* src/SDCCBlock.c (addiCodeToeBBlock): fixed bug 1652207: GOTO icodes appended by...
[fw/sdcc] / ChangeLog
1 2007-02-06 Bernhard Held <bernhard AT bernhardheld.de>
2
3         * src/SDCCBlock.c (addiCodeToeBBlock): fixed bug 1652207: GOTO icodes
4         appended by loop induction must be at the very end of the eBBlock
5
6 2007-02-05 Borut Razem <borut.razem AT siol.net>
7
8         * support/regression/fwk/lib/timeout.c: native WIN32 port,
9           implemented #1651830 Reg. tests: rewrite timeout.c to use WIN32 API
10
11 2007-02-03 Borut Razem <borut.razem AT siol.net>
12
13         * src/SDCC.y, src/SDCCmain.c, src/SDCCglobl.h, doc/sdccman.lyx:
14           applied patch #1646602 option to set default signedness of char to
15           unsigned, added -funsigned-char command line option,
16           thanks to Gunther Jehle
17         * device/lib/Makefile.in: added the -f option to rm so it doesn't
18           prompt for file deletion a few hundred times (especially the
19           subversion files, which have ro permissions so it asks for
20           confirmation), thanks to Simon McAuliffe;
21           added {} + option to find in order to remove multiple files from a
22           single rm commad
23
24 2007-02-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
25
26         * device/include/mcs51/SST89x5xRDx.h: Added.
27
28 2007-02-02 Raphael Neider <rneider AT web.de>
29
30         * src/pic/glue.c (emitSymbolSet): check sym->etype before use
31         * src/regression/Makefile: use --no-pcode-opt, ignore failing tests
32
33 2007-02-01 Raphael Neider <rneider AT web.de>
34
35         * src/pic/glue.c (picglue,emitSymbolSet,showAllMemmaps): emit the
36           config words again
37
38 2007-01-31 Borut Razem <borut.razem AT siol.net>
39
40         * support/Util/dbuf_string.h: added ATTRIBUTE_PRINTF to dbuf_printf()
41           if compiled with GCC. Thanks to Raphael Neider
42
43 2007-01-31 Raphael Neider <rneider AT web.de>
44
45         * src/pic/pcode.c (isValidIdChar,bankCompare): fuzzy matching of
46             operand names, handles name and (name + n) for all n,
47           (sameBank): restructured, also check bank allocation policy,
48         * src/pic/glue.c (emitPseudoStack): fixed printf arguments,
49           (pic14_operandsAllocatedInSameBank): check whether to operands
50             will be allocated into the same bank (i.e., section) to reduce
51             BANKSEL overhead, queried from pcode.c:sameBank,
52           (pic14printLocals): reintroduced clustering registers into a single
53             section: all compiler generated symbols will now reside in one
54             bank (per file), reducing BANKSEL overhead and code size,
55           (showAllMemmaps): use local dbuf where possible
56
57 2007-01-29 Raphael Neider <rneider AT web.de>
58
59         * src/pic/gen.c (popGetExternal): simplified, mark symbol as used,
60           (call_libraryfunc): retrieve/create symbol and mark as used,
61           (genFunction): mark defined functions as non-extern and add again
62            to code memmap for later output
63         * src/pic/glue.c (emitPseudoStack): put into own subroutine,
64           (pic14printLocals): reworked for new symbol emission,
65           (emitIfNew,pic14_constructAbsMap,emitIvalLabel,emitIvals,emitInitVal,
66           showAllMemmaps): reworked symbol output using dbufs, added handling
67             of string literals (still incomplete),
68           (picglue): removed symbol emission, moved into showAllMemmaps,
69           (emitSymbolSet): new workhorse for symbol output,
70           (pic14emitMaps,pic14printPublics,pic14printExterns): commented out
71
72 2007-01-29 Borut Razem <borut.razem AT siol.net>
73
74         * src/SDCCmain.c, src/SDCCutil.c: dbuf_splitFile: file extension
75           component contains the extension separator.
76
77 2007-01-28 Borut Razem <borut.razem AT siol.net>
78
79         * sim/ucsim/cmd.src/cmdutil.cc: NUL device is detected as CG_FILE type
80           on WIN32
81         * src/SDCCdwarf2.c, src/SDCCglobl.h, src/SDCCmain.c, src/SDCCutil.c,
82           src/SDCCutil.h, src/avr/gen.c, src/ds390/gen.c, src/hc08/gen.c,
83           src/mcs51/gen.c, src/pic/device.c, src/pic/gen.c, src/pic/pcode.c,
84           src/pic/pcodepeep.c, src/pic/ralloc.c, src/pic16/device.h,
85           src/pic16/gen.c, src/pic16/main.c, src/pic16/pcode.c,
86           src/pic16/pcodepeep.c, src/pic16/ralloc.c, src/xa51/gen.c,
87           src/z80/gen.c, support/Util/MySystem.c:
88           accept slash and backslash as directory separator on WIN32 and
89           Cygwin ports
90
91 2007-01-28 Raphael Neider <rneider AT web.de>
92
93         * src/pic16/devices.inc,
94         * device/include/pic16/pic18f[24][23]21.h,
95         * device/include/pic16/pic18fregs.h,
96         * device/lib/pic16/libdev/pic18f[24][23]21.c,
97         * device/lib/pic16/pics.all: added support for the 18f[24][23]21 family
98         * device/lib/pic16/libio/adc.ignore,
99         * device/lib/pic16/libio/i2c.ignore,
100         * device/lib/pic16/libio/usart.ignore: do not build I/O lib for new
101           family, as gputils do not yet support the devices
102         * device/lib/pic16/Makefile.subdir: ignore errors on install
103         * support/scripts/inc2h-pic16.pl: script to generate pic16 device
104           headers and libraries from gputils .inc files
105
106 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
107
108         * doc/sdccman.lyx: add printf_fast_f precision limitation note
109
110 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
111
112         * doc/sdccman.lyx: add printf benchmarks
113
114 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
115
116         * device/lib/printf_fast.c: fix %c, char promoted to int
117         * device/lib/printf_tiny.c: fix %c, char promoted to int
118
119 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
120
121         * device/lib/printf_fast.c: fix float overflow check, bug #1525093
122
123 2007-01-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
124
125         * support/regression/tests/swap.c: 64 bit hosts failed
126         * doc/sdccman.lyx: added preliminary mcs51 printf feature matrix
127
128 2007-01-25 Raphael Neider <rneider AT web.de>
129
130         * src/pic/pcode.c (sameBank,FixRegisterBanking): optimize banksels
131           based on absolute register address, patch by Alex Blond
132
133 2007-01-22 Raphael Neider <rneider AT web.de>
134
135         * src/pic/glue.c (pic14emitRegularMap): mark initialized symbols as
136           emitted, do not emit them again...
137
138 2007-01-22 Raphael Neider <rneider AT web.de>
139
140         * src/regression/bank1.c, src/regression/compare6.c,
141           src/regression/add.c: cosmetic changes
142         * src/pic/pcode.h: moved GPTRTAG_* here from gen.c
143         * src/pic/gen.c: fixed global zero and one,
144           (aopForSym): removed unued code,
145           (aopGet): assert aop is defined, check and use `index' of
146             pCodeImmd operands (fixes #1630908),
147         * src/pic/pcode.c (get_op): added output of generic pointer tag,
148           (register_reassign): prevent accidental register unification,
149           (ReuseReg): cosmetic changes (also above)
150         * src/pic/glue.c (pic14_constructAbsMap,pic14emitRegularMap,
151           pic14emitStaticSeg): do not emit initialized data,
152           (printIval*): replaced with working versions,
153           (pic14createInterruptVect,picglue): use idata for initialized data,
154             now init data should work in all modules (not only main()),
155         * device/lib/pic/libsdcc/idata.c: NEW, handle initialized data
156
157 2007-01-21 Borut Razem <borut.razem AT siol.net>
158
159         * sim/ucsim/configure.in: introduced macro DD_COPT_NO_IGNORE,
160           use -fPIC or -fpic if they are supported and not ignored
161         * src/SDCCval.c: fixed bug introduced by me in rev. #4577
162         * support/cpp2/libcpp/lex.c: fixed gcc 4.1.1 warnings
163
164 2007-01-20 Borut Razem <borut.razem AT siol.net>
165
166         * src/SDCC.lex, src/SDCCmain.c, sdc/SDCCglobl.h, doc/sdccman.lyx:
167           implemented RFE #1470316: allow "$" in variable names
168
169 2007-01-20 Raphael Neider <rneider AT web.de>
170
171         * device/include/pic/pic14regs.h: reverted accidental wipe of the file
172
173 2007-01-20 Raphael Neider <rneider AT web.de>
174
175         * device/lib/pic/libdev/devices.txt: device list for mkall.sh
176         * device/lib/pic/libdev/mkall.sh: script to rebuild all device libs
177         * device/lib/pic/libdev/pic14ports.txt: device PORT specifications
178         * support/scripts/inc2h.pl: fixed major .inc parsing bugs,
179           applied patch from Robert Tate (#1629249) to add PORTs and TRISs
180         * device/lib/pic/libdev/pic*.c,
181         * device/include/pic/pic*.h: regenerated with enhanced inc2h.pl
182         * device/lib/pic/libdev/Makefile.in: show progress
183
184 2007-01-19 Bernhard Held <bernhard AT bernhardheld.de>
185
186         * doc/sdccman.lyx: updated "configure options" for autoconf 2.6
187         * support/scripts/sdcc_cygwin_mingw32,
188         * support/scripts/sdcc_mingw32,
189         * support/scripts/build.mak: replaced --datadir by --datarootdir for
190         conformance with autoconf 2.6
191
192 2007-01-19 Raphael Neider <rneider AT web.de>
193
194         * src/pic/device.c (register_map): fixed list construction
195         * src/pic/gen.c (genDivOneByte,genModOneByte): accept result > 1 byte,
196           (genMod): removed case for genModbits,
197           (genModbits): removed as now unused/unimplemented
198         * src/pic/glue.c (picglue): prevent name clash with sources 'init.c'
199
200 2007-01-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
201
202         * support/regression/tests/swap.c: added in response to #1638622
203         * doc/sdccman.lyx: synced version, minor changes
204
205 2007-01-18 Borut Razem <borut.razem AT siol.net>
206
207         * SDCClabel.c: fixed bug #1638651: wrong linenumber presented in warning,
208           thanks to Gunther Jehle
209         * src/asm.c: don't die if the file drfined in #line couldn't be opened
210         * src/SDCC.lex, src/SDCCglobal.h, src/SDCCicode.c, src/SDCCsymt.c,
211           src/SDCCval.c: removed redundant definitions of currFname and mylineno;
212           use filename in lineno instead.
213         * SDCCast.c: removed MSVC warning C4018: '==' : signed/unsigned mismatch,
214           print the file name in ast_print()
215
216 2007-01-18 Borut Razem <borut.razem AT siol.net>
217
218         * support/Util/dbuf_string.c: removed (PTR) cast since it is not
219           defined in MSVC
220         * src/SDCC.lex: stringLiteral() returns const char pointer,
221           EOF detection in stringLiteral(), fixed asmbuf memory leak,
222           fixed column counting
223         * src/SDCCval.[ch]: constVal(), value *strVal() and charVal()
224           accept const char pointer as parameter
225         * src/SDCCdwarf2.c: corrected buffer size
226
227 2007-01-17 Borut Razem <borut.razem AT siol.net>
228
229         * support/Util/dbuf_string.c: fixed for amd64
230
231 2007-01-15 Borut Razem <borut.razem AT siol.net>
232
233         * src/pic16/ralloc.c, src/pic/ralloc.c, src/SDCC.y:
234           removed terminal symbol ELIPSIS, since it was never generated by the
235           lexer and it was wrongly used in parameter_identifier_list rule
236
237 2007-01-15 Raphael Neider <rneider AT web.de>
238
239         * doc/sdccman.lyx: updated PIC14/16 command line args, updated PIC14
240             code page and data banking description
241         * src/pic/genarith.c,
242         * src/pic/gen.h: removed bit arithmetic functions,
243             updated exit(1) to exit(EXIT_FAILURE)
244         * device/lib/pic16/libsdcc/stack/stack.S: default to 256 byte stack
245         * device/include/pic16/pic18f2455.h,
246         * device/lib/pic16/libdev/pic18f2455.c: added PORTD, LATD, LATE,
247             TRISD and TRISE, fixed/added some bit names
248         * device/lib/pic16/libdev/pic18f{2550,4550,4455}.c,
249         * device/include/pic16/pic18f{2550,4550,4455}.h: simply include
250             updated pic18f2455.{c,h} instead of duplicating them
251
252 2007-01-14 Borut Razem <borut.razem AT siol.net>
253
254         * as/mcs51/asnoice.c, as/hc08/asnoice.c: fixed bug #1447412:
255           Cannot debug files that contain spaces in the path name
256           by converting spaces in asm file name to underscores
257
258 2007-01-13 Borut Razem <borut.razem AT siol.net>
259
260         * doc/sdccman.lyx: fixed format errors
261
262 2007-01-10 Borut Razem <borut.razem AT siol.net>
263
264         * src/SDCC.lex, src/SDCCmain.c: fixed bug #1631895:
265           codeseg/constseg #pragma fail
266         * suppoprt/cpp2/Makefile.bcc: reenable Borland C compilation
267         * suppoprt/cpp2/configure.in, suppoprt/cpp2/libcpp/lex.c,
268           suppoprt/cpp2/Makefile.in, suppoprt/cpp2/sdcpp-opts,
269           suppoprt/cpp2/sdcpp.[ch]: house cleaning
270
271 2007-01-09 Borut Razem <borut.razem AT siol.net>
272
273         * get rid of diagnistic.[ch], pretty-print.[ch],
274           c-pretty-print.[ch], ... used just for error, warning, ...
275           message formatting
276         * suppoprt/cpp2/pretty-print.[ch], suppoprt/cpp2/diagnostic.[ch],
277           suppoprt/cpp2/diagnostic.def, suppoprt/cpp2/input.h,
278           suppoprt/cpp2/pretty-print.[ch]:
279           removed
280         * suppoprt/cpp2/Makefile.in, suppoprt/cpp2/opts.c,
281           suppoprt/cpp2/sdcpp-opts.c, suppoprt/cpp2/sdcpp.[ch],
282           suppoprt/cpp2/sdcpp.dsp:
283           changed
284
285 2007-01-08 Maarten Brock <sourceforge.brock AT dse.nl>
286
287         * device/lib/printf_large.c (output_float): removed recursion,
288           use smaller buffer on stack for mcs51,
289           fixed bug printing 1.96
290         * support/regression/tests/snprintf.c: added test
291
292 2007-01-07 Borut Razem <borut.razem AT siol.net>
293
294         * use dynamic memory buffers instead temporary files
295         * support/Util/dbuf_string.c, support/Util/dbuf_string.h:
296           added
297         * src/Makefile.in, src/SDCC.lex, src/SDCCast.c, src/SDCCast.h,
298           src/SDCCcse.c, src/SDCCglobl.h, src/SDCCglue.c, src/SDCCglue.h,
299           src/SDCCicode.c, src/SDCCicode.h, src/SDCCmain.c, src/SDCCmem.c,
300           src/SDCCmem.h, src/SDCCpeeph.c, src/SDCCpeeph.h, src/SDCCsymt.c,
301           src/SDCCsymt.h, src/SDCCutil.c, src/asm.c, src/asm.h, src/avr/gen.c,
302           src/avr/main.c, src/ds390/gen.c, src/ds390/main.c, src/hc08/gen.c,
303           src/hc08/main.c, src/izt/gen.c, src/mcs51/gen.c, src/mcs51/main.c,
304           src/pic/device.c, src/pic/gen.c, src/pic/glue.c, src/pic/main.c,
305           src/pic/ralloc.c, src/pic16/gen.c, src/pic16/glue.c,
306           src/pic16/main.c, src/pic16/ralloc.c, src/port.h, src/src.dsp,
307           src/xa51/gen.c, src/xa51/main.c, src/z80/gen.c, src/z80/main.c,
308           support/Util/dbuf.c, support/Util/dbuf.h:
309           modified
310         * .version, sdcc.spec: bumped version to 2.6.4
311
312 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
313
314         * src/port.h: added TARGET_Z80_LIKE macro
315         * src/SDCCmain.c (linkEdit): use TARGET_Z80_LIKE,
316           output PSEG location if --xram-loc or --xstack-loc was used
317         * as/link/mcs51/lkarea.c (lnksect2): set segment address afterwards
318
319 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
320
321         * as/as_gbz80.dsp, as/z80/as_gbz80.dsp,
322         * as/as_z80.dsp,   as/z80/as_z80.dsp,
323         * as/asx8051.dsp,  as/mcs51/asx8051.dsp,
324         * sdcc.dsw: moved project files into subdir
325         * as/hc08/as_hc08.dsp,
326         * as/hc08/Makefile.bcc,
327         * as/hc08/Makefile.in,
328         * as/mcs51/Makefile.bcc,
329         * as/mcs51/Makefile.in,
330         * as/z80/Makefile.bcc,
331         * as/z80/Makefile.in,
332         * as/link/mcs51/Makefile.bcc: use as/strcmpi.c
333         * as/hc08/asm.h,
334         * as/mcs51/asm.h,
335         * as/z80/asm.h: added as_strcmpi() and as_strncmpi() prototypes
336         * as/hc08/asmain.c,
337         * as/hc08/assym.c,
338         * as/mcs51/asmain.c,
339         * as/mcs51/assym.c,
340         * as/z80/assym.c: removed include "strcmpi.h"
341         * as/hc08/strcmpi.c,
342         * as/hc08/strcmpi.h,
343         * as/mcs51/strcmpi.c,
344         * as/mcs51/strcmpi.h,
345         * support/Util/strcmpi.c,
346         * support/Util/strcmpi.h: removed files
347         * as/strcmpi.c: added as_strncmpi()
348
349 2007-01-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
350
351         * sdcc.dsw: Added some dependencies on project config.dsp
352
353 2007-01-05 Maarten Brock <sourceforge.brock AT dse.nl>
354
355         * as/link/mcs51/lkarea.c (lnkarea2, lnksect2): replaced [di]seg_ap->a_addr
356           with [di]ram_start to fix a regresion
357
358 2007-01-03 Bernhard Held <bernhard AT bernhardheld.de>
359
360         * configure.in: added missing mcs51 in status output
361         * Makefile.in: add support/regression to SDCC_EXTRA to distclean this
362         directory
363         * debugger/mcs51/clean.mk (distclean): remove config.h
364         * src/clean.mk (clean): remove SDCCy.c, SDCCy.h, SDCClex.c
365         * support/cpp2/Makefile.in (clean): remove s-options, optionlist,
366         options.h, s-options-h and options.c
367         * support/cpp2/clean.mk: unused, removed
368         * Makefile.common.in,
369         * main_in.mk,
370         * as/Makefile.in,
371         * as/hc08/Makefile.in,
372         * as/hc08/clean.mk,
373         * as/mcs51/Makefile.in,
374         * as/mcs51/clean.mk,
375         * as/z80/clean.mk,
376         * as/z80/conf.mk,
377         * as/z80/Makefile.in,
378         * as/z80/clean.mk,
379         * as/link/Makefile.in,
380         * as/link/hc08/Makefile.in,
381         * as/link/hc08/clean.mk,
382         * as/link/mcs51/Makefile.in,
383         * as/link/mcs51/clean.mk,
384         * as/link/z80/Makefile.in,
385         * as/link/z80/clean.mk,
386         * as/link/z80/conf.mk,
387         * debugger/mcs51/Makefile.in,
388         * debugger/mcs51/clean.mk,
389         * device/include/Makefile.in,
390         * device/lib/Makefile.in,
391         * device/lib/mcs51/Makefile.in,
392         * device/lib/pic/Makefile.in,
393         * device/lib/pic/Makefile.common.in,
394         * device/lib/pic/Makefile.subdir,
395         * device/lib/pic/Makefile.rules,
396         * device/lib/pic16/libio/Makefile.in,
397         * device/lib/pic16/Makefile.subdir,
398         * device/lib/pic16/libdev/Makefile.in,
399         * device/lib/pic16/Makefile.rules,
400         * device/lib/pic16/Makefile.common.in,
401         * sim/ucsim/avr.src/Makefile.in,
402         * sim/ucsim/main_in.mk,
403         * sim/ucsim/cmd.src/Makefile.in,
404         * sim/ucsim/doc/Makefile.in,
405         * sim/ucsim/gui.src/Makefile.in,
406         * sim/ucsim/gui.src/obsolete/portmon.src/Makefile.in,
407         * sim/ucsim/gui.src/serio.src/Makefile.in,
408         * sim/ucsim/hc08.src/Makefile.in,
409         * sim/ucsim/libltdl/Makefile.in,
410         * sim/ucsim/s51.src/Makefile.in,
411         * sim/ucsim/sim.src/Makefile.in,
412         * sim/ucsim/sim.src/conf.mk,
413         * sim/ucsim/xa.src/Makefile.in,
414         * sim/ucsim/z80.src/Makefile.in,
415         * src/Makefile.in,
416         * src/clean.mk,
417         * src/port.mk,
418         * support/cpp2/Makefile.in,
419         * support/librarian/Makefile.in,
420         * support/librarian/clean.mk,
421         * support/makebin/Makefile.in,
422         * support/makebin/clean.mk,
423         * support/packihx/Makefile.in,
424         * support/regression/Makefile.in,
425         * support/regression/ports/ds390/spec.mk,
426         * support/regression/ports/gbz80/spec.mk,
427         * support/regression/ports/hc08/spec.mk,
428         * support/regression/ports/mcs51/spec.mk,
429         * support/regression/ports/mcs51-large/spec.mk,
430         * support/regression/ports/mcs51-medium/spec.mk,
431         * support/regression/ports/mcs51-xstack-auto/spec.mk,
432         * support/regression/ports/pic14/spec.mk,
433         * support/regression/ports/pic16/spec.mk,
434         * support/regression/ports/mcs51-stack-auto/spec.mk,
435         * support/regression/ports/ucz80/spec.mk,
436         * support/regression/ports/xa51/spec.mk,
437         * support/regression/ports/z80/spec.mk: fixed for autoconf 2.6x by
438         adding a slash after $(top_builddir) and/or adding @datarootdir@
439         * configure.in,
440         * debugger/mcs51/configure.in,
441         * device/lib/pic/configure.in,
442         * device/lib/pic16/configure.in,
443         * sim/ucsim/configure.in,
444         * support/cpp2/configure.in,
445         * support/packihx/configure.in: changed AC_PREREQ to 2.60
446         * configure,
447         * debugger/mcs51/configure,
448         * device/lib/pic/configure,
449         * device/lib/pic16/configure,
450         * sim/ucsim/configure,
451         * support/cpp2/configure,
452         * support/packihx/configure: generated with autoconf 2.60
453
454 2007-01-02 Maarten Brock <sourceforge.brock AT dse.nl>
455
456         * as/link/hc08/lkihx.c (newArea),
457         * as/link/hc08/lkrloc.c: renamed newArea() to ihxNewArea()
458
459 2007-01-02 Borut Razem <borut.razem AT siol.net>
460
461         * doc/sdccman.lyx: documented #pragma sdcc_hash
462         * support/cpp2/sdcpp.c: allow_naked_hash (value of #pragma sdcc_hash)
463           initialized to 0
464         * support/cpp2/c-ppoutput.c: fixed warning: no newline at end of file
465
466 2007-01-01 Bernhard Held <bernhard AT bernhardheld.de>
467
468         * src/SDCCast.c (createDo): backPatchLabels() needs falseLabel in
469         empty 'while'-loop to work correctly, see regression test 'while.c'
470         * support/regression/tests/while.c: added
471
472 2007-01-01 Borut Razem <borut.razem AT siol.net>
473
474         * support/cpp2/libcpp/directives.c, support/cpp2/libcpp/identifiers.c,
475           support/cpp2/libcpp/init.c, support/cpp2/libcpp/sdcpp-opts.c,
476           support/cpp2/libcpp/sdcpp.c:
477           sdcpp specific pragma/directive/option handling moved to sdcpp.c
478         * doc/sdccman.lyx: reference to the GCC 4.1.1 CPP Manual
479         * support/cpp2/libcpp/mkdeps.c: synchronized with GCC CPP 4.1.1
480
481 2006-12-31 Borut Razem <borut.razem AT siol.net>
482
483         * SDCPP synchronized with GCC CPP release version 4.1.1,
484           currently the latest release:
485         * support/cpp2/libcpp, support/cpp2/libcpp/include,
486           support/cpp2/libcpp/include/cpp-id-data.h
487           support/cpp2/libiberty/fopen_unlocked.c
488           support/cpp2/libiberty/md5.c
489           support/cpp2/md5.h
490           support/cpp2/opt-functions.awk
491           support/cpp2/opt-gather.awk
492           support/cpp2/optc-gen.awk
493           support/cpp2/opth-gen.awk:
494           added
495         * support/cpp2/Makefile.in, support/cpp2/auto-host_vc_in.h,
496           support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
497           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
498           support/cpp2/c-pretty-print.h, support/cpp2/cppdefault.c,
499           support/cpp2/cppdefault.h, support/cpp2/diagnostic.c,
500           support/cpp2/diagnostic.h, support/cpp2/except.h,
501           support/cpp2/hwint.h, support/cpp2/input.h,
502           support/cpp2/intl.h, support/cpp2/move-if-change,
503           support/cpp2/opts.c, support/cpp2/opts.h,
504           support/cpp2/output.h, support/cpp2/prefix.c,
505           support/cpp2/prefix.h, support/cpp2/pretty-print.c,
506           support/cpp2/pretty-print.h, support/cpp2/sdcpp-opts.c,
507           support/cpp2/sdcpp.c, support/cpp2/sdcpp.dsp,
508           support/cpp2/sdcpp.h, support/cpp2/sdcpp.opt,
509           support/cpp2/sdcppa.dsp, support/cpp2/symcat.h,
510           support/cpp2/version.c:
511           modified
512         * support/cpp2/libcpp/charset.c, support/cpp2/libcpp/directives.c,
513           support/cpp2/libcpp/errors.c, support/cpp2/libcpp/expr.c,
514           support/cpp2/libcpp/files.c, support/cpp2/libcpp/identifiers.c,
515           support/cpp2/libcpp/include/cpplib.h, support/cpp2/libcpp/include/line-map.h,
516           support/cpp2/libcpp/include/mkdeps.h, support/cpp2/libcpp/include/symtab.h,
517           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
518           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/line-map.c,
519           support/cpp2/libcpp/macro.c, support/cpp2/libcpp/mkdeps.c,
520           support/cpp2/libcpp/symtab.c, support/cpp2/libcpp/system.h,
521           support/cpp2/libcpp/traditional.c, support/cpp2/libcpp/ucnid.h,
522           support/cpp2/libiberty/hashtab.c, support/cpp2/libiberty/hashtab.h:
523           moved
524         * support/cpp2/cppcharset.c, support/cpp2/cpperror.c,
525           support/cpp2/cppexp.c, support/cpp2/cppfiles.c,
526           support/cpp2/cpphash.c, support/cpp2/cpphash.h,
527           support/cpp2/cppinit.c, support/cpp2/cpplex.c,
528           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
529           support/cpp2/cppmacro.c, support/cpp2/cpptrad.c,
530           support/cpp2/cppucnid.h, support/cpp2/hashtab.c,
531           support/cpp2/hashtab.h, support/cpp2/hashtable.c,
532           support/cpp2/hashtable.h, support/cpp2/line-map.c,
533           support/cpp2/line-map.h, support/cpp2/mkdeps.c,
534           support/cpp2/mkdeps.h, support/cpp2/options_vc_in.c,
535           support/cpp2/options_vc_in.h, support/cpp2/opts.sh,
536           support/cpp2/system.h:
537           deleted / moved
538
539 2006-12-31 Borut Razem <borut.razem AT siol.net>
540
541         * configure.in, configure: fixed bug #1538756: configure dies if bison
542           and flex are not installed, 2nd try
543
544 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
545
546         * src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to
547         400.x for better code in RFE 899102
548
549 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
550
551         * src/SDCCpeeph.c (deadMove),
552         * src/port.h,
553         * src/mcs51/peep.h: renamed 'op' by 'reg'
554         * src/mcs51/peep.c (isFunc, isCallerSaveFunc): added,
555         (scan4op): small change for removeDeadMove(), added support for
556         'callee saves' and/or PACLL function calls,
557         (removeDeadMove): added, removes superflous 'mov r%1,%2',
558         (removeDeadPopPush): renamed from mcs51DeadMove(), common parts
559         left in new dispatcher mcs51DeadMove()
560         (mcs51DeadMove): dispatcher for removeDeadPopPush() and new
561         removeDeadMove()
562         * src/mcs51/peeph.def: added rule 301 removing superflous 'mov r%1,%2'
563
564 2006-12-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
565
566         * support/cpp2/options_vc_in.h, support/cpp2/options_vc_in.c,
567           support/cpp2/sdcppa.dsp: create 'options.h' and 'options.c' under MSVC.
568
569 2006-12-30 Borut Razem <borut.razem AT siol.net>
570
571         * support/cpp2/spacs.h: deleted from svn
572         * configure.in, configure: fixed bug #1538756: configure dies if bison
573           and flex are not installed
574
575 2006-12-29 Maarten Brock <sourceforge.brock AT dse.nl>
576
577         * src/z80/gen.c (assignResultValue): fixed bug when registers overlap,
578           with this z80 passes printf float test when enabled
579         * support/regression/tests/bug1057979.c: typo disabled ds390 float test
580
581 2006-12-28 Borut Razem <borut.razem AT siol.net>
582
583         * support/cpp2/config.in, support/cpp2/configure.in,
584           support/cpp2/configure, support/cpp2/Makefile.in:
585           fix for the solaris build
586
587 2006-12-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
588
589         * src/SDCC.y (type_specifier2, pointer),
590         * src/SDCCsymt.h,
591         * src/SDCCsymt.c (mergeSpec, checkSClass),
592         * support/Util/SDCCerr.c,
593         * support/Util/SDCCerr.h: Parse and validate the restrict keyword
594         * support/valdiag/valdiag.py: Allow test cases to specify
595           required language standard
596         * support/valdiag/tests/restrict.c: New file to test restrict keyword
597         * support/valdiag/tests/tentdecl.c: Supress empty source file error
598
599 2006-12-27 Borut Razem <borut.razem AT siol.net>
600
601         * support/cpp2/cppmain.c, support/cpp2/mbchar.[ch]: removed
602         * support/cpp2/libiberty/Makefile.in, support/cpp2/libiberty/sdcpp.dsp:
603           mbchar removed
604         * support/cpp2/libiberty/getpwd.c, support/cpp2/sdcpp.h:
605           fixed for borland C
606         * support/cpp2/libiberty/Makefile.bcc: updated
607         * src/pic16/main.c: fixed #pragma udata handling
608         * src/mcs51/mcs51.dsp: added peep.[ch] to the project
609
610 2006-12-26 Bernhard Held <bernhard AT bernhardheld.de>
611
612         * src/SDCCpeeph.c: made labelHashEntry global,
613         made pcDistance, FBYNAME static,
614         (pcDistance): made static, use isComment and isLabel,
615         (deadMove): added,
616         (getLabelRef): added, extracted from labelRefCount(),
617         (labelRefCount): use new getLabelRef(),
618         (callFuncByName): made static, added deadMove,
619         use isComment and isLabel,
620         (newPeepRule): made static, set isLabel,
621         (isLabelDefinition): added parameter isPeepRule to allow '%' in
622         labels from peephole rules,
623         (buildLabelRefCountHash): speed up by running isLabelDefinition() only
624         when isComment or isLabel is set
625         * src/SDCCpeeph.h: added "isLabel" and "visited" to struct lineNode,
626         added labelHashEntry, isLabelDefinition, labelHash and getLabelRef
627         to make them global
628         * src/mcs51/peep.h: added
629         * src/mcs51/peep.c: added, implements mcs51DeadMove()
630         * src/port.h: added peep->deadMove to port structure
631         * src/mcs51/main.c: initialize peep->deadMove with mcs51DeadMove
632         * src/mcs51/peeph.def: renumbered rule 300 to 400, added new rule 300
633         deadMove, finally removed no. 1 and 2
634         * src/mcs51/gen.c,
635         * src/pic/gen.c,
636         * src/z80/gen.c,
637         * src/z80/ralloc.c,
638         * src/pic16/gen.c,
639         * src/ds390/gen.c,
640         * src/hc08/gen.c: mark lines with isComment or isLabel
641         * sim/ucsim/s51.src/uc390hw.cc: don't waist 65535 ticks before CKRDY
642         * .version,
643         * sdcc.spec: bumped version to 2.6.3
644
645 2006-12-26 Borut Razem <borut.razem AT siol.net>
646
647         * support/cpp2/Makefile.in: added dependency on options.h
648         * configure: regenerated
649         * support/cpp2/sdcpp.opt, support/cpp2/move-if-change: svn:eol-style native
650         * support/cpp2/Makefile.in: added vasprintf.c
651
652 2006-12-25 Borut Razem <borut.razem AT siol.net>
653
654         * SDCPP synchronized with GCC CPP release version 3.4.6,
655           the latest release before 4.x:
656         * support/cpp2/Makefile.in, support/cpp2/config.h,
657           support/cpp2/configure, support/cpp2/configure.in,
658           support/cpp2/cppdefault.c, support/cpp2/cppdefault.h,
659           support/cpp2/cpperror.c, support/cpp2/cppexp.c,
660           support/cpp2/cppfiles.c, support/cpp2/cpphash.c,
661           support/cpp2/cpphash.h, support/cpp2/cppinit.c,
662           support/cpp2/cpplex.c, support/cpp2/cpplib.c,
663           support/cpp2/cpplib.h, support/cpp2/cppmacro.c,
664           support/cpp2/cpptrad.c, support/cpp2/except.h,
665           support/cpp2/hashtable.c, support/cpp2/hashtable.h,
666           support/cpp2/hwint.h, support/cpp2/intl.h,
667           support/cpp2/line-map.c, support/cpp2/line-map.h,
668           support/cpp2/mkdeps.c, support/cpp2/mkdeps.h,
669           support/cpp2/output.h, support/cpp2/prefix.c,
670           support/cpp2/prefix.h, support/cpp2/sdcpp.dsp,
671           support/cpp2/system.h, support/cpp2/version.c:
672           modified
673         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
674           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
675           support/cpp2/c-pretty-print.h, support/cpp2/cppcharset.c,
676           support/cpp2/cppucnid.h, support/cpp2/diagnostic.c,
677           support/cpp2/diagnostic.def, support/cpp2/diagnostic.h,
678           support/cpp2/hashtab.c, support/cpp2/hashtab.h,
679           support/cpp2/input.h, support/cpp2/libiberty/getpwd.c,
680           support/cpp2/libiberty/vasprintf.c, support/cpp2/libiberty/xmemdup.c,
681           support/cpp2/move-if-change, support/cpp2/opts.c,
682           support/cpp2/opts.h, support/cpp2/opts.sh,
683           support/cpp2/pretty-print.c, support/cpp2/pretty-print.h,
684           support/cpp2/sdcpp.opt, support/cpp2/sdcpp-opts.c,
685           support/cpp2/win32, support/cpp2/win32/dirent.c,
686           support/cpp2/win32/dirent.h:
687           added
688         * support/cpp2/sdcpp.c: renamed from sdcppmain.c
689         * support/cpp2/sdcpp.h: renamed from sdcc.h
690         * sdcppinit.c: deleted
691
692 2006-12-23 Borut Razem <borut.razem AT siol.net>
693
694         * support/cpp2/cpphash.h, support/cpp2/cpplex.c,
695           support/cpp2/cpplib.[ch], support/cpp2/sdcppinit.c, doc/sdccman.lyx,
696           preproc.c: an other try to fix bug #982435: introduced
697           -pedantic-parse-number command line option and pedantic_parse_number
698           pragma
699
700 2006-12-21 Maarten Brock <sourceforge.brock AT dse.nl>
701
702         * as/link/mcs51/lkarea.c (lnkarea2): handle absolute areas, restructured
703            BSEG handling,
704           (lnksect2): use --data-loc and --idata-loc as lower bound for ramstart,
705            corrected overlayed areax addresses, warn about memory overlaps
706         * as/mcs51/asmain.c (asmbl): create a new area for every .org directive
707         * src/avr/main.c,
708         * src/ds390/main.c,
709         * src/hc08/main.c,
710         * src/mcs51/main.c,
711         * src/pic16/main.c,
712         * src/pic/main.c,
713         * src/xa51/main.c,
714         * src/z80/main.c,
715         * src/port.h: added xabs_name and iabs_name
716         * src/SDCCglue.c (emitRegularMap): allocate for absolutes with initializer
717           (glue, emitMaps): create and emit maps d_abs and i_abs
718         * src/SDCCglue.h: cosmetic changes
719         * src/SDCCmain.c (setDefaultOptions): idata can start below 0x80
720         * src/SDCCmem.h,
721         * src/SDCCmem.c (initMem): added x_abs, i_abs and d_abs
722           (allocDefault): put absolute, initialized globals in them
723         * support/regression/tests/absolute.c: added absolute bdata test
724         * device/lib/printf_large.c (output_float): moved fpBuffer to stack/xdata
725
726 2006-12-20 Borut Razem <borut.razem AT siol.net>
727
728         * support/cpp2/cpphash.h, support/cpp2/cpplex.c: fixed bug #982435
729         * support/regression/tests/preproc.c: renamed from bug-1351710.c,
730           added regression test for bug #982435
731
732 2006-12-18 Borut Razem <borut.razem AT siol.net>
733
734         * src/SDCCutil.c: fixed a bug in (get_pragma_token)
735         * src/pic16/main.c, src/SDCC.lex, src/z80/main.c:
736           small cosmetic changes
737         * src/SDCC.lex: (stringLiteral) fixed bug #1351710
738         * support/regression/tests/bug-1351710.c: added regression test
739
740 2006-12-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
741
742         * doc/sdccman.lyx: added the long missed iCode table
743           "<where is figure II?>", added links to wiki
744
745 2006-12-17 Borut Razem <borut.razem AT siol.net>
746
747         * doc/sdccman.lyx, src/pic16/main.c, src/pic/main.c, src/port.h,
748           src/SDCC.lex, src/SDCCutil.[ch], src/z80/main.c,
749           support/Util/SDCCerr.[ch]: removed deprecated pragmas,
750           unified table driven pragma handling, pragma argument type checking
751         * support/Util/dbuf.c: (dbuf_set_size) allow to set size equal to the
752           current one - version 1.1.3
753         * src/SDCCmain.c: (setParseWithComma) substituted brain damaged strtok
754
755 2006-12-13 Raphael Neider <rneider AT web.de>
756
757         * src/pic/device.h: removed AssignedMemory structure and macros
758         * src/pic/device.c: removed global finalMapping (linker assigns
759             memory locations),
760           (register_map): add SFRs to remembered memRanges
761           (addMemRange,isSFR,dump_map,dump_sfr,mapRegister,assignRegister,
762           assignFixedRegisters,assignRelocatableRegisters): removed,
763           (setMaxRAM,validAddress): adapted accordingly,
764           (pic14_hasSharebank,pic14_getSharedStack): only report and use
765             reasonably sized sharebanks,
766         * src/pic/ralloc.c (writeUsedRegs): stripped down (remove?),
767           (allDefsOutOfRange): removed unused code,
768         * src/pic/main.c (_process_pragma): removed memmap/maxram pragma
769             handling
770         * src/pic/pcode.c (register_reassign): removed recursion warning,
771             fired far too often,
772         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap): modified
773             to use existing pic14_stringInSet() to avoid duplicate symbols,
774             tidied up the code a bit,
775           (pic14printLocals): added in symmetry to printExterns, replaces
776             writeUsedRegs more or less,
777           (picglue): call new pic14_printLocals(),
778         * device/include/pic/pic*.h: removed #pragma memmap directives,
779             information gathered from include/pic/pic14devices.txt
780         * support/scripts/inc2h.pl: do not emit #pragma memmap lines
781
782 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
783
784         * device/include/mcs51/C8051F520.h: fixed buggy CPT0MX
785
786 2006-12-11 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
787
788         * device/include/mcs51/cc2430.h: fixed missing ';'
789
790 2006-12-10 Raphael Neider <rneider AT web.de>
791
792         * device/lib/pic16/libc/stdio/vfprintf.c,
793         * device/lib/pic16/libc/stdio/printf_small.c,
794         * device/lib/pic16/libc/stdio/printf_timy.c: pop int from stack for
795           char arguments, as char varargs are cast to int by the caller,
796           hopefully fixes #1604915 (other device libraries are still affected)
797
798 2006-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
799
800         * src/mcs51/ralloc.c (packRegsForAssign),
801         * src/hc08/ralloc.c (packRegsForAssign): fixed bug #1605880
802
803 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
804
805         * device/include/malloc.h: removed init_dynamic_memory
806         * device/lib/malloc.c: made init_dynamic_memory static and automatically
807           call it once from malloc. Also use _sdcc_heap[] from _heap.c
808         * device/lib/_heap.c: new, added, contains _sdcc_heap[]
809         * device/lib/libsdcc.lib,
810         * device/lib/Makefile.in,
811         * support/regression/ports/mcs51-xstack-auto/spec.mk: added _heap.c
812         * doc/sdccman.lyx: documented use of new _heap.c
813         * support/regression/tests/malloc.c: removed init_dynamic_memory
814         * src/cdbFile.c(spacesToUnderscores): new function,
815           (cdbWriteEndFunction, cdbWriteCLine): use spacesToUnderscores, fixes bug
816           1068030
817         * device/include/tinibios.h: removed defines for putchar and getchar
818         * device/lib/ds390/Makefile.in: added putchar.c
819         * device/lib/ds390/putchar.c: new, added, fixes bug 1465671
820
821 2006-12-09 Borut Razem <borut.razem AT siol.net>
822
823         * support/cpp2/sdcc.h: prevent multiple inclusion
824         * support/cpp2/options.h: deleted
825
826 2006-12-08 Borut Razem <borut.razem AT siol.net>
827
828         * support/cpp2/sdcc.h: removed x*alloc() macros
829         * support/cpp2/libiberty.h: uncommented out x*alloc() declarations
830         * support/cpp2/Makefile.bcc, support/cpp2/Makefile.in,
831           support/cpp2/sdcpp.sdc: x*alloc files added to the project
832         * support/cpp2/system.h: moved #include "sdcc.h"
833         * support/cpp2/libiberty/xexit.c, support/cpp2/libiberty/xmalloc.c,
834           support/cpp2/libiberty/xstrdup.c, support/cpp2/libiberty/xstrerror.c:
835           added
836         * support/cpp2/sdcppinit.c: added -isysroot, -fsigned-char,
837           -funsigned-char options
838         * support/cpp2/sdcppmain.c: fixed bug 1611411
839
840 2006-12-07 Borut Razem <borut.razem AT siol.net>
841
842         * support/cpp2/cpplib.c: reverted sdcpp special handling of _Pragma()
843           directive
844
845 2006-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
846
847         * src/SDCCsymt.c (addDecl): fixed bug 1609244
848         * src/SDCCmain.c (linkEdit): fixed bug 1609279
849         * doc/sdccman.lyx,
850         * .version: bumped to 2.6.2 because a) it's been a while
851           b) the linker sources have moved c) the preprocessor is upgraded
852
853 2006-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
854
855         * support/regression/tests/snprintf.c: some checks
856         * lib/src/printf_large.c: %bc: read char instead of int from stack
857
858 2006-12-03 Maarten Brock <sourceforge.brock AT dse.nl>
859
860         * device/include/mcs51/cc2430.h: inserted _XPAGE
861
862 2006-12-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
863
864         * device/include/mcs51/cc2430.h: added
865
866 2006-12-02 Maarten Brock <sourceforge.brock AT dse.nl>
867
868         * device/include/asm/default/features.h,
869         * device/include/asm/ds390/features.h,
870         * device/include/mcs51/at89s53.h,
871         * device/include/ser.h,
872         * device/include/ser_ir.h,
873         * device/include/serial.h: changed keywords to double underscore variants,
874           fixes bug 1590261 some more, thanks Steven Borley
875
876 2006-12-01 Raphael Neider <rneider AT web.de>
877
878         * src/pic/pcode.c (register_reassign): do not crash on recursive code
879           but emit warning (recursion is not supported for pic14)
880
881 2006-11-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
882
883         * src/mcs51/peeph.def: added 101.a,b (moves to int/long xdata)
884         * doc/sdccman.lyx: various small changes, acknowledged Sourceforge
885
886 2006-11-30 Raphael Neider <rneider AT web.de>
887
888         * src/pic/device.c (dump_sfr): always emit symbols
889         * src/pic/glue.c (pic14printPublics): fixed typo
890
891 2006-11-30 Raphael Neider <rneider AT web.de>
892
893         * src/pic/device.c (create_pic,ram_map): add memRange entries to PIC
894           (pic14_getSharebankSize, pic14_getSharebankAddress): replaced with
895           (pic14_hasSharebank,pic14_isShared,pic14_allRAMShared,
896            pic14_getSharedStack): NEW, evaluate the memRange entries to locate
897            a sharebank, use a non-shared bank for the stack if none available
898         * src/pic/device.h (struct memRange): added linked list next field,
899           added prototypes for above functions
900         * src/pic/ralloc.c (initStack): handle shared and banked stacks,
901           (typeRegWithIdx): accept fixed and unfixed stack registers
902         * src/pic/pcode.c (pCodeInitRegisters): use new functions to create
903           the stack, handle shared and banked stack (except for WSAVE),
904           (insertBankSel): removed useless optimization (will never fire),
905           (FixRegisterBanking): added optimization for devices with only one
906           possibly aliased bank of memory, like 16f84
907         * src/pic/glue.c (pic14_constructAbsMap): back to udata_ovr, as some
908           devices have no SHAREBANK in the linker script
909         * device/include/pic/pic14devices.txt: documented memmap
910         * device/lib/pic/libdev/Makefile.in: removed --stack-loc again
911
912 2006-11-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
913
914         * src/hc08/gen.c (transferRegReg, loadRegFromAop, forceStackedAop,
915           storeRegToAop, freeAsmop, genPlusIncr, genPlus, genPointerGetSetOfs,
916           genAnd, genOr, genXor, genLeftShiftLiteral, genRightShiftLiteral,
917           genhc08Code): switched most of the D (debug) macros to DD (detailed
918           debug) macros to better control clutter in the generated .asm file.
919         * src/hc08/gen.c: (forceStackedAop, genUminus, genLeftShift,
920           genRightShift): fixed bug with non-constant bit shift stored to
921           a volatile result (SF Open Discussion forum thread #1616749).
922           Single byte case is not yet optimized.
923
924 2006-11-28 Maarten Brock <sourceforge.brock AT dse.nl>
925
926         * device/include/asm/mcs51/features.h,
927         * device/include/malloc.h,
928         * device/include/stdio.h: changed keywords to double underscore variants,
929           fixes bug 1590261
930
931 2006-11-27 Borut Razem <borut.razem AT siol.net>
932
933         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
934           support/cpp2/Makefile.in, support/cpp2/cppfiles.c,
935           support/cpp2/output.h, support/cpp2/cppinit.c,
936           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
937           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
938           support/cpp2/cppdefault.c, support/cpp2/system.h,
939           support/cpp2/cpphash.h, support/cpp2/cpplex.c,
940           support/cpp2/cppdefault.h, support/cpp2/mbchar.c,
941           support/cpp2/prefix.c, support/cpp2/except.h,
942           support/cpp2/hwint.h, support/cpp2/cppmacro.c,
943           support/cpp2/line-map.h, support/cpp2/sdcpp.dsp,
944           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
945           support/cpp2/version.c, support/cpp2/cppmain.c,
946           support/cpp2/version.h, support/cpp2/hashtable.c,
947           support/cpp2/cpperror.c:
948           synchronized with GCC CPP release version 3.3.6,
949           the latest where cppmain.c still exists.
950         * support/cpp2/cpptrad.c, support/cpp2/sdcppmain.c,
951           support/cpp2/sdcppinit.c: added
952
953 2006-11-27 Borut Razem <borut.razem AT siol.net>
954
955         * support/cpp2/cpplex.c:
956           fixed _asm ... _endasm handling bug, introduce with GCC CPP
957           synchronization
958         * support/cpp2/cpplib.c: removed definitions of unused variables
959
960 2006-11-26 Borut Razem <borut.razem AT siol.net>
961
962         * support/cpp2/libiberty.h: commented out x*alloc() declarations
963           since they are redefined by macros in support/cpp2/sdcc.h
964         * support/cpp2/sdcc.h: x*alloc macro redefinition
965
966 2006-11-25 Borut Razem <borut.razem AT siol.net>
967
968         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
969           support/cpp2/configure, support/cpp2/Makefile.in,
970           support/cpp2/cppfiles.c, support/cpp2/output.h,
971           support/cpp2/cppinit.c, support/cpp2/cpplib.c,
972           support/cpp2/config.h, support/cpp2/cpplib.h,
973           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
974           support/cpp2/cppdefault.c, support/cpp2/config.in,
975           support/cpp2/system.h, support/cpp2/cpplex.c,
976           support/cpp2/cpphash.h, support/cpp2/mbchar.c,
977           support/cpp2/cppdefault.h, support/cpp2/prefix.c
978           support/cpp2/hwint.h, support/cpp2/mbchar.h,
979           support/cpp2/prefix.h, support/cpp2/cppmacro.c,
980           support/cpp2/configure.in, support/cpp2/intl.h,
981           support/cpp2/sdcpp.dsp, support/cpp2/acconfig.h,
982           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
983           support/cpp2/version.c, support/cpp2/cppmain.c,
984           support/cpp2/ansidecl.h, support/cpp2/libiberty.h,
985           support/cpp2/hashtable.c, support/cpp2/aclocal.m4,
986           support/cpp2/cpperror.c,
987           support/cpp2/libiberty/safe-ctype.c,
988           support/cpp2/libiberty/safe-ctype.h,
989           support/cpp2/libiberty/splay-tree.c,
990           support/cpp2/libiberty/obstack.c,
991           support/cpp2/libiberty/lbasename.c,
992           support/cpp2/libiberty/splay-tree.h,
993           support/cpp2/libiberty/obstack.h:
994           synchronized with GCC CPP release version 3.2.3,
995           the latest before integration of cpp into gcc
996         * support/cpp2/except.h, support/cpp2/line-map.c,
997           support/cpp2/line-map.h,
998           support/cpp2/libiberty/hex.c,
999           support/cpp2/libiberty/concat.c,
1000           support/cpp2/libiberty/filenames.h: added
1001         * support/cpp2/intl.c: deleted
1002
1003 2006-11-24 Borut Razem <borut.razem AT siol.net>
1004
1005         * src/SDCC.y: enabled compilation of empty source file
1006         * support/Util/SDCCerr.[ch]: added sdcc warning 190 -
1007           "ISO C forbids an empty source file"
1008         * device/lib/_startup.c, device/lib/printf_tiny.c: disable warning 190
1009           if all the code is ifdefed out.
1010
1011 2006-11-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1012
1013         * src/hc08/gen.c (genPcall): fix for bug #1601032
1014
1015 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
1016
1017         * device/include/mcs51/c8051f000.h, device/include/mcs51/C8051F000.h,
1018         * device/include/mcs51/c8051f018.h, device/include/mcs51/C8051F018.h,
1019         * device/include/mcs51/c8051f020.h, device/include/mcs51/C8051F020.h,
1020         * device/include/mcs51/c8051f040.h, device/include/mcs51/C8051F040.h,
1021         * device/include/mcs51/c8051f060.h, device/include/mcs51/C8051F060.h,
1022         * device/include/mcs51/c8051f120.h, device/include/mcs51/C8051F120.h,
1023         * device/include/mcs51/c8051f200.h, device/include/mcs51/C8051F200.h,
1024         * device/include/mcs51/c8051f300.h, device/include/mcs51/C8051F300.h,
1025         * device/include/mcs51/c8051f310.h, device/include/mcs51/C8051F310.h,
1026         * device/include/mcs51/c8051f320.h, device/include/mcs51/C8051F320.h,
1027         * device/include/mcs51/c8051f326.h, device/include/mcs51/C8051F326.h,
1028         * device/include/mcs51/c8051f330.h, device/include/mcs51/C8051F330.h,
1029         * device/include/mcs51/c8051f340.h, device/include/mcs51/C8051F340.h,
1030         * device/include/mcs51/c8051f350.h, device/include/mcs51/C8051F350.h,
1031         * device/include/mcs51/c8051f410.h, device/include/mcs51/C8051F410.h:
1032           Renamed to all upper case as per the standard set by SiLabs
1033
1034 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
1035
1036         * device/include/mcs51/C8051F520.h: new, added
1037         * device/include/mcs51/compiler.h: added link about predefined macros
1038
1039 2006-11-23 Raphael Neider <rneider AT web.de>
1040
1041         * src/regression/Makefile: add -L path to fresh library
1042         * src/regression/simulate: emphasize FAILED output
1043         * src/regression/create_stc: output _failures from gpsim
1044         * src/regression/compare4.c,
1045         * src/regression/rotate6.c: fixed char literals,
1046           all compile, all run =8-D
1047
1048         * src/pic/pcode.h: added isPCASMDIR macro
1049         * src/pic/gen.c (genAnd): fixed bit offset
1050         * src/pic/ralloc.c (allocNewDirReg,allocDirReg,allocRegByName,
1051           packBits): unified register numbering schemes,
1052           (newReg): do not insert stack registers into hash table,
1053           (initStack): unpinned pseudo stack, simplified,
1054           (typeRegWithIdx): fixed retrieval of stack registers,
1055         * src/pic/pcode.c (addpCodeComment,sameBank): added,
1056           (pCodeReplace): removed invalid assertion,
1057           (insertPCodeInstruction): fixed newly added labels,
1058           (insertBankSwitch,BankSelect,IsBankChange,DoBankSelect,
1059           FixRegisterBankingInFlow,compareBankFlow,FixBankFlow,
1060           DumpFlow): removed unsed (broken?) code,
1061           (insertBankSel): prevent STATUS from being BANKSELed,
1062           (FixRegisterBanking): rewritten from scratch, implemented generic
1063             optimizations (suppress BANKSELs to same register and to registers
1064             present in all banks),
1065           (AnalyzeBanking): update flow after BANKSELection
1066
1067         * src/pic/glue.c (pic14_constructAbsMap): emit pseudo stack in
1068             sharebank, let linker place it, mark STKxx symbols as emitted
1069
1070 2006-11-21 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1071
1072         * src/regression/arrays.c,
1073         * src/regression/bank1.c,
1074         * src/regression/bool2.c,
1075         * src/regression/compare7.c,
1076         * src/regression/compare8.c,
1077         * src/regression/compare9.c,
1078         * src/regression/compare10.c,
1079         * src/regression/configword.c,
1080         * src/regression/for.c,
1081         * src/regression/mult1.c,
1082         * src/regression/pointer1.c,
1083         * src/regression/rotate6.c,
1084         * src/regression/string1.c,
1085         * src/regression/struct1.c,
1086         * src/regression/Makefile: make PIC14 regression tests run again
1087           (3 fail, 6 won't compile)
1088
1089 2006-11-21 Raphael Neider <rneider AT web.de>
1090
1091         * device/include/pic16/pic18f4550.h,
1092         * device/include/pic16/pic18f4455.h,
1093         * device/lib/pic16/libdev/pic18f4550.c,
1094         * device/lib/pic16/libdev/pic18f4455.c: fixed #1578591 and #1595144
1095         * configure.in: removed superfluous closing bracket
1096
1097 2006-11-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1098
1099         * device/lib/expf.c: Fixed bug 1599523: result of expf(x) is
1100           always positive.
1101
1102 2006-11-21 Raphael Neider <rneider AT web.de>
1103
1104         * src/pic/device.{c,h}: added pic14_getPIC()
1105         * src/pic/gen.c (continueIfTrue,jumpIfTrue): added PIC code,
1106           (genAnd): added PIC code for one case, fixes #1597044
1107         * src/pic/pcode.c (BankSelect): Ohoh, added generic optimization for
1108           SFRs that are present in all banks (e.g., STATUS)
1109
1110 2006-11-20 Raphael Neider <rneider AT web.de>
1111
1112         * src/pic/pcode.c: changed inverted ops for DECFSZ/DECFSZW and
1113           INCFSZ/INCFSZW and declared them as changing Z bit,
1114           (insertPCodeInstruction): correctly invert the above instructions,
1115           fixes #1599333,
1116           (DoBankSelect): don't panic on po_immediates
1117
1118 2006-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1119
1120         * as/link/aslink.h,
1121         * as/link/mcs51/lkihx.c (newArea),
1122         * as/link/mcs51/lkrloc.c: renamed newArea() to ihxNewArea()
1123         * as/link/mcs51/lkihx.c (ihx): output reset vector as start address
1124
1125 2006-11-11 Raphael Neider <rneider AT web.de>
1126
1127         * src/pic/pcode.c (newpCodeOpBit): search SymbolTab for referenced
1128           bitfield symbols, fixes #1579535 (once more...).
1129
1130 2006-11-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1131
1132         * support/regression/generate-cases.py,
1133         * support/regression/fwk/include/testfwk.h,
1134         * support/regression/fwk/lib/testfwk.c: used code pointers,
1135           (about 50kByte less code generated for mcs51)
1136
1137 2006-11-06 Borut Razem <borut.razem AT siol.net>
1138
1139         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
1140           debugger/mcs51/configure: fixed failed check because the function
1141           rl_function_of_keyseq isn't in Readline 5.2. Thanks to Ilya Goldberg
1142           who submitted the patch for gpsim.
1143         * debugger/mcs51/configure.in: removed the result message
1144         * debugger/mcs51/Makefile.in: fixed the config.status warning
1145           "... seems to ignore the --datarootdir setting"
1146
1147 2006-11-03 Maarten Brock <sourceforge.brock AT dse.nl>
1148
1149         * device/include/mcs51/c8051f020.h,
1150         * device/include/mcs51/c8051f040.h,
1151         * device/include/mcs51/c8051f060.h,
1152         * device/include/mcs51/c8051f120.h: added PS0, fixed bug 1589279
1153         * src/z80/gen.c (gencjneshort),
1154         * src/z80/peeph.def: applied patch 1571373, thanks Philipp Krause
1155
1156 2006-10-31 Borut Razem <borut.razem AT siol.net>
1157
1158         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
1159           debugger/mcs51/configure: get readline version
1160
1161 2006-10-30 Borut Razem <borut.razem AT siol.net>
1162
1163         * debugger/mcs51/sdcdb.c: replaced hardcoded "/" with DIR_SEPARATOR_STRING
1164         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
1165           debugger/mcs51/configure: locate readline even when cross compiling
1166         * support/scripts/sdcc.nsi: include readline5.dll into the setup package
1167
1168 2006-10-29 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1169
1170         * device/include/mcs51/serial_IO.h: putchar() and getchar() using
1171           serial port.
1172
1173 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
1174
1175         * device/include/malloc.h,
1176         * device/lib/calloc.c,
1177         * device/lib/free.c,
1178         * device/lib/malloc.c,
1179         * device/lib/realloc.c: moved definition of struct into sources
1180         * support/regression/tests/malloc.c: use void* for init_dynamic_memory()
1181
1182 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
1183
1184         * as/asx8051.dsp: corrected output directories
1185         * as/link/hc08: new directory for hc08 linker
1186         * as/hc08/aslink.h,             as/link/aslink.h,
1187         * as/hc08/aslink.mak,           as/link/hc08/aslink.mak,
1188         * as/hc08/clean.mk,             as/link/hc08/clean.mk,
1189         * as/hc08/link_hc08.dsp,        as/link/hc08/link_hc08.dsp,
1190         * as/hc08/lkaomf51.c,           as/link/hc08/lkaomf51.c,
1191         * as/hc08/lkarea.c,             as/link/hc08/lkarea.c,
1192         * as/hc08/lkdata.c,             as/link/hc08/lkdata.c,
1193         * as/hc08/lkelf.c,              as/link/hc08/lkelf.c,
1194         * as/hc08/lkihx.c,              as/link/hc08/lkihx.c,
1195         * as/hc08/lklibr.c,             as/link/hc08/lklibr.c,
1196         * as/hc08/lkmain.c,             as/link/hc08/lkmain.c,
1197         * as/hc08/lkmem.c,              as/link/hc08/lkmem.c,
1198         * as/hc08/lkrloc.c,             as/link/hc08/lkrloc.c,
1199         * as/hc08/lks19.c,              as/link/hc08/lks19.c,
1200         * as/hc08/Makefile.aslink,      as/link/hc08/Makefile.aslink,
1201         * as/hc08/Makefile.bcc,         as/link/hc08/Makefile.bcc,
1202         * as/hc08/Makefile.in,          as/link/hc08/Makefile.in,
1203         * as/link/hc08/conf.mk,
1204         * configure,
1205         * configure.in,
1206         * Makefile.in,
1207         * sdcc.dsw: moved hc08 linker to as/link/hc08
1208         * as/hc08/lkeval.c,     as/link/mcs51/lkeval.c,     as/link/lkeval.c,
1209         * as/hc08/lkhead.c,     as/link/mcs51/lkhead.c,     as/link/lkhead.c,
1210         * as/hc08/lklex.c,      as/link/mcs51/lklex.c,      as/link/lklex.c,
1211         * as/hc08/lklist.c,     as/link/mcs51/lklist.c,     as/link/lklist.c,
1212         * as/hc08/lknoice.c,    as/link/mcs51/lknoice.c,    as/link/lknoice.c,
1213         * as/hc08/lksym.c,      as/link/mcs51/lksym.c,      as/link/lksym.c,
1214         * as/link/mcs51/aslink.dsp,
1215         * as/link/mcs51/Makefile.in: factored out the common files
1216         * as/hc08/lkstore.c: deleted, use the one already in as/link/
1217         * as/clean.mk: extra cleaning common files
1218         * as/link/mcs51/strcmpi.c,      as/strcmpi.c: moved
1219         * as/link/mcs51/strcmpi.h: deleted, moved protoype to aslink.h
1220         * as/mcs51/asm.h: include sdccconf.h or sdcc_vc.h
1221
1222 2006-10-29 Raphael Neider <rneider AT web.de>
1223
1224         * src/pic/ralloc.c (newReg): create aliases for registers with
1225           multiple names to fix #1579535 and #1584001,
1226           (regWithIdx,dirregWithName): resolve aliases on lookup
1227         * src/pic/pcode.c (DoBankSelect): die with error message on failing
1228           bankselect
1229         * device/lib/pic/libdev/Makefile.in: move pseudo stack down to 0x4f
1230           to prevent build errors on small devices
1231
1232 2006-10-28 Raphael Neider <rneider AT web.de>
1233
1234         * src/pic/gen.c (genFunction,genCall): drop "same code page"
1235           assumption within interrupt handlers, fixes #1584940
1236         * src/pic/glue.c (pic14_constructAbsMap): mark absolute symbols as
1237           "emitted" to avoid emitting them again in udata
1238
1239 2006-10-27 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1240
1241         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
1242         Removed.
1243
1244 2006-10-26 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1245
1246         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
1247         Initialize uart only if SM0 and SM1 are zero.  Also, use flag to turn
1248         on/off CR to CRLF conversion.
1249
1250 2006-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1251
1252         * doc/sdccman.lyx: updated IRQ section
1253
1254 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1255
1256         * device/lib/serial_io.c: removed
1257         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c
1258         replacements for serial_io.c
1259
1260 2006-10-24 Maarten Brock <sourceforge.brock AT dse.nl>
1261
1262         * src/z80/main.c (_process_pragma, _parseOptions): fixed bug 1583318
1263
1264 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1265
1266         * device/lib/serial_io.c: Default putchar() and getchar() for
1267           mcs51 uses serial port.
1268
1269 2006-10-23 Maarten Brock <sourceforge.brock AT dse.nl>
1270
1271         * src/mcs51/gen.c (movc): improved check for 0 and 1, see RFE 1582704
1272
1273 2006-10-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1274
1275         * support/regression/ports/mcs51/support.c: smaller
1276         _sdcc_external_startup()
1277         * device/lib/mcs51/crtxclear.asm: don't check high byte of l_PSEG
1278
1279 2006-10-20 Maarten Brock <sourceforge.brock AT dse.nl>
1280
1281         * device/lib/gbz80/crt0.s,
1282         * device/lib/gbz80/crt0_rle.s,
1283         * device/lib/gbz80/div.s,
1284         * device/lib/gbz80/fstubs.s,
1285         * device/lib/gbz80/heap.s,
1286         * device/lib/gbz80/mul.s,
1287         * device/lib/gbz80/putchar.s,
1288         * device/lib/gbz80/stubs.s,
1289         * device/lib/z80/crt0.s,
1290         * device/lib/z80/crt0_rle.s,
1291         * device/lib/z80/div.s,
1292         * device/lib/z80/fstubs.s,
1293         * device/lib/z80/heap.s,
1294         * device/lib/z80/mul.s,
1295         * device/lib/z80/putchar.s,
1296         * device/lib/z80/stubs.s: reverted, I was mistaken
1297
1298 2006-10-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1299
1300         * src/mcs51/peeph.def: peephole 238.x added check for notvolatile
1301         * support/regression/ports/mcs51/support.c: removed race
1302         condition on TI in _putchar allowing to use serial port mode 0
1303
1304 2006-10-20 Borut Razem <borut.razem AT siol.net>
1305
1306         * debugger/mcs51/sdcdb.c: replaced isblank() with isspace()
1307
1308 2006-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
1309
1310         * device/lib/gbz80/crt0.s,
1311         * device/lib/gbz80/crt0_rle.s,
1312         * device/lib/gbz80/div.s,
1313         * device/lib/gbz80/fstubs.s,
1314         * device/lib/gbz80/heap.s,
1315         * device/lib/gbz80/mul.s,
1316         * device/lib/gbz80/putchar.s,
1317         * device/lib/gbz80/stubs.s,
1318         * device/lib/z80/crt0.s,
1319         * device/lib/z80/crt0_rle.s,
1320         * device/lib/z80/div.s,
1321         * device/lib/z80/fstubs.s,
1322         * device/lib/z80/heap.s,
1323         * device/lib/z80/mul.s,
1324         * device/lib/z80/putchar.s,
1325         * device/lib/z80/stubs.s: removed all leading underscores from area names
1326
1327 2006-10-17 Maarten Brock <sourceforge.brock AT dse.nl>
1328
1329         * support/regression/ports/mcs51/support.c: use highest baudrate so the
1330           regression tests are not waiting in the simulator for simulated
1331           transmission of debug output
1332
1333 2006-10-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1334
1335         * device/lib/printf_large.c: slightly smaller
1336         * doc/sdccman.lyx: do not use spaces within html links
1337
1338 2006-10-16 Borut Razem <borut.razem AT siol.net>
1339
1340         * configure.in, configure, sdccconf_in.h, src/SDCCglobal,
1341           debugger/mcs51/Makefile.in, debugger/mcs51/sdcdb.[ch],
1342           debugger/mcs51/aclocal.m4, debugger/mcs51/acinclide.m4,
1343           debugger/mcs51/config.h.in, debugger/mcs51/configure.in,
1344           debugger/mcs51/configure:
1345           [ 1185668 ] add gnu readline support to sdcdb - enabled
1346
1347 2006-10-16 Raphael Neider <rneider AT web.de>
1348
1349         * src/pic/pcode.c (BankSelect): another fix on (partial) BANKSELs,
1350           fixes #1577882, removes close to all banking optimizations
1351
1352 2006-10-15 Maarten Brock <sourceforge.brock AT dse.nl>
1353
1354         * src/SDCCsymt.c (checkSClass): no error for uninitialised absolute
1355           variables in code memory
1356         * support/regression/tests/absolute.c: added test for this
1357
1358 2006-10-15 Raphael Neider <rneider AT web.de>
1359
1360         * src/pic/pcode.c (InsertBankSel): suppress BANKSELs for one bank
1361           devices,
1362           (BankSelect): emit BANKSEL before touching linker-placed regs,
1363           fixes #1570934
1364
1365 2006-10-10 Raphael Neider <rneider AT web.de>
1366
1367         * src/SDCCmain.c (optionsTable): accept --stack-size for PICs,
1368         * src/pic/device.c (pic14_getSharebankSize,pic14_getSharebankAddress),
1369         * src/pic/main.c (_pic14_parseOptions),
1370         * src/pic/main.h: mostly reverted to previous state, now use results
1371             from SDCCmain.c's argument parsing
1372
1373 2006-10-10 Borut Razem <borut.razem AT siol.net>
1374
1375         * debugger/mcs51/break.[ch], debugger/mcs51/cmd.c,
1376           debugger/mcs51/sdcdb.[ch], debugger/mcs51/simi.c:
1377           [ 1185668 ] add gnu readline support to sdcdb -
1378           prepared for READLINE, not enabled yet,
1379           thanks to <tal.bav AT gmail.com>
1380
1381 2006-10-10 Raphael Neider <rneider AT web.de>
1382
1383         * src/pic16/pcode.c (pic16_pCode2str): use isACCESS_BANK macro
1384         * src/pic16/devices.inc,
1385         * device/include/pic16 (pic18f[24]620.h),
1386         * device/include/pic18fregs.h,
1387         * device/lib/pic16/pics.all,
1388         * device/lib/pic16/libdev/pic18f[24]{620,525}.c): added support for
1389             18f2620, 18f4620, 18f2525, and 18f4525 devices, thanks to
1390             Gary Plumbridge and Anton Strobl
1391
1392 2006-10-10 Raphael Neider <rneider AT web.de>
1393
1394         * src/pic/main.c (_pic14_parseOptions): added --stack-loc=NUM and
1395           --stack-siz=NUM options to configure the argument passing stack
1396         * src/pic/main.h: added stackLocation and stackSize to pic14_options_t
1397         * src/pic/device.c (mapRegister): catch out-of-memory SIGSEGVs,
1398           (pic14_getSharebankSize): obey --stack-siz=NUM,
1399           (pic14_getSharebankAddress): obey --stack-loc=NUM
1400
1401 2006-10-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1402
1403         * doc/sdccman.lyx: added to the manual
1404         * doc/figures/ddd_example.png: added (neither pdflatex nor
1405         most browsers seem to like the .eps file)
1406
1407 2006-10-06 Bernhard Held <bernhard AT bernhardheld.de>
1408
1409         * src/SDCCglue.c (tempfileandname): changed un*x tmp search paths
1410         to /tmp and /var/tmp acc. LSB
1411         * src/SDCCast.c (addCast): Fixed bug 1571231: promote in case of
1412         RESULT_TYPE_IFX
1413         * support/regression/tests/onebyte.c: added test
1414
1415 2006-10-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1416
1417         * src/mcs51/gen.c: emitcode for "add a,0x%02x" requires only 8 bits.
1418
1419 2006-10-05 Borut Razem <borut.razem AT siol.net>
1420
1421         * partially fixed [ 1570701 ] peephole - not replacing code from multiline macros,
1422           thanks to dfulab:
1423           - sdcc.dsw: changed property eol-style to CRLF
1424           - support/scripts/resource.rc: replaced references to "afxres.h" with "winres.h"
1425
1426 2006-10-04 Raphael Neider <rneider AT web.de>
1427
1428         * device/include/pic/{pic16f84.h,pic16f84a.h},
1429         * device/lib/pic/libdev/{pic16f84.c,pic16f84a.c}: added PORT[AB]_bits
1430           from patch #1522504, thanks to Robas Teodor
1431
1432 2006-10-02 Maarten Brock <sourceforge.brock AT dse.nl>
1433
1434         * as/link/z80/lkarea.c: essentially reverted lnksect() to #4380 which
1435           fixes bug 1566015
1436
1437 2006-10-01 Maarten Brock <sourceforge.brock AT dse.nl>
1438
1439         * src/pic16/glue.c (pic16emitMaps),
1440         * src/pic/glue.c (pic14emitMaps): hopefully fixed bug 1568779
1441         * device/lib/gets.c: fixed bug 1568829,thanks Philipp Krause
1442         * device/lib/pic16/libc/string/memcpypgm2ram.c,
1443         * device/lib/pic16/libc/string/memcpyram2ram.c: fixed bug 1568836, thanks
1444           Philipp Krause
1445         * as/mcs51/asmain.c (asmbl, newdot): fixed problems with absolute areas
1446         * as/link/mcs51/lkmem.c (summary2): reverted, do do count abs segments
1447
1448 2006-09-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1449
1450         * support/librarian/sdcclib.c: Added option -l.
1451         * as/link/mcs51/lkmem.c: don't use absolute segments to compute memory
1452           usage totals.
1453         * device/lib/make51lib.bat: added.  Allows building mcs51 libraries easily
1454           using Windows command prompt.
1455
1456 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
1457
1458         * device/lib/libsdcc.lib: added module rand
1459         * src/ds390/ralloc.c (rematStr),
1460         * src/hc08/ralloc.c (rematStr),
1461         * src/mcs51/ralloc.c (rematStr),
1462         * src/z80/ralloc.c (rematStr): made output more consistent
1463         * src/mcs51/gen.c: cosmetic changes
1464
1465 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
1466
1467         * src/port.h: added mem.cabs_name to PORT
1468         * src/ds390/main.c,
1469         * src/hc08/main.c,
1470         * src/mcs51/main.c,
1471         * src/pic16/main.c,
1472         * src/pic/main.c,
1473         * src/xa51/main.c,
1474         * src/z80/main.c: added cabs_name initializers
1475         * src/SDCCglue.c (emitStaticSeg): allocate and initialize absolute
1476           constants
1477           (emitMaps): emit absolutes in code memory into cabs_name
1478         * src/SDCCmem.c,
1479         * src/SDCCmem.h: added memory map c_abs and defined CABS_NAME
1480         * src/ds390/gen.c (genCodePointerGet): fixed bug if left is a literal
1481         * support/regression/fwk/include/testfwk.h: added define for at
1482         * support/regression/tests/absolute.c: added, new
1483
1484 2006-09-29 Maarten Brock <sourceforge.brock AT dse.nl>
1485
1486         * src/mcs51/gen.c (genPlusIncr, genMinusDec, genAddrOf): small
1487           optimizations, see also patch 887161 by Stas Sergeev
1488         * src/mcs51/peeph.def(104, 207, 209, 212): disabled as they do not seem
1489           to be necessary anymore,
1490           (102, 103, 104, 127): renamed all occurances of bp to _bp
1491
1492 2006-09-27 Maarten Brock <sourceforge.brock AT dse.nl>
1493
1494         * device/include/mcs51/at89c51snd1c.h: fixed MSK_SREQ definition
1495           thanks Weston T. Schmidt for patch 1555221
1496         * src/mcs51/peeph.def: renamed rule 257 to 257.a, added 257.b
1497         * src/SDCCicode.c(geniCodeMultiply): small optimization
1498
1499 2006-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
1500
1501         * device/include/stdlib.h: added rand prototypes
1502         * device/lib/rand.c: new, added
1503         * device/lib/Makefile.in: added rand.c
1504         * src/z80/peeph.def,
1505         * src/z80/peeph-gbz80.def,
1506         * src/z80/peeph-z80.def: updated conditonals, fixed bug 1565908
1507
1508 2006-09-20 Raphael Neider <rneider AT web.de>
1509
1510         * device/lib/pic16/libio/i2c/i2cnack.c (i2c_nack): fixed ACKDT bit
1511
1512 2006-09-19 Maarten Brock <sourceforge.brock AT dse.nl>
1513
1514         * as/link/aslink.h: cosmetic changes
1515         * as/link/mcs51/Makefile.in,
1516         * as/link/z80/Makefile.in: fixed build on CF where VPATH is used
1517
1518 2006-09-17 Maarten Brock <sourceforge.brock AT dse.nl>
1519
1520         * as/link/aslink.h,
1521         * as/link/mcs51/aslink.h,
1522         * as/link/z80/aslink.h: merged and moved to as/link/
1523         * as/link/lkstore.c,
1524         * as/link/mcs51/lkstore.c: moved to as/link/
1525         * as/link/clean.mk: remove *.o
1526         * as/link/mcs51/alloc.h: deleted
1527         * as/link/mcs51/lkarea.c: added lnksect prototype
1528         * as/link/mcs51/lkdata.c,
1529         * as/link/mcs51/lklex.c,
1530         * as/link/mcs51/lkmain.c: renamed as_getline to lk_getline
1531         * as/link/mcs51/lkmem.c,
1532         * as/link/mcs51/lknoice.c: removed include strcmpi.h
1533         * as/link/mcs51/lksym.c: include stdlib.h instead of malloc.h or alloc.h
1534         * as/link/mcs51/aslink.dsp,
1535         * as/link/mcs51/Makefile.aslink,
1536         * as/link/mcs51/Makefile.bcc,
1537         * as/link/mcs51/Makefile.in: updated for moved files
1538         * as/link/z80/lkarea.c,
1539         * as/link/z80/lkhead.c,
1540         * as/link/z80/lklex.c,
1541         * as/link/z80/lklibr.c,
1542         * as/link/z80/lklist.c,
1543         * as/link/z80/lkmain.c,
1544         * as/link/z80/lkrloc.c,
1545         * as/link/z80/lksym.c: synced with mcs51
1546         * as/link/z80/lkdata.c,
1547         * as/link/z80/lkeval.c,
1548         * as/link/z80/lkihx.c,
1549         * as/link/z80/lks19.c: cosmetic changes
1550         * as/link/z80/Makefile.in,
1551         * as/link/z80/linkgbz80.dsp,
1552         * as/link/z80/linkz80.dsp: updated for moved files
1553
1554 2006-09-16 Borut Razem <borut.razem AT siol.net>
1555
1556         * debugger/mcs51/sdcdb.c: partially fixed
1557           [ 1203664 ] sdcdb fails to open files w. two "." periods
1558         * debugger/mcs51/simi.c, debugger/mcs51/symtab.c,
1559           debugger/mcs51/symtab.h: fixed indenting
1560         * configure.in, configure: up to date with latest Maarten's changes
1561
1562 2006-09-15 Maarten Brock <sourceforge.brock AT dse.nl>
1563
1564         as/link/mcs51
1565         as/aslink.dsp,                  as/link/mcs51/aslink.dsp,
1566         as/link/mcs51/aslink.h,         as/mcs51/aslink.h,
1567         as/link/mcs51/aslink.mak,       as/mcs51/aslink.mak,
1568         as/link/mcs51/lkaomf51.c,       as/mcs51/lkaomf51.c,
1569         as/link/mcs51/lkarea.c,         as/mcs51/lkarea.c,
1570         as/link/mcs51/lkdata.c,         as/mcs51/lkdata.c,
1571         as/link/mcs51/lkeval.c,         as/mcs51/lkeval.c,
1572         as/link/mcs51/lkhead.c,         as/mcs51/lkhead.c,
1573         as/link/mcs51/lkihx.c,          as/mcs51/lkihx.c,
1574         as/link/mcs51/lklex.c,          as/mcs51/lklex.c,
1575         as/link/mcs51/lklibr.c,         as/mcs51/lklibr.c,
1576         as/link/mcs51/lklist.c,         as/mcs51/lklist.c,
1577         as/link/mcs51/lkmain.c,         as/mcs51/lkmain.c,
1578         as/link/mcs51/lkmem.c,          as/mcs51/lkmem.c,
1579         as/link/mcs51/lknoice.c,        as/mcs51/lknoice.c,
1580         as/link/mcs51/lkrloc.c,         as/mcs51/lkrloc.c,
1581         as/link/mcs51/lks19.c,          as/mcs51/lks19.c,
1582         as/link/mcs51/lkstore.c,        as/mcs51/lkstore.c,
1583         as/link/mcs51/lksym.c,          as/mcs51/lksym.c,
1584         as/link/mcs51/Makefile.aslink,  as/mcs51/Makefile.aslink,
1585         as/link/mcs51/alloc.h,
1586         as/link/mcs51/clean.mk,
1587         as/link/mcs51/conf.mk,
1588         as/link/mcs51/Makefile.bcc,
1589         as/link/mcs51/Makefile.in,
1590         as/link/mcs51/readme.390,
1591         as/link/mcs51/strcmpi.c,
1592         as/link/mcs51/strcmpi.h,
1593         as/mcs51/clean.mk,
1594         as/mcs51/Makefile.bcc,
1595         as/mcs51/Makefile.in,
1596         configure,
1597         Makefile.in,
1598         sdcc.dsw: moved mcs51 linker to as/link/mcs51
1599
1600 2006-09-14 Maarten Brock <sourceforge.brock AT dse.nl>
1601
1602         * as/link,
1603         * as/link/Makefile.in,
1604         * as/link/z80/linkgbz80.dsp,
1605         * as/link/z80/linkz80.dsp,
1606         * configure,
1607         * link,
1608         * link/clean.mk,
1609         * link/Makefile.in,
1610         * link/README,
1611         * link/z80,
1612         * link/z80/aslink.h,
1613         * link/z80/clean.mk,
1614         * link/z80/conf.mk,
1615         * link/z80/linkgbz80.dsp,
1616         * link/z80/linkz80.dsp,
1617         * link/z80/lkarea.c,
1618         * link/z80/lkdata.c,
1619         * link/z80/lkeval.c,
1620         * link/z80/lkgb.c,
1621         * link/z80/lkgg.c,
1622         * link/z80/lkhead.c,
1623         * link/z80/lkihx.c,
1624         * link/z80/lklex.c,
1625         * link/z80/lklibr.c,
1626         * link/z80/lklist.c,
1627         * link/z80/lkmain.c,
1628         * link/z80/lkrloc.c,
1629         * link/z80/lks19.c,
1630         * link/z80/lksym.c,
1631         * link/z80/Makefile.in,
1632         * Makefile.in,
1633         * sdcc.dsw: moved link/ to as/link/
1634
1635 2006-09-11 Maarten Brock <sourceforge.brock AT dse.nl>
1636
1637         * as/mcs51/i51mch.c (machine): fixed warning
1638
1639 2006-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
1640
1641         * as/mcs51/i51mch.c (machine): S_DJNZ fixed bug 1554318
1642
1643 2006-09-09 Borut Razem <borut.razem AT siol.net>
1644
1645         * debugger/mcs51/sdcdb.c, debugger/mcs51/simi.c:
1646           sdcdb WIN32 native port
1647         * src/clean.mk: fixed
1648
1649 2006-09-08 Borut Razem <borut.razem AT siol.net>
1650
1651         * doc/sdccman.lyx: SDCDB and ucSim are available on Win32 platforms.
1652
1653 2006-09-08 Raphael Neider <rneider AT web.de>
1654
1655         * src/pic16/main.c (_pic16_linkEdit,pic16_linkCmd),
1656         * src/pic/main.c(_pic14_do_link, linkCmd): pass "-w" and "-r"
1657             to gplink to disable processor mismatch warning and to allow
1658             the use of devices with only aliased (shared) memory banks,
1659           (_pic16_genAssemblerPreamble): include pXXX.inc on --mplab-comp
1660
1661 2006-09-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1662
1663         * doc/sdccman.lyx: Some re-formating plus example on using
1664           #pragma preproc_asm +/-
1665
1666 2006-09-07 Borut Razem <borut.razem AT siol.net>
1667
1668         * support/scripts/sdcc.nsi: added SDCDB executables in a separate
1669           section
1670
1671 2006-09-06 Borut Razem <borut.razem AT siol.net>
1672
1673         * support/scripts/sdcc.nsi: fixed Error: unterminated string parsing
1674           line at sdcc.nsi:153
1675         * sdcc/debugger/mcs51/simi.c: argsToCmdLine() fixes
1676
1677 2006-09-05 Borut Razem <borut.razem AT siol.net>
1678
1679         * configure.in, configure: support for winsock2
1680         * debugger/mcs51/break.h, debugger/mcs51/cmd.c,
1681           debugger/mcs51/cmd.h, debugger/mcs51/sdcdb.c,
1682           debugger/mcs51/sdcdb.h, debugger/mcs51/simi.c,
1683           debugger/mcs51/simi.h, debugger/mcs51/symtab.c,
1684           debugger/mcs51/symtab.h: sdcdb WIN32 native port
1685
1686 2006-09-05 Maarten Brock <sourceforge.brock AT dse.nl>
1687
1688         * src/SDCCopt.c (cnvToFcall): fixed bug 1551947 by updating OP_USES
1689           and OP_DEFS
1690         * support/regression/tests/bug1551947.c: new, added
1691         * src/SDCCsymt.h: strings are char* not byte*
1692
1693 2006-09-05 Raphael Neider <rneider AT web.de>
1694
1695         * device/lib/pic16/libdev/pic18f4550.c,
1696           device/include/pic16/pic18f4550.h: added PORTD/TRISD
1697             declarations/definitions from patch #1520949
1698
1699 2006-09-05 Raphael Neider <rneider AT web.de>
1700
1701         * src/pic16/gen.c (genPackBits): fix assignment to 8-bit,
1702           byte-aligned bitfields, fixes #1539278
1703
1704 2006-09-05 Raphael Neider <rneider AT web.de>
1705
1706         * src/pic/gen.c (genReceive): skip unreferenced arguments,
1707           fixes #1544120
1708
1709 2006-09-04 Borut Razem <borut.razem AT siol.net>
1710
1711         * support/scripts/sdcc.nsi: move ucSim executables to a separate section
1712         * support/scripts/sdcc_cygwin_mingw32: don't disable ucsim,
1713           -mno-cygwin is a part of the compiler name
1714         * support/scripts/sdcc_mingw32: don't disable ucsim
1715
1716 2006-09-03 Borut Razem <borut.razem AT siol.net>
1717
1718         * sdcc.spec: corrected for 2.6.0. Thanks to Christer Weinigel.
1719         * device/lib/Makefile.in device/lib/clean.mk: small but essential corrections
1720
1721 2006-09-03 Raphael Neider <rneider AT web.de>
1722
1723         * src/pic/ralloc.c,
1724         * src/pic/pcode.c (InitReuseRegs): allocate registers with pseudo
1725           indices >= 0x1000 to disambiguate them from fixed regs __at(addr),
1726           fixes #1550049
1727
1728 2006-09-01 Borut Razem <borut.razem AT siol.net>
1729
1730         * sim/ucsim/cmd.src/cmdutil.cc: #include <sys/time.h> and <unistd.h>
1731           to make ppc-osx happy
1732
1733 2006-08-31 Borut Razem <borut.razem AT siol.net>
1734
1735         * sim/ucsim/cmd.src/newcmdposix.cc: #include <assert.h>
1736         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
1737         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
1738         * support/regression/ports/ds390/spec.mk,
1739           support/regression/ports/mcs51/spec.mk,
1740           support/regression/ports/xa51/spec.mk: introduced DEV_NULL variable.
1741           To run regression tests in mingw environment:
1742           make DEV_NULL=NUL CC=gcc
1743
1744 2006-08-30 Borut Razem <borut.razem AT siol.net>
1745
1746         * sim/ucsim/cmd.src/newcmdposix.cc, sim/ucsim/cmd.src/newcmdposixcl.h,
1747           sim/ucsim/cmd.src/newcmdwin32.cc, sim/ucsim/cmd.src/newcmdwin32cl.h,
1748           sim/ucsim/app.cc, sim/ucsim/appcl.h, sim/ucsim/configure,
1749           sim/ucsim/configure.in, sim/ucsim/ddconfig_in.h, sim/ucsim/error.cc,
1750           sim/ucsim/errorcl.h, sim/ucsim/option.cc, sim/ucsim/optioncl.h,
1751           sim/ucsim/utils.cc, sim/ucsim/utils.h, sim/ucsim/cmd.src/Makefile.in,
1752           sim/ucsim/avr.src/avr.cc, sim/ucsim/avr.src/avrcl.h,
1753           sim/ucsim/cmd.src/bp.cc, sim/ucsim/cmd.src/bpcl.h,
1754           sim/ucsim/cmd.src/cmdconf.cc, sim/ucsim/cmd.src/cmdgui.cc,
1755           sim/ucsim/cmd.src/cmdmem.cc, sim/ucsim/cmd.src/cmdset.cc,
1756           sim/ucsim/cmd.src/cmdsetcl.h, sim/ucsim/cmd.src/cmdstat.cc,
1757           sim/ucsim/cmd.src/cmduc.cc, sim/ucsim/cmd.src/cmduccl.h,
1758           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
1759           sim/ucsim/cmd.src/command.cc, sim/ucsim/cmd.src/commandcl.h,
1760           sim/ucsim/cmd.src/get.cc, sim/ucsim/cmd.src/getcl.h,
1761           sim/ucsim/cmd.src/info.cc, sim/ucsim/cmd.src/newcmd.cc,
1762           sim/ucsim/cmd.src/newcmdcl.h, sim/ucsim/cmd.src/set.cc,
1763           sim/ucsim/cmd.src/show.cc, sim/ucsim/cmd.src/timer.cc,
1764           sim/ucsim/hc08.src/hc08.cc, sim/ucsim/hc08.src/hc08cl.h,
1765           sim/ucsim/s51.src/Makefile.in, sim/ucsim/s51.src/interrupt.cc,
1766           sim/ucsim/s51.src/interruptcl.h, sim/ucsim/s51.src/pca.cc,
1767           sim/ucsim/s51.src/pcacl.h, sim/ucsim/s51.src/port.cc,
1768           sim/ucsim/s51.src/portcl.h, sim/ucsim/s51.src/serial.cc,
1769           sim/ucsim/s51.src/serialcl.h, sim/ucsim/s51.src/timer0.cc,
1770           sim/ucsim/s51.src/timer0cl.h, sim/ucsim/s51.src/timer1.cc,
1771           sim/ucsim/s51.src/timer1cl.h, sim/ucsim/s51.src/timer2.cc,
1772           sim/ucsim/s51.src/timer2cl.h, sim/ucsim/s51.src/uc390.cc,
1773           sim/ucsim/s51.src/uc390cl.h, sim/ucsim/s51.src/uc390hw.cc,
1774           sim/ucsim/s51.src/uc390hwcl.h, sim/ucsim/s51.src/uc51.cc,
1775           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/wdt.cc,
1776           sim/ucsim/s51.src/wdtcl.h, sim/ucsim/sim.src/hw.cc,
1777           sim/ucsim/sim.src/hwcl.h, sim/ucsim/sim.src/mem.cc,
1778           sim/ucsim/sim.src/memcl.h, sim/ucsim/sim.src/obsolete.cc,
1779           sim/ucsim/sim.src/obsolete.h, sim/ucsim/sim.src/sim.cc,
1780           sim/ucsim/sim.src/simcl.h, sim/ucsim/sim.src/stack.cc,
1781           sim/ucsim/sim.src/stackcl.h, sim/ucsim/sim.src/test_mem_speed.cc,
1782           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1783           sim/ucsim/xa.src/xa.cc, sim/ucsim/xa.src/xacl.h,
1784           sim/ucsim/z80.src/z80.cc, sim/ucsim/z80.src/z80cl.h:
1785           ucsim WIN32 native port
1786
1787 2006-08-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1788
1789         * doc/sdccman.lyx: added note on dynamic memory heap initialization
1790
1791 2006-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
1792
1793         * src/mcs51/gen.c (genAnd, genOr, genXor): fixed bug 1546986
1794         * src/ds390/gen.c (aopGetUsesAcc): handle AOP_DPTR2 and AOP_DPTRn too
1795
1796 2006-08-26 Maarten Brock <sourceforge.brock AT dse.nl>
1797
1798         * src/ds390/gen.c (genAnd, genOr, genXor): fixed bug 1546986
1799         * support/regression/tests/bug1546986.c: new, added
1800         * as/mcs51/.cvsignore,
1801         * debugger/mcs51/.cvsignore,
1802         * src/.cvsignore: deleted
1803
1804 2006-08-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1805
1806         * device/include/mcs51/P89c51RD2.h: fixed bug 1546936 (error in sbit
1807           definitions)
1808
1809 2006-08-20 Borut Razem <borut.razem AT siol.net>
1810
1811         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h:
1812           removed cl_listen_console::match(), cl_console::match(),
1813           restructured cl_commander::proc_input()
1814
1815 2006-08-16 Borut Razem <borut.razem AT siol.net>
1816
1817         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h,
1818           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
1819           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/uc.cc: code cleaning
1820
1821 2006-08-14 Borut Razem <borut.razem AT siol.net>
1822
1823         * support/regression/Makefile.in,
1824           support/regression/ports/pic14/gpsim.cmd,
1825           support/regression/ports/pic14/spec.mk,
1826           support/regression/ports/pic14/support.c:
1827           added pic14 regression test
1828
1829 2006-08-14 Maarten Brock <sourceforge.brock AT dse.nl>
1830
1831         * as/doc/asxhtm.html: documented changed ABS behaviour
1832         * as/doc/README: fixed some typos
1833
1834 2006-08-13 Maarten Brock <sourceforge.brock AT dse.nl>
1835
1836         * support/regression/tests/float_trans.c: disabled test if __STDC_IEC_559__
1837           not defined on host
1838
1839 2006-08-12 Borut Razem <borut.razem AT siol.net>
1840
1841         * support/regression/fwk/include/testfwk.h,
1842           support/regression/fwk/lib/testfwk.c,
1843           support/regression/generate-cases.py,
1844           support/regression/Makefile.in:
1845           regression test framework does not depend on function pointers and
1846           variable arguments
1847
1848 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
1849
1850         * device/include/stddef.h: c temporary hack to fix bug 1518273
1851
1852 2006-08-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1853
1854         * device/include/mcs51/cc2510fx.h: added
1855         * src/z80/z80.dsp, src/gbz80/gbz80.dsp: added support/Util/strcmpi.ch
1856           to projects.
1857
1858 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
1859
1860         * as/z80/assym.c (mlookup): ignore case when looking up mnemonics
1861         * as/z80/Makefile.in: added strcmpi.c
1862         * as/z80/z80adr.c: added upper case registers and lower case conditionals
1863         * support/Util/strcmpi.ch: added with intention to remove from mcs51/hc08
1864
1865 2006-08-08 Maarten Brock <sourceforge.brock AT dse.nl>
1866
1867         * device/lib/gbz80/asm_strings.s,
1868         * device/lib/gbz80/crt0_rle.s,
1869         * device/lib/gbz80/div.s,
1870         * device/lib/gbz80/mul.s,
1871         * device/lib/gbz80/shift.s,
1872         * device/lib/z80/asm_strings.s,
1873         * device/lib/z80/crt0_rle.s,
1874         * device/lib/z80/div.s,
1875         * device/lib/z80/mul.s,
1876         * device/lib/z80/shift.s: changed to all lower case menmonics except the
1877           flags which are all upper case
1878
1879 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
1880
1881         * as/z80/asm.h: made CASE_SENSITIVE 1
1882         * link/z80/aslink.h: made CASE_SENSITIVE 1
1883         * src/z80/gen.c (throughout): made all conditionals upper case
1884         * support/regression/tests/bug1503067.c: new
1885
1886 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
1887
1888         * src/z80/gen.c (aopPut): fixed bug !*ixy should be !*iyx,
1889           (shiftIntoPair): added case 2 for PAIR_IY,
1890           (setupToPreserveCarry): replaced parameters with iCode and check if
1891            PAIR_DE is in use to fix bug 1399290,
1892           (genPlus, genMinus): updated call to setupToPreserveCarry
1893         * support/regression/tests/bug1399290.c: new
1894
1895 2006-08-06 Maarten Brock <sourceforge.brock AT dse.nl>
1896
1897         * device/lib/Makefile.in (Z80SOURCES): enabled float support
1898         * sim/ucsim/z80.src/inst.cc (inst_rst): generate breakpoint on RST8,ACC==0
1899         * src/ds390/gen.c (shiftRLong),
1900         * src/hc08/gen.c (shiftLLong, shiftRLong): fixed bug 1533966
1901         * src/mcs51/gen.c (sameReg): changed to sameByte,
1902           (xch_a_aopGet): new,
1903           (shiftL2Left2Result, shiftR2Left2Result, shiftRLeftOrResult, shiftLLong,
1904            shiftRLong): fixed bug 1533966
1905         * src/z80/gen.c (shiftR2Left2Result, shiftL2Left2Result, genlshTwo,
1906           genLeftShiftLiteral, genrshTwo, genRightShiftLiteral): fixed bug 1533966
1907         * support/regression/Makefile.in: disabled z80, enabled ucz80
1908         * support/regression/tests/float_trans.c: enabled test for z80 and host
1909         * support/regression/tests/shifts2.c: new, for testing bug 1533966
1910
1911 2006-08-01 Borut Razem <borut.razem AT siol.net>
1912
1913         * src/mcs51/gen.c, src/dc390/gen.c: fixed warning:
1914           comparison is always false due to limited range of data type
1915           on PPC64 machine (openpower-linux1) where "char = unsigned char"
1916
1917 2006-08-01 Maarten Brock <sourceforge.brock AT dse.nl>
1918
1919         * sim/ucsim/hc08.src/hc08mac.h: removed faulty and unused add_u16_disp
1920         * sim/ucsim/hc08.src/hc08.cc: removed faulty and unused int8
1921         * sim/ucsim/z80.src/z80mac.h (add_u16_disp): use explicit signed char cast
1922         * sim/ucsim/z80.src/z80.cc: removed faulty and unused int8
1923
1924 2006-07-31 Borut Razem <borut.razem AT siol.net>
1925
1926         * sim/ucsim/configure, sim/ucsim/cmd.src/newcmdcl.h,
1927           sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/cmdutil.cc,
1928           sim/ucsim/z80.src/Makefile.in, sim/ucsim/configure.in,
1929           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/hc08.src/hc08.cc,
1930           sim/ucsim/ddconfig_in.h, sim/ucsim/s51.src/Makefile.in,
1931           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/serialcl.h,
1932           sim/ucsim/s51.src/uc51.cc, sim/ucsim/s51.src/serial.cc,
1933           sim/ucsim/app.cc, sim/ucsim/avr.src/Makefile.in:
1934           enable ucsim mingw compilation. Serial port is disabled,
1935           since it uses termios.h API, which is not available on native
1936           WIN32
1937
1938 2006-07-31 Borut Razem <borut.razem AT siol.net>
1939
1940         * Small Device C Compiler 2.6.0 released
1941         * support/scripts/sdcc.nsi: added FULL_DOC option
1942         * .version, doc/sdccman.lyx: changed sdcc version to 2.6.1
1943
1944 2006-07-28 Borut Razem <borut.razem AT siol.net>
1945
1946         * support/scripts/sdcc.nsi: remove $INSTDIR/include/asm/pic16/*.h
1947         * doc/INSTALL.txt: updated
1948
1949 2006-07-27 Borut Razem <borut.razem AT siol.net>
1950
1951         * device/lib/pic/Makefile.in, device/lib/pic/Makefile.subdir,
1952           device/lib/pic/libdev/Makefile.in: fixed bug
1953           [ 1438354 ] pic libsdcc: distclean doesn't work
1954         * device/lib/pic16/Makefile.in, device/lib/pic16/Makefile.subdir,
1955           device/lib/pic16/libio/Makefile.in: fixed bug
1956           [ 1438344 ] pic16 lib: clean doesn't work properly
1957         * doc/knownbugs.html removed [ 1438354 ] and [ 1438344 ] from the list
1958
1959 2006-07-26 Maarten Brock <sourceforge.brock AT dse.nl>
1960
1961         * device/lib/pic/libsdcc/fsdiv.c,
1962         * device/lib/pic/libsdcc/fsmul.c,
1963         * device/lib/pic16/libsdcc/float/fsdiv.c,
1964         * device/lib/pic16/libsdcc/float/fsmul.c,
1965         * device/lib/_fsdiv.c,
1966         * device/lib/_fsmul.c: bugfix, handle too large and too small numbers
1967         * support/regression/tests/bug1520966.c: added
1968         * doc/knownbugs.html: removed [ 1520966 ] from the list
1969
1970 2006-07-25 Borut Razem <borut.razem AT siol.net>
1971
1972         * configure.in, configure, sdccconf_in.h: fixed bug
1973           [ 1519095 ] regression test onebyte.c fails on ppc64 host
1974         * doc/knownbugs.html: removed [ 1519095 ] from the list
1975
1976 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
1977
1978         * doc/knownbugs.html: added, contains list of known bugs at release
1979         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
1980
1981 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
1982
1983         * device/include/mcs51/compiler.h: added SFRX for xdata based special
1984           function registers and corrected defaults with additional warning
1985         * device/lib/malloc.c: cosmetic changes
1986         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
1987         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
1988           (fillGaps): and used it
1989
1990 2006-07-20 Raphael Neider <rneider AT web.de>
1991
1992         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
1993           output unless SDCCPICDEBUG is set
1994         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
1995           output if SILENT is set
1996
1997 2006-07-11 Borut Razem <borut.razem AT siol.net>
1998
1999         * doc/README.txt: updated
2000
2001 2006-07-10 Borut Razem <borut.razem AT siol.net>
2002
2003         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
2004           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
2005           in WIN32 installation
2006         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
2007           release candidate 1
2008
2009 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
2010
2011         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
2012         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
2013
2014 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
2015
2016         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
2017
2018 2006-07-06 Borut Razem <borut.razem AT siol.net>
2019
2020         * support/regression/tests/bitfields.c:
2021           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
2022         * support/regression/tests/constantRange.c:
2023           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
2024
2025 2006-07-04 Borut Razem <borut.razem AT siol.net>
2026
2027         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
2028           src/port.mk,
2029           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
2030           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
2031           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
2032           reverted changes from 2006-07-03
2033         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
2034         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
2035           added CPPFLAGS, used by the host port
2036
2037 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
2038
2039         * support/regression/valdiag/tests/switch.c,
2040         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
2041         * support/regression/tests/libmullong.c: fixed for host
2042         * support/regression/ports/host/spec.mk: disable all warnings for host,
2043         SDCC runs with --less-pedantic too
2044
2045 2006-07-03 Borut Razem <borut.razem AT siol.net>
2046
2047         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
2048           defined CPPFLAGS
2049         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
2050         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
2051           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
2052           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
2053           include ../port.mk
2054         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
2055           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2056           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
2057           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
2058
2059 2006-07-02 Raphael Neider <rneider AT web.de>
2060
2061         * src/pic16/devices.inc,
2062         * device/include/pic16/pic18fregs.h,
2063         * device/include/pic16/pic18f4550.h,
2064         * device/lib/pic16/pics.all,
2065         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
2066
2067 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
2068
2069         * as/hc08/lkaomf51.c (OutputName),
2070         * as/mcs51/lkaomf51.c (OutputName),
2071         * as/z80/asmain.c (asmbl),
2072         * src/ds390/main.c (asmLineNodeFromLineNode),
2073         * src/hc08/ralloc.c (hc08_assignRegisters),
2074         * src/mcs51/main.c (asmLineNodeFromLineNode),
2075         * src/xa51/ralloc.c (checkRegMask),
2076         * src/xa51/gen.c (emitcode),
2077         * src/z80/gen.c (_emit2),
2078         * src/SDCCast.c (searchLitOp),
2079         * src/SDCCglobl.h,
2080         * support/packihx/packihx.c,
2081         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
2082         * src/ds390/gen.c (aopPutUsesAcc),
2083         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
2084         * support/regression/tests/libmullong.c (mullong_wrapper),
2085         * src/SDCCsymt.c (powof2),
2086         * src/SDCCast.c,
2087         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
2088         * src/SDCCsymt.h: added TYPE_TARGET_*
2089         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
2090         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
2091         SDCCast because 1) header problems 2) this is the right place
2092         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
2093         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
2094         prototype
2095
2096 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
2097
2098         * src/SDCCicode.h: removed buggy semicolon in unused macro
2099         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
2100         search for previous definiton of auto symbols too,
2101         (findPrevUse): fixed logic of emitWarnings
2102
2103 2006-06-26 Raphael Neider <rneider AT web.de>
2104
2105         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
2106           PCLATH and PCLATU on interrupts, potentially fixes #1505141
2107
2108 2006-06-25 Raphael Neider <rneider AT web.de>
2109
2110         * device/lib/pic/libm: NEW, added math library functions
2111         * device/lib/pic/libsdcc: NEW; added float support functions
2112         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
2113         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
2114           NEW, added math related headers
2115         * device/include/asm/pic/features.h: NEW
2116         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
2117           (popGet): allow larger offsets for AOP_PCODE,
2118           (genDataPointerSet): handle literals explicitly, more debug output,
2119           (genAssign): fixed for float using aopLiteral ;-)
2120         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
2121           GOTO initialisation routine
2122         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
2123           flag on registers, fixes #1469043 (local variables do not work)
2124         * src/pic/main.c (_pic14_do_link),
2125         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
2126           available
2127
2128 2006-06-25 Borut Razem <borut.razem AT siol.net>
2129
2130         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
2131           characters printed (not including the trailing '\0' used to end
2132           output to strings). Problem detected in regression test bug-927659.c.
2133           NOTE: printf() family functions should return int instead
2134           unsigned int!
2135         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
2136           specifier are printed as themselves
2137         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
2138           support flags, width and precision specifiers
2139
2140 2006-06-24 Borut Razem <borut.razem AT siol.net>
2141
2142         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
2143           to the list of sdcc tagrets not supporting bit type
2144         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
2145           testfor pic16 due to bug:
2146           [ 1511794 ] pic16: regression test bug-895992.c fails
2147
2148 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
2149
2150         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
2151         * src/SDCCglue.c (initPointer), fixed bug 1496419
2152         * support/regression/tests/bug1496419.c: new, added
2153
2154 2006-06-22 Borut Razem <borut.razem AT siol.net>
2155
2156         * support/regression/ports/pic16/support.c: use gpsim usart module from
2157           libgpsim_modules library
2158
2159 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2160
2161         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
2162         IP0H to IPH0.
2163
2164 2006-06-19 Raphael Neider <rneider AT web.de>
2165
2166         * src/pic/glue.h,src/pic16/glue.h: added prototypes
2167         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
2168           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
2169           (pic14printExterns,pic14printPublics,pic16printPublics,
2170           pic16_printExterns): use new functions to emit symbols
2171           (picglue,pic16glue): emit publics before emitting externs
2172         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
2173           locally defined functions to avoid bug #1443651
2174         * support/regression/tests/bug-716242.c: removed pic16 workaround
2175         * support/regression/ports/pic16/spec.mk: ignore errors during build
2176
2177 2006-06-19 Raphael Neider <rneider AT web.de>
2178
2179         * src/pic/glue.h: added pic14aopLiteral prototype
2180         * src/pic/glue.c (pic14aopLiteral): return unsigned int
2181         * src/pic/gen.c: removed stdint.h dependency
2182           (aopGet): use Safe_strdup()
2183           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
2184           (genDataPointerSet): use pic14aopLiteral()
2185         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
2186           for pic16; thanks to Bernhard and Maarten
2187
2188 2006-06-18 Borut Razem <borut.razem AT siol.net>
2189
2190         * support/regression/tests/structflexarray.c: flexible array members
2191           not supported by gcc < 3
2192         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
2193           GUI tool by default
2194         * src/pic/gen.c: don't include [p]strdin.h on solaris
2195         * support/Util/pstdint.h: addad svn attributes
2196         * support/regression/tests/constantRange.c,
2197           support/regression/tests/rotate.c: include inttypes.h instead
2198           stdint.h on solaris, addad svn attributes
2199
2200 2006-06-18 Raphael Neider <rneider AT web.de>
2201
2202         * src/SDCCsymt.c (initCSupport): change return type of divschar to
2203           int for PIC16
2204         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
2205           (pic16_genMinusBits): simplified sign-extension
2206           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
2207             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
2208             adjusted to correctly handle mixed-signed operands, disabled
2209             now unused multiplciation routines
2210         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
2211           (assignResultValue): added argument denoting the size of the result
2212             as returned by the function (fixes upcasts in assigning from
2213             function calls: char foo(); int i = foo();)
2214           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
2215             function result to assignResultValue
2216           (genMult): disabled inlined multiplication code
2217           (genDiv): augmented to also handle the modulus operator, fixed to
2218             handle mixed-signed operands correctly
2219           (genMod): simply call genDiv, disabled unused code
2220           (genAssign): fixed missing (sign-)extension on result
2221         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
2222             valid char operands, allow signed operands for native code, added
2223             division and modulo operator handling
2224         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
2225
2226         As a consequence, onebyte.c (if split into two files) and muldiv.c
2227         pass regression tests.
2228
2229 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2230
2231         * doc/Makefile.in: two runs of makeindex seem needed to get
2232         correct page references in the index of sdccman.pdf
2233         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
2234
2235 2006-06-17 Borut Razem <borut.razem AT siol.net>
2236
2237         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
2238
2239 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2240
2241         * doc/sdccman.lyx: updated, added (porting source code, debugging),
2242         mentioned ec2drv and paulmon
2243
2244 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
2245
2246         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
2247           consecutive abs areas
2248           (find_empty_space, allocate_space): added map to handle codemap or
2249            xdatamap,
2250           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
2251            absolute idata and xdata
2252         * as/mcs51/lkmem.c (summary2): updated legend
2253
2254 2006-06-16 Raphael Neider <rneider AT web.de>
2255
2256         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
2257
2258 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
2259
2260         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
2261           1208515
2262         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
2263
2264 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
2265
2266         * src/port.h (struct PORT): added field gp_tags, to hold the tag
2267         value of generic pointers,
2268         * src/avr/main.c,
2269           src/ds390/main.c,
2270           src/hc08/main.c,
2271           src/izt/i186.c,
2272           src/izt/tlcs900h.c,
2273           src/mcs51/main.c,
2274           src/pic/main.c,
2275           src/pic16/main.c,
2276           src/xa51/main.c,
2277           src/z80/main.c: PORT structure, added elements for gp_tags field,
2278         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
2279         fields in the PORT structure of each port,
2280         * src/SDCCast.c (decorateType): allow processing of generic pointers
2281         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
2282         S_FIXED symbols
2283
2284 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
2285
2286         * link/z80/lkgb.c,
2287         * link/z80/lkgg.c,
2288         * src/pic16/gen.c,
2289         * src/pic16/main.c,
2290         * src/pic16/pcode.c,
2291         * src/pic/main.c,
2292         * src/pic/pcoderegs.c,
2293         * src/SDCCicode.c,
2294         * src/SDCCmain.c,
2295         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
2296           bug 1504689 on minGW
2297
2298 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2299
2300         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
2301
2302 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
2303
2304         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
2305
2306 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
2307
2308         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
2309           for optimization
2310
2311 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
2312
2313         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
2314         to a char variable. Fixed bug #1504211
2315         * device/include/pic16/adc.h,
2316         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
2317         and fixed bug #1364390
2318
2319 2006-06-10 Borut Razem <borut.razem AT siol.net>
2320
2321         * CVSROOT: removed the CVS left-over
2322
2323 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
2324
2325         * as/hc08/asmain.c (asexit),
2326         * as/hc08/lkmain.c (lkexit),
2327         * as/mcs51/asmain.c (asexit),
2328         * as/mcs51/lkmain.c (lkexit),
2329         * src/SDCCglue.c (DEFSETFUNC),
2330         * src/SDCCmain.c (linkEdit, assemble),
2331         * support/librarian/sdcclib.c (AddRel),
2332           replaced unlink() by standard C remove()
2333         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
2334         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
2335           gatherImplicitVariables): new, added to fix bug 608752,
2336           (createFunction): added gatherImplicitVariables()
2337         * src/SDCCast.h: added createRMW prototype
2338         * src/SDCCsymt.h (struct symbol): added infertype
2339         * support/regression/tests/bug608752.c: new, added
2340
2341 2006-06-10 Raphael Neider <rneider AT web.de>
2342
2343         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
2344           multibyte dummy reads (fixes #1503234)
2345
2346 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
2347
2348         * device/include/mcs51/compiler.h: new, added header file to enable
2349           creating common sfr definition header files for different compilers
2350
2351 2006-06-05 Raphael Neider <rneider AT web.de>
2352
2353         * src/pic16/{pcode.h,genarith.c}:
2354           introduced pCodeOp combining any two pCodeOps (previously only
2355           two register operands could be combined), removed pcop2 from
2356           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
2357         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
2358         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
2359           rewritten to use new PO_TWO_OPS
2360         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
2361         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
2362           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
2363           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
2364           (pic16_get_op): embraced return arg to allow #define return(x),
2365             added new case for combined opcodes
2366           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
2367           (pic16_pCode2str,pic16_getRegFrompCodeOp,
2368            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
2369
2370 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
2371
2372         * src/SDCCval.c (checkConstantRange): added
2373         * src/SDCCval.h: added checkConstantRange
2374         * support/Util/SDCCerr.c,
2375         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
2376         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
2377         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
2378         * src/SDCCast.c (decorateType): added checkConstantRange,
2379         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
2380         can be emitted with the correct always true/false warning,
2381         added optimization for double '!';
2382         result of decorateType() must be assigned back to the tree, because
2383         decorateType() can change the tree
2384         * src/SDCCicode.c (geniCodeLogic),
2385         (geniCodeAssign): replaced new checkConstantRange, added warnings,
2386         (checkConstantRange): removed, it was only a fragment which never
2387         emitted a warning
2388         * src/SDCCsymt.c (computeType): fixed promotion for
2389         "-1 < (unsigned bit) b"
2390         * src/pic/ralloc.c (packRegsForAssign),
2391         * src/pic16/ralloc.c (packRegsForAssign),
2392         * src/hc08/ralloc.c (packRegsForAssign),
2393         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
2394         from mcs51
2395         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
2396         * support/regression/tests/constantRange.c: added
2397         * support/valdiag/tests/constantRange.c: added
2398         * support/valdiag/valdiag.py: added -DPORT_HOST=1
2399
2400 2006-06-02 Borut Razem <borut.razem AT siol.net>
2401
2402         * support/regression/ports/pic16/support.c: increase stack size
2403           to 255 bytes
2404         * support/regression/Makefile.in: sort tests by name so that the
2405           resutlts can be compared on different machines / platforms
2406
2407 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
2408
2409         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
2410         * src/ds390/gen.c (emitLabel): new, added,
2411           (genDjnz): fixed stack overflow bug,
2412           (throughout): cosmetic changes to sync with mcs51/gen.c,
2413           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
2414         * src/mcs51/gen.c (genEndFunction): small optimization,
2415           (throughout): cosmetic changes to sync with ds390/gen.c
2416
2417 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
2418
2419         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
2420           (_print_format): fixed printing pointers
2421         * src/mcs51/gen.c (emitLabel, movb): new, added,
2422           (genAssign): small optimization,
2423           (genDjnz): fixed stack overflow bug,
2424           (throughout): replaced sprintf with SNPRINTF,
2425           replaced mcs51_regWithIdx with REG_WITH_INDEX,
2426           replaced emitcode("mov", "b,...") with MOVB(...),
2427           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
2428           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
2429         * src/mcs51/peeph.def: added rules 140 and 264
2430         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
2431           so they may get optimized into registers
2432
2433 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
2434
2435         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
2436           immediately when encountered,
2437           (printUsage): always use stderr even on windows
2438
2439 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
2440
2441         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
2442         (processParms): fixed bug #1247551
2443         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
2444         parseCmdLine, main): print '--version' to stdout,
2445         print 'help' to stdout if --help is given,
2446         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
2447         arguments are given; fixed --help
2448
2449 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
2450
2451         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
2452         * support/regression/tests/bug-1493710.c: added
2453
2454 2006-05-27 Borut Razem <borut.razem AT siol.net>
2455
2456         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
2457           static instead auto
2458         * support/regression/ports/pic16/support.c: increase stack size
2459           from default 64 bytes to 128 bytes
2460         * support/regression/tests/staticinit.c,
2461           support/regression/tests/float.c: regression tests fully enabled
2462           for pic16 port by putting the initialized data arrays into the code
2463           section
2464         * support/regression/ports/pic16/spec.mk: don't link default libraries.
2465           This was changed by mistake in the previous version.
2466
2467 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
2468
2469         * src/pic16/gen.c (genFunction, genEndFunction): some
2470         beautifications, fixed bug with falsely restoring FSR2 in large
2471         stack model, thanks to Beau E. Cox for reporting the bug
2472
2473 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
2474
2475         * debugger/mcs51/break.c,
2476         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
2477           use %p to print pointers, made address variables unsigned
2478         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
2479         * debugger/mcs51/symtab.c (parseSymbol): must return something
2480         * src/mcs51/gen.c (aopForSym): small optimization,
2481            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
2482           (freeAsmop): added missing break,
2483           (aopPut): removed parameter bvolatile, determine it inside the function,
2484           (saveRegisters, unsaveRegisters): small optimization,
2485           (genIpush): removed pointless check,
2486           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
2487           replaced sprintf with SNPRINTF,
2488           replaced strcpy with strncpyz,
2489           updated aopPut calls,
2490           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
2491         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
2492
2493 2006-05-24 Borut Razem <borut.razem AT siol.net>
2494
2495         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
2496           modification of test for the pic16 port, put the array to the code
2497           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
2498
2499 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2500
2501         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
2502         * support/Util/pstdint.h: added
2503
2504 2006-05-22 Borut Razem <borut.razem AT siol.net>
2505
2506         * src/regression/Makefile: removed bool2.c test, added -q linker option
2507         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
2508           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
2509           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
2510           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
2511           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
2512           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
2513           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
2514           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
2515           define SUPPORT_BIT_TYPES 0, removed unused bit variables
2516
2517 2006-05-22 Raphael Neider <rneider AT web.de>
2518
2519         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
2520           bug #1492360 (problematic due to generic pointers, see code)
2521
2522 2006-05-22 Borut Razem <borut.razem AT siol.net>
2523
2524         * support/regression/ports/pic16/specs.mk: removed stack size linker
2525           directive
2526         * support/regression/tests/array.c,
2527           support/regression/tests/bitopcse.c,
2528           support/regression/tests/bug-908454.c,
2529           support/regression/tests/malloc.c: modified for pic16 regression test
2530         * support/regression/tests/bitfields.c:
2531           pic16 - excluded bitfileds of size > 8
2532         * support/regression/tests/bp.c: pic16 - reduced data size
2533         * support/regression/tests/bug-221100.c: pic16 - reduced data size
2534         * support/regression/tests/bug-460010.c:
2535           pic16 - used the absolute address the fits in memory
2536         * support/regression/tests/bug-716242.c:
2537           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
2538         * support/regression/tests/float.c:
2539           pic16 - excluded - data size too big
2540         * support/regression/tests/onebyte.c:
2541           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
2542         * support/regression/tests/shifts.c:
2543           pic16 - function names probably have to differ in first X characters
2544           (gpasm limitation?)
2545         * support/regression/tests/staticinit.c:
2546           pic16 - excluded some tests due error: no target memory available for
2547           section ".idata"
2548
2549 2006-05-22 Borut Razem <borut.razem AT siol.net>
2550
2551         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
2552           second try. Thanks Stas Sergeev once more.
2553
2554 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
2555
2556         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
2557           (genLeftShift, genRightShift): fixed bug 1491627
2558         * src/hc08/peeph.def (rules 7, 8.x): added
2559         * support/regression/tests/shifts.c (ShiftLeftByParam,
2560           ShiftRightByParam, testShiftByParam): added to test variable shifting
2561
2562 2006-05-20 Raphael Neider <rneider AT web.de>
2563
2564         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
2565         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
2566           (allocReg): add only new registers to dynAllocRegs,
2567           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
2568             #1489055, #1445850, and probably #1483693
2569
2570 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
2571
2572         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
2573         bug in for-loop that didn't emit the last of CONFIG and ID registers
2574
2575 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
2576
2577         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
2578           with offset
2579         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
2580           1489016, 1434401 and 1490124
2581         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
2582           1489016, 1434401 and 1490124
2583
2584 2006-05-17 Borut Razem <borut.razem AT siol.net>
2585
2586         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
2587           thanks Stas Sergeev
2588
2589 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2590
2591         * device/include/mcs51/P89c51RD2.h,
2592         * device/include/mcs51/P89LPC901.h,
2593         * device/include/mcs51/P89LPC922.h,
2594         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
2595
2596 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
2597
2598         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
2599         to fix missing stack pragma in compiled binary object file,
2600
2601 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
2602
2603         * support/packihx/configure.in,
2604         * support/packihx/configure: removed warning, autoconf >= 2.5x can
2605         determine sizeof basic types even while cross compiling
2606
2607 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
2608
2609         * src/avr/gen.c (aopop),
2610         * src/ds390/gen.c (aopOp),
2611         * src/hc08/gen.c (aopOp),
2612         * src/mcs51/gen.c (aopop),
2613         * src/pic16/gen.c (pic16_aopOp),
2614         * src/pic/gen.c (aopOp),
2615         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
2616         if size of operand is smaller than spill location
2617
2618 2006-05-12 Borut Razem <borut.razem AT siol.net>
2619
2620         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
2621           have to have CR/LF line endings even if they are checked out on *nix
2622           or on WIN32 in cygwin binmode
2623
2624 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
2625
2626         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
2627         * device/include/ds80c390.h: added sfr16 definitions
2628         * src/ds390/gen.c,
2629         * src/ds390/gen.h,
2630         * src/ds390/main.c,
2631         * src/ds390/ralloc.c,
2632         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
2633           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
2634           bit returning functions
2635         * support/regression/tests/sfr16.c: enabled test on ds390
2636
2637 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2638
2639         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
2640         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
2641
2642 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
2643
2644         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
2645         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
2646           (cl_address_space constructor): removed expensive initialization,
2647           (cl_address_space::get_cell): extended for late initialization,
2648           (cl_address_space::*): use late initialization,
2649           (cl_address_decoder::activate): removed expensive initialization,
2650           This reduced regression test running time by 25%
2651
2652 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
2653
2654         * packihx/,
2655         * configure.in,
2656         * configure,
2657         * sdcc.dsw,
2658         * Makefile.bcc,
2659         * Makefile.in,
2660         * support/packihx/Makefile.in,
2661         * support/packihx/clean.mk,
2662         * support/packihx/Makefile.bcc,
2663         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
2664
2665 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2666
2667         * src/SDCCval.c (valNot): fix for regression test failure
2668           of not.c on big endian hosts
2669
2670 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
2671
2672         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
2673
2674 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2675
2676         * device/lib/mcs51/Makefile.in: changed string comparison operator
2677           to = for POSIX compliance; == is bash extension
2678
2679 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
2680
2681         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
2682           kosmonaut_pirx
2683
2684 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
2685
2686         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
2687         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
2688         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
2689         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
2690         bug report #1478657,
2691
2692 2006-05-05 Borut Razem <borut.razem AT siol.net>
2693
2694         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
2695           making the html
2696
2697 2006-05-02 Borut Razem <borut.razem AT siol.net>
2698
2699         * doc/Makefile.in: removed *.ind dependency since there is no rule to
2700           create *.ind, which made make to fail if invoked with -j 2
2701
2702 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
2703
2704         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
2705           Hubert Sack for patch 1479782
2706
2707 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
2708
2709         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
2710
2711 2006-05-01 Raphael Neider <rneider AT web.de>
2712
2713         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
2714           (create_pic): store only prefix-free device name,
2715           (init_pic): check for device names with "16" prefix,
2716           (list_valid_pics),
2717         * src/pic/device.h (struct PIC_device),
2718         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
2719             stored device name,
2720         * device/include/pic/pic12f{635,675,629,683}.h,
2721         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
2722         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
2723         * device/include/pic/pic16f505.h,
2724         * device/lib/pic/libdev/pic16f505.c: removed
2725         * device/include/pic/pic14devices.txt: added support for pic12f
2726             devices, removed unsupported non 16-bit devices
2727             [above changes provided by patch from Zik Saleeba]
2728         * src/pic/*, src/pic16/*, device/include/pic16/*,
2729           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
2730
2731 2006-05-01 Borut Razem <borut.razem AT siol.net>
2732
2733         * configure.in, configure, doc/Makefile.in:
2734           sync with nightly build makefile - latex, dvipdf and dvips
2735           not needed any more
2736
2737 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
2738
2739         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
2740         in the library source
2741
2742 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
2743
2744         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
2745
2746 2006-04-28 Raphael Neider <rneider AT web.de>
2747
2748         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
2749         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
2750           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
2751         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
2752
2753 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
2754
2755         * device/lib/pic/libdev/Makefile.in,
2756         * device/lib/hc08/Makefile.in,
2757         * device/lib/gbz80/Makefile.in,
2758         * device/lib/z80/Makefile.in,
2759         * device/lib/ds390/Makefile.in,
2760         * device/lib/ds400/Makefile.in: added srcdir to include search path,
2761         thanks to Borut for the bug report
2762         * configure.in,
2763         * configure: always create doc/Makefile independent from --enable-doc
2764         * Makefile.in: always install from directory doc independent from
2765         --enable-doc
2766         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
2767         removed
2768         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
2769         * doc/Makefile.in: install *.txt if present
2770         * device/include/Makefile.in (install): added installation of pic/*.inc
2771         and pic/*.txt files again, they were erroneously removed
2772
2773 2006-04-28 Raphael Neider <rneider AT web.de>
2774
2775         * src/pic/{gen.c,main.h,pcode.c},
2776         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
2777             concerning signedness with casts
2778
2779 2006-04-28 Raphael Neider <rneider AT web.de>
2780
2781         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
2782             definition of an interrupt handler,
2783         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
2784             interrupt handler stuff from picglue() to separate routine,
2785           (picglue): enabled definition of intr handlers in files w/o main()
2786
2787 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2788
2789         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
2790           compilation with MSVC 2005 Express Edition (VC8)
2791
2792 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
2793
2794         * device/lib/Makefile: fixed build of gbz80 lib
2795
2796 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2797
2798         * support/regression/tests/bug-460010.c,
2799         * support/regression/tests/bug-524691.c,
2800         * support/regression/tests/bug-716242.c: removed conditional defines
2801           that are already in testfwk.h
2802
2803 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
2804
2805         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
2806           (AccAXRsh1): added, shift right by 1,
2807           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
2808            AccAXLrl1
2809         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
2810
2811 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
2812
2813         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
2814         remove cast to same type
2815         * src/SDCCast.c (decorateType): fix for RFE 1475742,
2816         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
2817         * as/z80/Makefile,
2818         * link/z80/Makefile: removed, they have moved to
2819         Makefile.in files
2820         * configure,
2821         * configure.in: replaced duplicate message about ucsim by missing sdcpp
2822         * install-sh: fix bug #1204398 by setting umask 0022
2823         * device/lib/Makefile: separate build of z80 and gbz80 lib
2824
2825 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
2826
2827         Enabled VPATH feature: changed nearly all Makefiles (149 files).
2828         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
2829
2830         One basic decision: e.g. src/clean.mk includes further files. In order
2831         to make this work there are two solutions:
2832         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
2833           run configure on them. This way they can use
2834           'include $(srcdir)/port-clean.mk'
2835         - always include clean.mk by the Makefile at the same level. To avoid
2836           that `make clean` tries to include and build Makefile.dep the
2837           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
2838           implemented, because now even `make uninstall` doesn't create
2839           Makefile.in. clean.mk could be eliminated by pasting it in
2840           Makefile.in.
2841
2842         * debugger/mcs51/Makefile.in: build own objects from library sources
2843         (SLIB, SDCC) in current directory
2844
2845         * configure, configure.in: renamed --disable-device-lib-build in
2846         --disable-device-lib; added --enable-doc, the required tools are
2847         searched by configure; added result message; the toolchain for the
2848         belonging ports are now only built, if the port is enabled.
2849
2850         * support/regression/*: all output is written in directory gen, because
2851         the fwk and ports directories don't livet in the build tree using vpath
2852
2853         * doc/sdccman.lyx: renamed --disable-device-lib-build to
2854         --disable-device-lib, added --enable-doc, added section VPATH
2855
2856         * sim/ucsim/configure.in,
2857         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
2858         z80 are enabled by default
2859
2860 2006-04-24 Raphael Neider <rneider AT web.de>
2861
2862         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
2863             to config word, "pic14_"-prefixed some extern functions
2864           (pic14_emitConfigWord): emit __config directive(s) if assignment to
2865             config word has been found
2866         * src/pic/device.h: added prototypes
2867         * src/pic/pcode.c: added "pic14_"-prefix where needed
2868         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
2869             fixup
2870         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
2871             words,
2872           (pic14emitRegularMap): ignore config words,
2873           (pic14createInterruptVect): moved generating __config directives away
2874           (picglue): have __config directives emitted
2875
2876 2006-04-24 Borut Razem <borut.razem AT siol.net>
2877
2878         * doc/Makefile: sync with nightly build makefile
2879
2880 2006-04-24 Raphael Neider <rneider AT web.de>
2881
2882         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
2883             registers that have not been assigned proper liveranges,
2884             fixes #1469504 and #1474602,
2885           (pCodeRegOptimizeRegUsage): fixed typo in comment
2886
2887 2006-04-24 Borut Razem <borut.razem AT siol.net>
2888
2889         * device/examples/main8051.c: deleted - it was removed from CVS
2890           24.mar.2000 and after that modified 18.feb.2001, so it reappered
2891           after the transition to Subversion
2892         * src/SDCCalloc.h: deleted - it was removed  from CVS
2893           3.feb.2001 and after that modified 18.feb.2001, so it reappered
2894           after the transition to Subversion
2895         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
2896           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
2897           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
2898           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
2899
2900 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
2901
2902         * as/asx8051.dsp: added mcs51/strcmpi.h
2903         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
2904         * as/hc08/aslink.h: updated lnksect prototype
2905         * as/hc08/asm.h,
2906         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
2907         * as/hc08/asmain.c,
2908         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
2909           (newdot): handle A_ABS
2910         * as/hc08/asout.c,
2911         * as/mcs51/asout.c (outarea): output address
2912         * as/hc08/lkaomf51.c,
2913         * as/mcs51/lkaomf51.c: disabled unused array UsageType
2914         * as/hc08/m08pst.c,
2915         * as/mcs51/i51pst.c,
2916         * as/z80/z80pst.c: "ABS" is not A_OVR
2917         * as/hc08/lkarea.c (newarea): read a_addr,
2918           (lnkarea): added codemap array, sort absolute areas to the front,
2919            combine all GSINITx/GSFINAL,
2920           (find_empty_space, allocate_space): new functions,
2921           (lnksect): return next address, handle absolute sections
2922         * as/mcs51/lkarea.c (newarea): read a_addr,
2923           lnksect2 prototype changed,
2924           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
2925           (find_empty_space, allocate_space): new, factored out of lnksect2,
2926           (lnksect2): return next address, handle absolute sections
2927         * as/hc08/lkhead.c,
2928         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
2929         * as/hc08/lklibr.c (addfile, fndsym),
2930         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
2931           index out of range and detect both '\' and '/'
2932         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
2933         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
2934           regression tests (ds390 cannot return bool yet)
2935         * doc/sdccman.lyx: changed version number, document changed --no-peep,
2936           document critical interrupts on z80, document changed SDCC define
2937         * src/asm.c (_asxxxx_mapping): fixed .org directive,
2938           (_a390_mapping): added .org directive
2939         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
2940           (genMultOneByte): fixed warnings
2941         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
2942           ones
2943         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
2944         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
2945           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
2946         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
2947         * src/pic16/main.c: removed newReg prototype
2948         * src/pic16/pcode.c,
2949         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
2950           warnings
2951         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
2952           ones
2953         * src/pic16/ralloc.c
2954         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
2955           to fix warnings
2956         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
2957           from short to PIC_OPTYPE
2958         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
2959         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
2960           optype from short to PIC_OPTYPE
2961         * src/port.h: made int_size unsigned to fix warnings
2962         * src/SDCC.y: fixed warning on MSVC
2963         * src/SDCCicode.c (getArraySizePtr): return unsigned int
2964         * src/SDCCopt.c (convertToFcall): fixed warnings
2965         * src/SDCCsymt.h: removed double prototype for genSymName
2966         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
2967           offset int to fix warnings
2968
2969 2006-04-22 Borut Razem <borut.razem AT siol.net>
2970
2971         * doc/sdccman.lyx, */Makefile, */Makefile.in:
2972           references to CVS replaced with Subversion
2973
2974 2006-04-21 Borut Razem <borut.razem AT siol.net>
2975
2976         * doc/sdccman.lyx, */Makefile, */Makefile.in:
2977           references to CVS replaced with Subversion
2978
2979 2006-04-19 Borut Razem <borut.razem AT siol.net>
2980
2981         * src/version.awk: adapted for svn
2982         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
2983           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
2984           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
2985           /binutils-avr/etc/*.vi, *.jin: removed all properties
2986           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
2987
2988 2006-04-19 Borut Razem <borut.razem AT siol.net>
2989
2990         * CVS to Subversion migration completed
2991
2992 2006-04-18 Borut Razem <borut.razem AT siol.net>
2993
2994         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
2995           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
2996
2997 2006-04-17 Borut Razem <borut.razem AT siol.net>
2998
2999         * device/include/Makefile.in: added pic/*.inc to the installation
3000
3001 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
3002
3003         * support/regression/collate-results.py: fixed output in case of
3004         a valdiag error
3005         * support/regression/generate-cases.py: fixed splitting of pathnames
3006         with dots
3007         * as/hc08/lklibr.c (addfile),
3008         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
3009
3010 2006-04-11 Raphael Neider <rneider AT web.de>
3011
3012         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
3013         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
3014         * src/pic16/pcode.c (assignValnums): fixed #1460578
3015
3016 2006-04-11 Raphael Neider <rneider AT web.de>
3017
3018         * device/lib/pic/libdev/*.c,
3019         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
3020           fixes #1468739, enables compilation in --std-c99 mode
3021         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
3022
3023 2006-04-11 Raphael Neider <rneider AT web.de>
3024
3025         * src/pic/device.c (find_device): removed debug output
3026           (list_valid_pics): enabled verbose listing of supported devices
3027         * device/include/stdbool.h: define bool as char for pic14/16 as well
3028
3029 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3030
3031         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
3032
3033 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3034
3035         * .version: bumped version to 2.5.6
3036         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
3037
3038 2006-04-06 Raphael Neider <rneider AT web.de>
3039
3040         * .version: bumped version to 2.5.6 (pic14 ABI changed)
3041         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
3042         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
3043           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
3044             pic14_constructAbsMap
3045           (pic14printPublics): declare absolute global symbols as global
3046           (pic14createInterruptVect),
3047         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
3048           (newReg): assume new registers unused, use correct name in
3049             hashtable (reg->name instead of name), more debugLog output
3050         * src/pic/device.h (PIC_device): added fields for verbose output
3051         * src/pic/device.c: moved device definition to pic14devices.txt,
3052             added routines for runtime parsing of pic14devices.txt,
3053             added support for second config word
3054         * src/pic/main.c (_process_pragma): removed #pragma maxram,
3055           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
3056           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
3057           (_pic14_parseOptions): moved pCodeInitRegisters here
3058           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
3059         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
3060           (pCodeInitRegisters): rewrapped comments, perpared new approach to
3061             handling the pseudo stack
3062         * device/lib/Makefile.in: ignore failures in objects-pic16,
3063         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
3064         * device/lib/pic/NEWS: document new dependency on picXXX.lib
3065         * device/lib/pic/Makefile.subdir,
3066         * device/lib/pic16/Makefile.subdir: improved clean rules
3067         * device/lib/pic/libdev/: NEW, pic14 device libraries
3068         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
3069         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
3070         * device/include/Makefile.in: create subdir and install pic14 headers
3071         * device/include/pic/p16f_common.inc: removed unused declarations
3072         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
3073             PICs from inc2h.pl v1.6,
3074             replaced BIT_AT macros with struct declarations
3075         * device/include/pic/pic14devices.txt: definition of supported devices,
3076             all above improvements contributed by Zik Saleeba, thanks
3077         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
3078         * support/scripts/sdcc.nsi: also install pic14 device libraries and
3079             headers
3080
3081 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3082
3083         * device/include/mcs51/c8051f410.h: added interrupt numbers,
3084         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
3085           thanks to Charles Olds
3086
3087 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3088
3089         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
3090
3091 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3092
3093         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
3094         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
3095         * support/regression/bug1464657.c: added, new test
3096
3097 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
3098
3099         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
3100           version number
3101
3102 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
3103
3104         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
3105           --no-peep and --peep-file <file> are used don't use default rules but
3106           do use the <file>
3107
3108 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
3109
3110         * src/mcs51/gen.c (genCall): fixed bug 1457608
3111
3112 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3113
3114         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
3115         changes seem to cause (trigger?) problems with the build system.
3116
3117 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
3118
3119         * src/SDCCpeeph.c (operandsLiteral): new, added,
3120           (callFuncByName): inserted operandsLiteral
3121         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
3122
3123 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3124
3125         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
3126         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
3127
3128 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3129
3130         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
3131           implemented patch 1120823 Thanks to Willy De la Court (normal
3132           interrupts need an interrupt number now if they are made critical),
3133           and enabled nesting of critical functions though not for gbz80
3134           (genCritical, genEndCritical): added functions
3135           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
3136         * src/z80/mappings.i: added "ei" to all mappings
3137
3138 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3139
3140         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
3141         submitted by the Debian SDCC maintainer Aurelien Jarno:
3142         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
3143         archive with gcc 4.1 on mips and wrote the patch"
3144
3145 2006-03-16 Raphael Neider <rneider AT web.de>
3146
3147         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
3148           the left operand is shorter than the result (c* = lit-c* + int),
3149           fixes bug #1450796
3150         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
3151           OP_SYMBOL
3152
3153 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3154
3155         * src/.version: increased version number to 2.5.5
3156         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
3157         linking is done manually in pic16 port's _linkEdit,
3158         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
3159         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
3160         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
3161         allocate asmop as AOP_ACC,
3162         (aopForRemat): added parameter 'bool result' in function declaration,
3163         (pic16_aopGet): return AOP_ACC when accessing WREG,
3164         (pic16_popGetTempReg): minor modification,
3165         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
3166         'pic16_allocWithIdx',
3167         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
3168         calling function in absolute addresses,
3169         (genAssign): take into account AOP_ACC asmop,
3170         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
3171         * src/pic16/pcoderegs.c: some debug functions and lines added,
3172         * src/pic16/ralloc.c (decodeRegType): added but commented out,
3173         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
3174         register too,
3175         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
3176         call to allocReg, not by manually allocating a new one,
3177         (pic16_assignRegisters): now before going through the register
3178         allocating functions mark all registers as free. This eliminates some
3179         side effects resulting from peephole parser done earlier in the backbone
3180
3181 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
3182
3183         * src/SDCCicode.c (geniCodeLogic),
3184         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
3185
3186 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
3187
3188         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
3189           (genSend): bugfix, do not allocate and free twice,
3190           (shiftRLong): handle partially overlapping aops
3191         * support/regression/tests/bitopcse.c: fixed warning redefined idata
3192
3193 2006-03-08 Borut Razem <borut.razem AT siol.net>
3194
3195         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
3196           for pic16
3197
3198 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
3199
3200         * support/regression/tests/bug1409955.c: new, added
3201         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
3202         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
3203           (aopForSym, aopOp): increment asmop.allocated if reused,
3204           (freeAsmop): decrement asmop.allocated and check for zero instead of
3205           using asmop.freed,
3206           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
3207           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
3208            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
3209            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
3210            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
3211            genSignedRightShift, genRightShift, genDataPointerGet,
3212            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
3213            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
3214             in reverse order from allocation,
3215           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
3216             added swappedLR to keep track
3217         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
3218           pdata & code for GCC, z80, gbz80 & hc08
3219         * support/regression/tests/zeropad.c: moved defines to testfwk.h
3220
3221 2006-03-08 Raphael Neider <rneider AT web.de>
3222
3223         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
3224
3225 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
3226
3227         * device/include/mcs51/c8051f410.h: new SiLabs mcu
3228         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
3229         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
3230
3231 2006-03-06 Borut Razem <borut.razem AT siol.net>
3232
3233         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
3234           made the linker quiet
3235
3236 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3237
3238         * src/pic16/gen.c (genPcall): fixed bug #1443644
3239         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
3240         which dumps before the function entry point a data byte which represents
3241         the number of the local variables used by the specified function, added
3242         'xinst' for initial support for Extended Instruction Support,
3243         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
3244         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
3245         port->fun_prefix anymore (may change later),
3246         (genFunction, genEndFunction): do not store/restore local registers for
3247         _main (this should take care the --main-return command line option in
3248         the future),
3249         (genOr): removed some legacy pic-port instructions,
3250         * src/pic16/genarith.c (genAddLit): re-enabled old code because
3251         performing operations with SFR's causes data to be written more than
3252         once to each SFR. Perhaps SFRs should be handled in special cases...
3253         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
3254         pcode.h
3255         * src/pic16/main.c (_process_pragma): stack bound checking did not take
3256         into account for stack starting position,
3257         (struct OPTIONS pic16_optionsTable): added command line argument
3258         --extended or -y for Extended Instruction Support,
3259         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
3260         (deassignLRs): *** perhaps the most important change, old 'for' code
3261         (commented out for reference), didn't account for some registers which
3262         were left marked 'not free' after a pointer operation. The change
3263         reduces register usage a lot in some cases
3264
3265 2006-03-04 Borut Razem <borut.razem AT siol.net>
3266
3267         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
3268           _clean
3269         * support/regression/tests/bug-524697.c: decreased array size for
3270           mcs51 to fit into the internal RAM
3271         * support/regression/Makefile.in: a little bit more verbose
3272
3273 2006-03-03 Borut Razem <borut.razem AT siol.net>
3274
3275         * support/regression/fwk/lib/testfwk.c,
3276           support/regression/fwk/include/testfwk.h: introduced function
3277           _prints(), nonrecursive _printn(), call _initEmu() from main()
3278         * support/regression/ports/gbz80/support.asm,
3279           support/regression/ports/ucz80/support.asm,
3280           support/regression/ports/z80/support.asm,
3281           support/regression/ports/ds390/support.c,
3282           support/regression/ports/hc08/support.c,
3283           support/regression/ports/host/support.c,
3284           support/regression/ports/mcs51/support.c,
3285           support/regression/ports/xa51/support.c: added empty _initEmu()
3286           function
3287         * support/regression/ports/pic16/gpsim.cmd,
3288           support/regression/ports/pic16/spec.mk,
3289           support/regression/ports/pic16/support.c,
3290           support/regression/Makefile.in: added pic16 regression test
3291
3292 2006-03-01 Raphael Neider <rneider AT web.de>
3293
3294         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
3295           genConstPointerGet): use safe way of generating MOVFF to cover
3296             literals as well as registers, fixes bug #1440527
3297         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
3298             dereference
3299           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
3300             more correctly, fixes bug #1232186
3301           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
3302         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
3303             gplink guess the correct processor in more cases, applied patch
3304             from Till Riedel attached to and fixing bug #1436552
3305
3306 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3307
3308         * support/regression/tests/array.c: added, contains check for #1434401
3309         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
3310
3311 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
3312
3313         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
3314         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
3315         * device/include/mcs51/c8051f326.h,
3316         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
3317         * device/include/mcs51/c8051f000.h,
3318         * device/include/mcs51/c8051f018.h,
3319         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
3320           PCON_IDLE,PCON_STOP and added sfr16 definitions
3321
3322 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
3323
3324         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
3325           genGetWord): fixed bug 1409955
3326
3327 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
3328
3329         * device/include/hc08/mc68hc908gp32.h,
3330         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
3331
3332 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
3333
3334         * src/SDCCast.c (constExprValue): return NULL if not a value
3335         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
3336         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
3337         * support/regression/tests/bitfields.c: enabled signed bitfield for all
3338
3339 2006-02-13 Borut Razem <borut.razem AT siol.net>
3340
3341         * src/regression/ptrarg.c: added, fails due to bug #1430967
3342         * src/regression/Makefile: ptrarg.c added, ...
3343
3344 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
3345
3346         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
3347         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
3348
3349 2006-02-11 Borut Razem <borut.razem AT siol.net>
3350
3351         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
3352           print "Processor: xxx" message to stdout only if --verbose
3353
3354 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3355
3356         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
3357         * support/regression/tests/bug1426356.c: added
3358         * support/regression/tests/bitfields.c: removed 2 tests
3359
3360 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3361
3362         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
3363         * device/include/mcs51/c8051f330.h,
3364         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
3365           PCON_IDLE,PCON_STOP and added sfr16 definitions
3366         * device/lib/_divsint.c,
3367         * device/lib/_divuint.c,
3368         * device/lib/_divulong.c,
3369         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
3370           register bank bug for small stackauto
3371
3372 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3373
3374         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
3375
3376 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
3377
3378         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
3379         * all.dsp: corrected several bin paths
3380         * device/include/mcs51/c8051f120.h,
3381         * device/include/mcs51/c8051f300.h,
3382         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
3383           to PCON_IDLE,PCON_STOP
3384         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
3385         * device/lib/printf_large.c (output_float): fixed bug 1388703
3386         * support/regression/tests/bug1057979.c: added test for bug 1388703
3387
3388 2006-02-08 Raphael Neider <rneider AT web.de>
3389
3390         * src/pic/pcode.c (pciTRIS): fixed typo,
3391           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
3392           (LinkFlow): fixed handling of flows that end in a call,
3393           (ReuseReg): perform safety check earlier
3394         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
3395             to work with flows at the beginning of a pBlock,
3396             fixes #1426557 (Symbol not previously defined),
3397           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
3398             usage information
3399           (RemoveUnusedRegisters): update register usage info
3400         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
3401             created, reuse existing ones instead
3402         * src/pic/gen.c (genPcall): fixed #1424719
3403
3404 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
3405
3406         * link/z80/lkmain.c,
3407         * link/z80/lklex.c,
3408         * link/z80/lkdata.c,
3409         * link/z80/aslink.h: fixed build on current cygwin:
3410         replaced getline() by lk_getline()
3411
3412 2006-02-01 Borut Razem <borut.razem AT siol.net>
3413
3414         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
3415           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
3416           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
3417           src/regression/bool1.c, src/regression/bool2.c,
3418           src/regression/bool3.c, src/regression/call1.c,
3419           src/regression/compare.c, src/regression/compare10.c,
3420           src/regression/compare2.c, src/regression/compare3.c,
3421           src/regression/compare4.c, src/regression/compare5.c,
3422           src/regression/compare6.c, src/regression/compare7.c,
3423           src/regression/compare8.c, src/regression/compare9.c,
3424           src/regression/configword.c, src/regression/for.c,
3425           src/regression/inline.c, src/regression/mult1.c,
3426           src/regression/nestfor.c, src/regression/or1.c,
3427           src/regression/pointer1.c, src/regression/ptrfunc.c,
3428           src/regression/rotate1.c, src/regression/rotate2.c,
3429           src/regression/rotate3.c, src/regression/rotate4.c,
3430           src/regression/rotate5.c, src/regression/rotate6.c,
3431           src/regression/rotate7.c, src/regression/string1.c,
3432           src/regression/struct1.c, src/regression/sub.c,
3433           src/regression/sub2.c, src/regression/switch1.c,
3434           src/regression/while.c, src/regression/xor.c,
3435           src/regression/create_stc, src/regression/simulate,
3436           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
3437           regression tests
3438         * src/regression/gpsim_assert.h: added
3439
3440 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
3441
3442         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
3443         ((void (code *) (void)) 0) ();
3444         * as/hc08/aslex.c,
3445         * as/hc08/aslink.h,
3446         * as/hc08/asm.h,
3447         * as/hc08/asmain.c,
3448         * as/hc08/lkdata.c,
3449         * as/hc08/lklex.c,
3450         * as/hc08/lkmain.c,
3451         * as/mcs51/aslex.c,
3452         * as/mcs51/aslink.h,
3453         * as/mcs51/asm.h,
3454         * as/mcs51/asmain.c,
3455         * as/mcs51/lkdata.c,
3456         * as/mcs51/lklex.c,
3457         * as/mcs51/lkmain.c,
3458         * as/z80/aslex.c,
3459         * as/z80/asm.h,
3460         * as/z80/asmain.c: fixed build on current cygwin:
3461         replaced getline() by as_getline()
3462
3463 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
3464
3465         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
3466         declarator in the symbol chain
3467         * src/SDCCsymt.h,
3468         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
3469         parameter list for function pointers
3470         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
3471         * support/regression/tests/bug-716242.c: added
3472
3473 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
3474
3475         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
3476         offset if possible
3477         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
3478
3479 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
3480
3481         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
3482         inifinitely recurseable, added static
3483         * support/regression/tests/bug-1408066.c: added
3484
3485 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
3486
3487         * src/SDCCicode.h,
3488         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
3489         renamed, added possibility to create "postLoopLbl"-labels
3490         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
3491         newiTempLoopHeaderLabel
3492         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
3493         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
3494         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
3495         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
3496         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
3497         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
3498         (basicInduction): fixed bug #136564, made static,
3499         (loopInduction): changed parameter of basicInduction, made static,
3500         (addPostLoopBlock): added
3501         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
3502         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
3503         findLoopEndSeq
3504         * support/regression/tests/bug-136564.c: added
3505         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
3506         --std-sdcc99 to LIBSDCCFLAGS
3507
3508 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
3509
3510         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
3511         while loop
3512         * support/regression/tests/bug-1406131.c: added
3513
3514 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
3515
3516         * src/SDCCast.c (decorateType): fix promotion of unary minus
3517         * src/SDCCsymt.c (computeType): beautified
3518         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
3519         (valUnaryPM, valComplement): fix sign and promotion,
3520         (valNot): ANSI: result type is int (SDCC: unsigned char)
3521         * support/regression/tests/uminus.c: speedup by removing superflous
3522         test case 'int'
3523         * support/regression/tests/onebyte.c: added promotion and signedness
3524         tests for unary minus
3525         * support/regressions/tests/bug-477927.c: disable warning about
3526         uninitialized variables
3527         * support/regression/tests/not.c: added
3528
3529 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
3530
3531         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
3532         * src/mcs51/gen.c (gen51Code): show final register usage after
3533         fillGaps in asm with --i-code-in-asm
3534         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
3535         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
3536         incUsed, rliveClear, adjustIChain): made static,
3537         (setFromRange): excluded because it's unused,
3538         (findPrevUseSym, markWholeLoop): added,
3539         (findPrevUse): rewritten; fixes bug 895992; now a complete search
3540         through all branches of predecessors enables sdcc to emit the warning
3541         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
3542         (rlivePoint): made static, added parameter emitWarnings which is only
3543         true during the first run out of two,
3544         (findRecursiveSucc, findRecursivePred): removed,
3545         (computeLiveRanges): made static, added parameter emitWarnings,
3546         (dumpIcRlive): added for debugging only
3547         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
3548         removed prototype of setFromRange()
3549         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
3550         in call of computeLiveRanges()
3551         * support/regression/tests/bug-895992.c: added
3552         * support/regression/tests/bug-971834.c: added
3553         * support/valdiag/tests/bug-895992.c: added
3554         * support/valdiag/tests/bug-971834.c: added
3555
3556 2005-12-18 Raphael Neider <rneider AT web.de>
3557
3558         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
3559           (genUnpackBits): improved code for direct operands,
3560           (genPackBits): improved code for literal assignment to bitfields
3561             and for direct destination operands (no FSR indirection),
3562             prevented redundant AND, fixes #1362800,
3563           (AccLsh): added parameter to disable masking of the result
3564         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
3565           skip instructions with side-effects (like incfsz),
3566           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
3567         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
3568         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
3569           fixes #1375263
3570
3571 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
3572
3573         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
3574         volatile variables as spill location
3575
3576 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
3577
3578         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
3579         replacing literals
3580         * support/regression/tests/bug-1376320.c: added
3581
3582 2005-12-08 Raphael Neider <rneider AT web.de>
3583
3584         * src/pic/device.c: renamed is_shared to pic14_is_shared
3585         * src/pic/gen.c (genIfx): re-enabled handling of sbits
3586         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
3587           (is_valid_identifier): added for above workaround
3588
3589 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
3590
3591         * device/lib/Makefile.in: fixed to enable port-specific-objects
3592         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
3593           char, thanks Hubert Sack
3594         * doc/sdccman.lyx: documented --xstack-loc,
3595           elaborated a bit more on interrupts and pitfalls,
3596           removed "setjmp/longjmp unsupported",
3597           documented some unsupported C99 features
3598         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
3599         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
3600           if, thanks Hubert Sack
3601         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
3602         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
3603           make make_library
3604         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
3605           regression tests can report resource usage (rfe 700441)
3606         * support/regression/collate-results.py: report resource usage
3607         * support/regression/ports/ds390/spec.mk,
3608         * support/regression/ports/hc08/spec.mk,
3609         * support/regression/ports/mcs51/spec.mk,
3610         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
3611         * support/regression/ports/ds390/uCsim.cmd,
3612         * support/regression/ports/hc08/uCsim.cmd,
3613         * support/regression/ports/mcs51/uCsim.cmd,
3614         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
3615         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
3616           library, use the default one
3617         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
3618           building the library
3619
3620 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
3621
3622         * config.dsp: added dependency on .version and configure_vc.awk
3623         * device/include/setjmp.h: updated for --stack-auto and --xstack
3624         * device/include/mcs51/at89c51snd1c.h: corrected line endings
3625         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
3626         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
3627         * device/lib/libsdcc.lib: added _setjmp
3628         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
3629           (decorateType): fixed bug 1372851,
3630           (optimizeGetHbit): fixed warning
3631         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
3632           array initialisation
3633         * support/regression/tests/bug1057979.c: added test for bug 1358192
3634         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
3635
3636 2005-12-03 Borut Razem <borut.razem AT siol.net>
3637
3638         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
3639           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
3640
3641 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
3642
3643         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
3644         createIval): implement symbol independant "flexible array member",
3645         (createIvalCharPtr): implemented flexible array initialisation with a
3646         string
3647         * src/SDCCsymt.c (copyStruct): removed,
3648         (getSize): fixed misleading comment,
3649         (getAllocSize): removed, the additional allocation size is now in
3650         sym->flexArrayLength,
3651         (checkStructFlexArray): new, syntax checks for flexible array members,
3652         (compStructSize): added syntax checks for "flexible array members"
3653         (copyStruct): removed,
3654         (copyLinkChain): removed inefficient fix for bug 770487
3655         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
3656         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
3657         symbol->flexArrayLength
3658         * src/SDCCerr.c,
3659         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
3660         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
3661         * support/regression/tests/structflexarray.c: added
3662         * support/valdiag/tests/structflexiblearray.c: added
3663
3664 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
3665
3666         * src/SDCCast.c (decorateType): fixed bug 1368489
3667         * support/Util/SDCCerr.c,
3668         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
3669
3670 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3671
3672         * device/include/mcs51/at89c51snd1c.h: added file submitted by
3673           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
3674
3675 2005-11-27 Borut Razem <borut.razem AT siol.net>
3676
3677         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
3678           support/cpp2/mkdeps.h: added command line option
3679           -obj-ext=<extension> to SDCPP to define object file externion, used
3680           for generation of make dependencies (-M)
3681         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
3682
3683 2005-11-26 Borut Razem <borut.razem AT siol.net>
3684
3685         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
3686           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
3687           added pic and pic16 libraries
3688
3689 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3690
3691         * device/include/float.h: Corrected typo in prototype of __fsgt
3692
3693 2005-11-25 Borut Razem <borut.razem AT siol.net>
3694
3695         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
3696           added creation of model-mcs51-stack-auto libraries
3697
3698 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
3699
3700         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
3701         and fields-list too
3702         * src/SDCCast.c (createIvalArray): removed obsolete comment
3703
3704 2005-11-24 Borut Razem <borut.razem AT siol.net>
3705
3706         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
3707           added missing device/lib/mcs51/crt*.asm sources
3708
3709 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
3710
3711         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
3712
3713 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
3714
3715         * device/lib/_fs2schar.c,
3716         * device/lib/_fs2sint.c,
3717         * device/lib/_fs2slong.c: optimized inline asm
3718
3719 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3720
3721         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
3722           Better handling of floats between -1.0 and 0.0.
3723
3724 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3725
3726         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
3727           (the missing "if"s prohibited removal of redundant labels)
3728
3729 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3730
3731         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
3732           Properly convert floats between -1.0 and 0.0 to long, int, and char
3733           types (max integer value of negative floats tends to zero).
3734         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
3735           Removed changes made so to work properly with floats between
3736           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
3737           and _fs2char.c
3738
3739 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
3740
3741         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
3742         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
3743         (genCast) cosmetic change
3744         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
3745         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
3746         from mcs51
3747         * support/regression/tests/bitfields (testSignedBitfields): added
3748
3749 2005-11-18 Borut Razem <borut.razem AT siol.net>
3750
3751         * sdcc/device/lib/Makefile.in: remove all unnecessary files
3752         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
3753           introduced SILENT option to make building of pic16 libraries less
3754
3755 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3756
3757         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
3758           Now they work properly with floats between -1.0 and 0.0
3759         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
3760
3761 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
3762
3763         * src/SDCCicode.c (printOperand): added missing else
3764
3765 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
3766
3767         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
3768         reformatted for better readability
3769         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
3770         signed bitfields
3771
3772 2005-11-17 Borut Razem <borut.razem AT siol.net>
3773
3774         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
3775           introduced SILENT option to make building of pic16 libraries less
3776           verbose - used for nightly snapshot build
3777         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
3778           available on Win32 platforms.
3779         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
3780           medium, large, pic and pic16
3781
3782 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3783
3784         * device/lib/printf_large.c: Temporary patch for bug 1358192:
3785           printf("%f"...) sets fraction to zero.
3786
3787 2005-11-16 Raphael Neider <rneider AT web.de>
3788
3789         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
3790           fixes #1357221
3791         * src/pic/gen.c (genIfx): implemented for CARRY bit
3792         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
3793           to generic pointers, fixes #1357332,
3794           (pic16_movLit2f): NEW,
3795           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
3796
3797 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
3798
3799         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
3800
3801 2005-11-11 Raphael Neider <rneider AT web.de>
3802
3803         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
3804         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
3805           compute pointer's type from operand,
3806           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
3807           improved single bit reads, fixes bug #1353379
3808
3809 2005-11-09 Borut Razem <borut.razem AT siol.net>
3810
3811         * support/scripts/sdcc.nsi: added lib/pic to the package
3812
3813 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
3814
3815         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
3816
3817 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
3818
3819         * support/regression/tests/bug1348008.c: added
3820         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
3821         * support/regression/tests/bug1337835.c: updated comment
3822
3823 2005-11-06 Borut Razem <borut.razem AT siol.net>
3824
3825         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
3826           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
3827           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
3828           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
3829           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
3830           dynamic construction of cl_error_class and derivates - 2.nd try
3831
3832 2005-11-05 Borut Razem <borut.razem AT siol.net>
3833
3834         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
3835           bug, which caused Bus Errors on sparc solaris
3836
3837 2005-11-04 Borut Razem <borut.razem AT siol.net>
3838
3839         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
3840           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
3841           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
3842           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
3843           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
3844           and derivates to resolve the initialization problem on OSX
3845
3846 2005-11-02 Borut Razem <borut.razem AT siol.net>
3847
3848         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
3849           corrected typo - #include <winsock2.h>
3850
3851 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
3852
3853         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
3854           (_asxxxx_mapping): added org directive for future enhancements
3855
3856 2005-11-01 Borut Razem <borut.razem AT siol.net>
3857
3858         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
3859           enabled sockets on WIN32
3860         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
3861
3862 2005-10-31 Borut Razem <borut.razem AT siol.net>
3863
3864         * support/regression/generate-cases.py: escape backslashes in {testcase}:
3865           WIN32 backslash path delimiters should be escaped when used in C strings
3866         * support/regression/tests/bitfields.c: exclude failing assertions for
3867           __CYGWIN32__ and __MINGW32__ hosts
3868
3869 2005-10-30 Borut Razem <borut.razem AT siol.net>
3870
3871         * src/SDCCutil.c: corrected double comparison typo
3872
3873 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
3874
3875         * device/lib/medium/Makefile: added for new memory model medium
3876         * device/include/asm/mcs51/features.h: updated for medium/pdata
3877         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
3878           added Multiply & Accumulate sbit's and MAC0_PAGE define
3879         * device/include/mcs51/c8051f300.h: added sfr16 definitions
3880         * device/include/mcs51/c8051f310.h: added sfr16 definitions
3881         * device/lib/_mullong.c: update for medium model
3882         * device/lib/incl.mk: added medium model
3883         * doc/sdccman.lyx: documented medium model
3884         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
3885         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
3886         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
3887         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
3888           (allocParms): set SCLS and OCLS to pdata for medium model
3889         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
3890           for pdata,
3891           (powof2): return <0 if not power of 2
3892         * src/avr/gen.c (genBitWise): use updated powof2
3893         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
3894           (shiftR2Left2Result): small optimization in setup, save acc when storing,
3895           (shiftLLeftOrResult): use B if necessary
3896         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
3897         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
3898         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
3899         * support/regression/Makefile.in: added test-mcs51-medium
3900         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
3901
3902 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
3903
3904         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
3905         specifier unsigned
3906         * device/lib/time.c (mktime): fixed bug 1334315
3907
3908 2005-10-28 Raphael Neider <rneider AT web.de>
3909
3910         * device/include/pic/p16f_common.inc: added common declarations
3911         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
3912
3913 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
3914
3915         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
3916           (aopPutUsesAcc): added to predict accumulator use,
3917           (assignResultValue): save acc if necessary,
3918           (genMinusDec): store result if indirectly addressed,
3919           (genDivOneByte):  save acc if necessary,
3920           (movLeft2Result): bugfix if left already in acc,
3921           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
3922             attention to accumulator use (esp. pdata),
3923           (genReceive): receive pdata correctly
3924         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
3925         * src/SDCCicode.h: added isOperandInPagedSpace prototype
3926
3927 2005-10-27 Raphael Neider <rneider AT web.de>
3928
3929         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
3930
3931 2005-10-27 Raphael Neider <rneider AT web.de>
3932
3933         * .version: changed version to 2.5.4
3934         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
3935         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
3936           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
3937             arithmetics support routines
3938         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
3939         * device/lib/Makefile.in: also create installdir for pic
3940
3941         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
3942           pic14 port as well
3943         * src/pic/device.c (dump_sfr): rewritten to delegate register
3944           placement to the linker (use `extern sym' rather than sym EQU addr),
3945           (validAddress): fixed to check last specified address
3946         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
3947           (popGetLit): truncate literal value to 8 bit,
3948           (popGet): moved assert to more appropriate place
3949           (popGetExternal): create pCode operand from and mark the according
3950             symbol as being `extern'
3951           (popGetAddr): added sanity check on immediate's offset, provide
3952             GPOINTER tag on demand
3953           (aopPut): fixed for immediates,
3954           (mov2w_op): move operand's address or contents to WREG (depending on
3955             operand type), safer variant of mov2w,
3956           (movwf,call_libraryfunc): NEW, handy abbreviations,
3957           (get_argument_pcop,get_return_val_pcop,pass_argument,
3958           get_returnvalue): interface for accessing function parameters and
3959             return values,
3960           (assignResultValuei,genRet): use new parameter/return value interface
3961           (pic14_getDataSize): back to old version handling generic pointers,
3962           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
3963             provided implementation and/or fixed old one,
3964           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
3965             calls, removed legacy 8051 reference code
3966           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
3967           (loadSignToC): NEW, move the operands sign bit to CARRY,
3968           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
3969             genRightShiftSigned, accepts negative shift counts,
3970           (setup_fsr): load FSR and adjust IRP (indirect memory access),
3971           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
3972             generic pointers, __data pointers and __code pointers,
3973           (genUnpackBits,genPackBits): rewritten to work with generic pointers
3974             and signed bitfields, limit bitfields to 8 bit,
3975           (genDataPointerGet): fixed number of bytes read,
3976           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
3977           (genPointerGet,genPointerSet): fixed handling of __code pointers,
3978             pointers to constant data are no longer assumed to point to __code
3979             space, removed invalid pointer types,
3980           (bitpatternFromVal): retrieve the PICs representation of an integer
3981             or float literal,
3982           (genDataPointerSet): fixed assigning to po_immediate operands,
3983           (genGenPointerSet): implemented as library call,
3984           (genIfx): fixed incorrect condition,
3985           (genAddrOf): limit generic pointers' addresses to 2 bytes,
3986             provide GPOINTER tag according to destination's storage class,
3987           (genCast): added code to handle casting to generic pointers, added
3988             sign-/zero extension of the result
3989           (aop_isLitLike,op_isLitLike): fixed handling of immediates
3990         * src/pic/gen.h: added macros to access IRP bit in STATUS register
3991         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
3992           extend the result
3993         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
3994           address/register resides in the shared banks
3995           (emitSymbolToFile): improved to handle global and `pinned' symbols,
3996             put all variables into separate sections (have the linker arrange
3997             them)
3998           (picglue): put init code and interrupt handlers in separate sections
3999         * src/pic/main.c: added port specific options table, modified to PORT
4000           structure to make GPOINTERs 3 byte, added pic14_options
4001           (_pic14_do_link): private linking routine (update paths to libraries,
4002             add libsdcc.lib by default)
4003         * src/pic/main.h: declare pic14_options
4004         * src/pic/pcode.c: fixed instructions i/o relations,
4005           (RegCond): reverted to correct version,
4006           (newpCodeOpLit): truncate literals to 8 bit,
4007           (genericPrint): added debug output,
4008           (getRegFromInstruction): fixed for various operand types, simplified
4009           (BuildFlow): fixed broken handling of isntructions with labels
4010           (LinkFlow): start at last instruction in flow (skip trailing comments),
4011             pass the flow on to the next instruction after CALL
4012           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
4013           (insertPCodeInstruction): fixed inserting after a skip instruction,
4014           (DoBankSelect): fixed for labeled instructions
4015           (OptimizepBlock): honor --nopeep switch
4016           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
4017         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
4018         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
4019           (pCodeOptime2pCodes): allow disabling this optimization via
4020             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
4021             but is still buggy), started implementation of a dataflow based
4022             pCode optimization (CSE + dead code elimination)
4023           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
4024         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
4025           names are independant of the stack location and therefore portable across
4026           devices
4027
4028 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
4029
4030         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
4031           (selectSpil): fixed bug 1337835 by not spilling bit variables
4032         * support/regression/tests/bug1337835.c: added test for this bug
4033         * src/mcs51/peeph.def: restart after rule 3.c,
4034           addded rules 263.x to optimize loading constants
4035
4036 2005-10-26 Raphael Neider <rneider AT web.de>
4037
4038         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
4039         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
4040           (genAssign): emit warning when casting literals to generic pointer
4041             type, also applies when taking the address of a fixed variable,
4042           (genCast): improved casting to generic pointers
4043         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
4044           extern variables, added verbose error message
4045         * device/include/pic16/{string.h,errno.h}: added #pragma library c
4046
4047 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
4048
4049         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
4050         carry must be complemented too
4051         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
4052         could be emitted by genMinus
4053         * src/SDCCval.c (constVal): fixed bug 1305065
4054
4055 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
4056
4057         * src/SDCCast.c (addCast): added promotion for bit variables
4058         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
4059         promotion casts + optimisation
4060         (optimizeGetWord): fix warning 'i' might be used uninitialized
4061         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
4062         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
4063
4064 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
4065
4066         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
4067         all chars are promoted to int; promotion should be handled in SDCCast.c
4068
4069 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4070
4071         * device/lib/_strcmp.c: Fixed bug 1326457
4072
4073 2005-10-11 Raphael Neider <rneider AT web.de>
4074
4075         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
4076         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
4077
4078 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4079
4080         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
4081         * support/regression/tests/sfr16.c: added test for the sfr32 bug
4082
4083 2005-10-04 Raphael Neider <rneider AT web.de>
4084
4085         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
4086           device/lib/pic16/pics.all: added pic18f1320
4087         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
4088
4089 2005-09-30 Raphael Neider <rneider AT web.de>
4090
4091         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
4092         * src/pic16/devices.inc: NEW, provides device descriptions
4093         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
4094
4095 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
4096
4097         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
4098           GETHBIT
4099
4100 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
4101
4102         * doc/sdccman.lyx: updated Highest Order Bit documentation,
4103           documented Any Order Bit, Higher Order Byte and Higher Order Word
4104         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
4105         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
4106           (optimizeGetAbit): new, to get any bit, not only the high bit,
4107           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
4108           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
4109           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
4110           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
4111             RIGHT_OP: also try GETBYTE, GETWORD optimization,
4112             GETABIT, GETBYTE, GETWORD: decorate them,
4113           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
4114           (ast_print): added GETABIT, GETBYTE, GETWORD
4115         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
4116         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
4117           (geniCodeBinary): new generic binary icode,
4118           (ast2iCode): added GETABIT, GETBYTE, GETWORD
4119         * src/port.h: updated comment for PORT.hasExtBitOp
4120         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
4121           (genGetByte): new, to get a single byte,
4122           (genGetWord): new, to get a word from a long,
4123           (gen51Code): added GETABIT, GETBYTE, GETWORD
4124         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
4125
4126 2005-09-23 Raphael Neider <rneider AT web.de>
4127
4128         * configure.in, configure: have device/lib/pic configured
4129         * device/lib/Makefile.in: added model-pic14
4130         * device/lib/clean.mk: added pic/ to clean rule
4131         * device/lib/pic: added rudimentary pic14 library providing support
4132           functions for multiplication/division/generic pointer access
4133         * src/SDCCopt.c (convilong): mark support functions as extern
4134           for pic14 port as well
4135         * src/pic/gen.c (genMult): added assertions,
4136           (genpic14Code): emit warning on unhandled iCodes
4137         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
4138         * src/pic/pcode.c (pCodeOpCopy),
4139         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
4140           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
4141           SFR_REGISTER}), made safe for future extensions
4142         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
4143           instructions even if preceeded by SKIP instructions (also remove
4144           them); removed unused code
4145         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
4146           prevents leaving parts of the structure uninitialized after copying
4147
4148 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
4149
4150         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
4151           ago by me
4152         * support/regression/tests/addsub.c: added test for the bug
4153
4154 2005-09-21 Raphael Neider <rneider AT web.de>
4155
4156         * device/include/pic16/pic18f1220.h,
4157           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
4158         * device/lib/pic16/Makefile.rules: added missing opening paren
4159         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
4160           are provided in genutils.c,
4161           (genUminusFloat,genUminus,genCmpEq): added asserts on different
4162           operand/result sizes,
4163           (genCmp): assert on NULL pointers first, then check deref'ed values
4164         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
4165           result size
4166
4167 2005-09-18 Raphael Neider <rneider AT web.de>
4168
4169         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
4170           as these are now unused,
4171           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
4172         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
4173           local, avoids uninitialized pointer dereference on r->name
4174         * src/pic16/ralloc.c (newReg): fixed indentation
4175
4176 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
4177
4178         * src/SDCCval.c (constVal): fixed bug 730366
4179         * support/Util/SDCCerr.c,
4180         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
4181
4182 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
4183
4184         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
4185
4186 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
4187
4188         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
4189
4190 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
4191
4192         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
4193           (hex2dec): made hex_digit unsigned char, removed ascii dependance
4194         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
4195           (hex2dec): made hex_digit unsigned char, removed ascii dependance
4196         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
4197         * packihx/packihx.c (hexDigit): made c unsigned char
4198         * as/mcs51/lklibr.c (fndsym),
4199         * link/z80/lkgb.c (gb),
4200         * link/z80/lklibr.c (fndsym),
4201         * link/z80/lkrloc.c (relr),
4202         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
4203         * src/SDCC.lex (checkCurrFile, process_pragma),
4204         * src/SDCCglue.c (spacesToUnderscores),
4205         * src/SDCCmain.c (setParseWithComma, processFile),
4206         * src/asm.c (tvsprintf, printCLine),
4207         * src/avr/gen.c (emitcode, aopPut),
4208         * src/ds390/gen.c (emitcode),
4209         * src/hc08/gen.c (emitcode, emitinline),
4210         * src/mcs51/gen.c (emitcode, genInline),
4211         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
4212           tokenizeLineNode),
4213         * src/pic/ralloc.c (debugLog),
4214         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
4215           tokenizeLineNode),
4216         * src/pic16/ralloc.c (debugLog),
4217         * src/z80/main.c (_process_pragma):
4218            made all ctype.h function calls safe
4219         * src/SDCCopt.c: include math.h for fabs
4220         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
4221           and used them throughout the code to make ctype.h function calls safe
4222         * src/ds390/main.c (asmLineNodeFromLineNode),
4223         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
4224         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
4225            unsigned char*
4226         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
4227           (newpCodeAsmDir): made ctype.h function calls safe
4228         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
4229           pic16_emitcode):  made lbp unsigned char*
4230         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
4231           (pic16_newpCodeAsmDir): made ctype.h function calls safe
4232         * src/xa51/gen.c (emitcode),
4233         * src/z80/gen.c (_emit2): made lbp unsigned char*
4234         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
4235            char*
4236
4237 2005-09-05 Raphael Neider <rneider AT web.de>
4238
4239         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
4240           access bank splitpoint
4241
4242 2005-09-05 Raphael Neider <rneider AT web.de>
4243
4244         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
4245
4246 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
4247
4248         * .version: changed to version 2.5.3
4249         * doc/sdccman.lyx: changed version to 2.5.3,
4250           documented --codeseg and --constseg and pragma codeseg and constseg,
4251           documented bit parameters (reentrant) and bit returning
4252         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
4253            currFunc->recvSize, but is this ok for all ports?
4254           (ast2iCode): result of ~ on unsigned char must be cast to int for
4255            bool to work
4256         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
4257           function pointers in bit space
4258         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
4259           (processFuncArgs): call port.reg_parm() with reentrancy info
4260         * src/port.h,
4261         * src/avr/main.c,
4262         * src/ds390/main.c,
4263         * src/hc08/main.c,
4264         * src/pic/main.c,
4265         * src/pic16/main.c,
4266         * src/xa51/main.c,
4267         * src/z80/main.c: port.reg_parm prototype extended with
4268           "bool reentrant" parameter
4269         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
4270           options.stackAuto for allocating bit register parameters
4271         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
4272           (genSend): set BitBankUsed if it is,
4273           (selectRegBank): factored out of genCall for use in genPcall,
4274           (genCall): removed redundant dtype assignmen, use selectRegBank,
4275           (genPcall): handle returning in Carry properly, save in F0 if needed,
4276           (genReceive): handle bit register parameters
4277         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
4278           (mcs51_assignRegisters): enable bit registers for all reentrant
4279            functions and don't set BitBankUsed unconditionally
4280         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
4281         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
4282         * support/regression/tests/funptrs.c: added tests for BOOL and for return
4283
4284 2005-08-27 Borut Razem <borut.razem AT siol.net>
4285
4286         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
4287         ppc-osx (Darwin) does not support -u option. It seems that it is
4288         supported only on Linux - GNU cp
4289
4290 2005-08-25 Borut Razem <borut.razem AT siol.net>
4291
4292         * sim/ucsim/gui.src/serio.src/Makefile.in,
4293           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
4294           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
4295           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
4296           install and strip, since the strip at /usr/ccs/bin should be used
4297           on solaris
4298
4299 2005-08-24 Borut Razem <borut.razem AT siol.net>
4300
4301         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
4302
4303 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
4304
4305         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
4306         ffffffffu
4307
4308 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
4309
4310         * as/mcs51/aslink.h: completed lkrloc.c prototypes
4311         * as/mcs51/lkmain.c (link_main): fixed warning
4312         * device/include/stdbool.h: ds390 has no advanced bit support yet
4313         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
4314         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
4315         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
4316           and updated their macros
4317         * src/SDCCval.c (constVal): updated comment for renamed b_long
4318
4319 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
4320
4321         * as/mcs51/asdata.c: changed ctype['['] to BINOP
4322         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
4323           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
4324           (oprio): set priority for '['
4325         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
4326            and adb_24_bit
4327         * as/mcs51/asm.h: added defines R_BIT and S_BIT
4328         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
4329         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
4330         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
4331           added overlayable BIT_BANK area
4332         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
4333           (summary2): explain 'T' in legenda
4334         * as/mcs51/lkrloc.c: replaced old K&R style,
4335           (relr): added R_BIT processing,
4336           (errmsg): added "Bit-addressable relocation error",
4337           (adb_bit): added for converting from byte- to bit-addressable space,
4338           (adb_24_bit): added for converting from byte- to bit-addressable space
4339         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
4340            used in reentrant functions now even as return value
4341         * device/lib/_gptrput.c (_gptrput): removed obsolete code
4342         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
4343           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
4344         * src/SDCCglobl.h: added indicator BitBankUsed
4345         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
4346            the bit registers b0-b7
4347         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
4348           (geniCodeCast): fixed bug 1263853,
4349           (geniCodeLogicAndOr): put result in bool or char,
4350           (geniCodeReceive): added parameter func for accessing the return type,
4351           (geniCodeFunctionBody): pass func to geniCodeReceive
4352         * src/SDCCmain.c: added indicator BitBankUsed
4353         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
4354         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
4355           (checkSClass): don't put automatic bool/bit on stack,
4356           (checkFunction): removed check on function cannot return bit
4357         * src/SDCCsymt.h: added newBoolLink prototype
4358         * src/mcs51/gen.c (rb1regs): added bit registers,
4359           (movc): created for assigning to carry,
4360           (pushReg, popReg): created for pushing registers,
4361           (sameRegs): check both AOP_REG and AOP_CRY types,
4362           (aopOp): handle bit registers,
4363           (aopPut): optimization no self-assign,
4364           (saveRegisters): push reg->base (bits) only once for bit registers,
4365            and use pushReg,
4366           (unsaveRegisters): pop reg->base only once and use popReg,
4367           (assignResultValue): added parameter func and return in carry for bits,
4368           (genIpush): optimization no reload in A if not changed,
4369           (genSend): bit parameters in reentrant functions are passed in bit
4370            registers by first assigning to bits in B, then save registers and
4371            copy B to bits,
4372           (genCall): handle returning in Carry properly, save it in F0 if needed,
4373           (genPcall): updated assignResultValue call, this is not safe yet for bit
4374            returning function !!!
4375           (genFunction): don't generate equ's for bit registers and use pushReg,
4376           (genEndFunction): take care of bit returning functions and use popReg,
4377           (genRet): return bit in Carry,
4378           (genIfx): optimize bit registers and other directly addressable bits,
4379           (genReceive): updated assignResultValue call
4380         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
4381           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
4382            registers when using stack-auto
4383         * src/mcs51/ralloc.c (_G): added allBitregs,
4384           (regs8051): added the bit registers,
4385           (createStackSpil): use macro IS_BIT,
4386           (getRegBit): added to allocate a bit register, else spill,
4387           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
4388           (updateRegUsage): factored out to ease stepping while debugging,
4389           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
4390            also allocate bit registers,
4391           (fillGaps): handle bit registers,
4392           (findAllBitregs): added to create bit vector with all bit registers,
4393           (mcs51_allBitregs): returns this bit vector,
4394           (mcs51_assignRegisters): when using stack-auto use bit registers for
4395            passing parameters and creating local variables
4396         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
4397
4398 2005-08-22 Borut Razem <borut.razem AT siol.net>
4399
4400         * device/lib/Makefile.in: replaced find option -or with -o
4401           to make it run on solaris
4402
4403 2005-08-22 Raphael Neider <rneider AT web.de>
4404
4405         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
4406           fixes #1265442 (crash on Solaris)
4407
4408 2005-08-20 Borut Razem <borut.razem AT siol.net>
4409
4410         * configure, configure.in: added tests for libsocket and libnsl libraries,
4411           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
4412           from support/regression/Makefile.in
4413         * support/regression/Makefile.in: added
4414         * device/lib/pic16/Makefile.common.in: force make to use bash shell
4415         * sim/ucsim/libtool: regenerated on sparc-solaris
4416         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
4417           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
4418           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
4419           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
4420           sparc-solaris, which doesn't use GNU ld linker
4421         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
4422         * as/Makefile: find on sparc-solaris does not support -maxdepth option
4423
4424 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
4425
4426         * src/mcs51/peeph.def: updated comments
4427
4428 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4429
4430         * device/lib/_gptrget.c,
4431         * device/lib/_gptrput.c: slightly shorter
4432         * doc/sdccman.lyx: incremented version
4433         * src/mcs51/peeph.def: moved peephole comments to the line of first
4434           change to better keep line correlation, reanimated 186.e
4435         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
4436
4437 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
4438
4439         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
4440           David Saxton with quotes around file name.
4441
4442 2005-08-15 Borut Razem <borut.razem AT siol.net>
4443
4444         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
4445           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
4446           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
4447           make tests run on x86_64 platform
4448
4449 2005-08-13 Raphael Neider <rneider AT web.de>
4450
4451         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
4452           as it might be executed DURING a build (parallel make is wonderful)
4453
4454 2005-08-13 Raphael Neider <rneider AT web.de>
4455
4456         * device/lib/Makefile.in (port-specific-objects-pic16):
4457           revert to cp $(PORT)/bin/*.* $(PORTDIR)
4458         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
4459           dependency
4460         * device/lib/pic16/Makefile.rules: build subdirs before creating
4461           the library, removed builddir rule, create $(builddir) early in
4462           recurse rule, use empty recurse rule for leaf directories
4463         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
4464           mkdir errors (race condition), removed duplicate suffix "hex"
4465           from clean rules
4466         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
4467         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
4468           prevents mkdir -p from aborting on Alpha
4469
4470 2005-08-12 Raphael Neider <rneider AT web.de>
4471
4472         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
4473           db-statements in order to allow for arrays of pointers in code
4474           sections to be placed without interspersed 0-padding, fixes
4475           bug #1256215
4476         * (emitStatistics): fixed division by zero for pic18f1220
4477         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
4478           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
4479         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
4480         * (pic16_pCodeConstString): keep track of already emitted string
4481           literals to prevent "duplicate definitions of symbol _str_NR"
4482         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
4483           debug message
4484         * device/lib/Makefile.in: ignore failing PIC16 library builds
4485         * device/lib/pic16/Makefile: do not build if gputils are missing
4486         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
4487
4488 2005-08-10 Raphael Neider <rneider AT web.de>
4489
4490         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
4491           my last commit)
4492
4493 2005-08-10 Raphael Neider <rneider AT web.de>
4494
4495         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
4496           Rokas' patch to add the new fixed point type "__fixed16x16"
4497         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
4498           functions for __fixed16x16 arithmetics
4499         * device/lib/pic16: reimplemented the build system to support
4500           a separate build directory, better handling of libio (create
4501           the library in a separate subdir for each architecture) and
4502           easier configuration (centralized in Makefile.common)
4503
4504 2005-08-07 Raphael Neider <rneider AT web.de>
4505
4506         * src/pic16/gen.c (genrshTwo): fixed sign extension
4507         * src/pic16/device.c: added pic18f2320, 4220 and 4320
4508         * device/include/pic16/pic18f2220.h: changed some bit definitions,
4509           added T0CONbits
4510         * device/include/pic16/pic18f4220.h: NEW, header for
4511           pic18f4220 and pic18f4320
4512         * device/include/pic16/pic18fregs.h: added new devices,
4513           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
4514         * device/include/pic16/signal.h: resolved name clashes
4515           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
4516           to also allow testing for interrupt enable bits, added
4517           comments on how to use the macros
4518         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
4519         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
4520           register definitions for the devices
4521         * device/lib/pic16/pics.all: added new devices
4522         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
4523           allocated memory
4524         * device/lib/pic16/libc/stdlib/memfree: do not count
4525           the block header as free memory
4526         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
4527           simplified and added missing end-of-blocklist-marker
4528           (reported by Peter Onion, fixes #1252814)
4529         * (_mergeHeapBlock): fixed loop condition
4530         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
4531           len==0, restructured code
4532         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
4533           up a bit, reduced bitfield accesses, prevent endless loops
4534           in case of heap corruption
4535         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
4536           "unreferenced arguments/must return a value" warnings
4537         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
4538           replaced BAUDREG with SPBRG
4539         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
4540           device/lib/pic16/debug/gstack/gstack.c: replaced
4541           _naked, _asm, _endasm with __naked, __asm, __endasm
4542
4543 2005-08-05 Raphael Neider <rneider AT web.de>
4544
4545         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
4546           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
4547
4548 2005-08-05 Borut Razem <borut.razem AT siol.net>
4549
4550         * device/lib/Makefile.in: added missing ';'
4551         * configure: removed ^M characters
4552
4553 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4554
4555         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
4556           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
4557           License
4558
4559 2005-08-04 Borut Razem <borut.razem AT siol.net>
4560
4561         * configure.in: pic16 libraries build 2nd try - enable running
4562           configure in device/lib/pic16
4563         * configure: regenerated from configure.in
4564         * device/lib/Makefile.in: create $(PORT)/bin directory
4565
4566 2005-08-03 Raphael Neider <rneider AT web.de>
4567
4568         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
4569           to get/set values via pointers
4570         * (genUnpackBits,genPackBits): changed detection of
4571           ptr->bitfield vs. sym.bitfield, fixed access via generic
4572           pointers, removed dead (wrong) code for multibyte bitfields
4573         * (genNearPointerGet, genGenPointerGet): removed useless code,
4574           fixed bitfield detection, fixes #1250594
4575         * (genNearPointerSet): removed useless code
4576         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
4577           and introduced macro pic16_emitpcode that conditionally emits
4578           the origin of the following pCode (useful for debugging SDCC)
4579         * src/pic16/pcode.c: changed (and disabled) some debug outputs
4580         * (createDefmap): fixed handling of LFSR for --optimize-df
4581
4582 2005-08-02 Borut Razem <borut.razem AT siol.net>
4583
4584         * device/lib/Makefile.in: pic16 libraries build enabled since
4585           gputils-0.13.2 are now localy installed at sourceforge's compile farm
4586
4587 2005-08-02 Raphael Neider <rneider AT web.de>
4588
4589         * src/pic16/gen.c (genPackBits): removed deprecated warning
4590         * (genGenPointerSet): fixed bitfield detection
4591
4592 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4593
4594         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
4595
4596 2005-07-31 Raphael Neider <rneider AT web.de>
4597
4598         * device/lib/pic16/libdev/pic18f458.c,
4599           device/include/pic16/pic18f458.h: added missing T0CONbits
4600
4601 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
4602
4603         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
4604
4605 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
4606
4607         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
4608
4609 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4610
4611         * device/include/mcs51/at89c51ed2.h: added.
4612
4613 2005-07-23 Raphael Neider <rneider AT web.de>
4614
4615         * src/pic/gen.h: added emitpcode macro for debugging
4616         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
4617           and replace by macro adding debug information on demand
4618         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
4619         * (gencjne): tried to fix; replaced with correct (slower) code
4620         * (gen{Unp,P}ackBits): fixed single bit access
4621         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
4622         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
4623           previous instruction
4624         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
4625           register has to be handled with care (forbidding movement
4626           of assignments/uses, removing assignments completely, ...)
4627         * (pCodeOptime2pCodes): make use of regIsSpecial
4628         * added lots of debugging output (commented out)
4629         * src/pic/rallloc.c (deassignLRs): prevent operand registers
4630           from being reused as result UNLESS it is known to work
4631
4632 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
4633
4634         * support/Util/dbuf.h: include <stddef.h> for size_t
4635         * .version: changed to version 2.5.2
4636
4637 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4638
4639         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
4640
4641 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4642
4643         * src/hc08/gen.c (genMinus): fixed bug #1241835,
4644           (genModOneByte): removed needless psha/pula
4645
4646 2005-07-22 Raphael Neider <rneider AT web.de>
4647
4648         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
4649           have PIC14 handled like PIC16, fixes broken pic14 linker calls
4650         * src/pic/gen.c (resolveIfx): do not "invent" labels
4651         * (genSkipc): changed to positive logic
4652         * (genSkipCond): removed as no longer needed
4653         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
4654           backport from PIC16
4655         * (genLeftShift): check operands are in different registers
4656         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
4657           INCF does not update CARRY...
4658         * src/pic/main.c: fixed _linkCmd
4659         * src/pic/pcode.c (unlinkpCode): added inactive code
4660         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
4661           alive (do not assign result and operand overlapping registers)
4662
4663 2005-07-22 Raphael Neider <rneider AT web.de>
4664
4665         * src/pic/device.c (dump_sfr): replaced register declaration with
4666           call to emitSymbolToFile() to avoid duplicate symbols
4667         * (assignRelocatableRegisters): do not declare external symbols
4668         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
4669           right (take size of type, not etype)
4670         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
4671         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
4672         * (packRegsForAccUse): disabled assignment of WREG as
4673           the result reg to prevent occurence of just fixed #1235003,
4674           fixes #1242954
4675         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
4676           symbols (avoids duplicate symbols in .asm file)
4677         * (pic14emitRegularMap): use emitSymbolToFile()
4678         * src/pic/gen.c (aopOp): fixed spillLocation handling
4679         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
4680         * (genDataPointerSet): removed unneccessary variables/output
4681
4682 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
4683
4684         * as/mcs51/lkarea.c: enlarged codemap for banked memory
4685         * device/lib/mcs51/crtbank.asm: added # to 0x0F
4686
4687 2005-07-21 Raphael Neider <rneider AT web.de>
4688
4689         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
4690           architecture cannot handle them efficiently, fixes bug #1235003
4691         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
4692           check for empty sets before using them (fixes bug #1232190)
4693
4694 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
4695
4696         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
4697           (lnksect2): generate warnings for memory overlap
4698         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
4699           constseg to set the name of these segments so you can instruct the linker
4700           to place them in banks
4701         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
4702         * src/SDCCglobl.h: added MODEL_HUGE to enum,
4703           added code_seg and const_seg to options
4704         * src/SDCCglue.c (emitMaps): use options.const_seg,
4705           (createInterruptVect): put interrupt vectors in segment HOME,
4706           (glue): put HOME before static segment and put the main glue in HOME,
4707           (glue): use options.code_seg
4708         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
4709         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
4710           these segments so you can instruct the linker to place them in banks
4711           (linkEdit): use code_loc for HOME segment which should be the first
4712           segment in code memory now
4713         * src/SDCCmem.c: fixed more stuff like bug 1238386
4714         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
4715           (changePointer): don't change function pointers to code pointers for
4716           banked functions,
4717           (compareType): added exceptional check for banked function pointers
4718         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
4719         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
4720           after static in code memory
4721         * src/mcs51/gen.c: added aopLiteralLong prototype,
4722           (aopForSym): use getSize for functions,
4723           (genCall): generate banked calls over one trampoline __sdcc_banked_call
4724           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
4725           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
4726           the segment,
4727           (genPcall): use call for literal function pointers and generate banked
4728           calls over the one trampoline so there's only one place for the user to
4729           modify according to his/hers hardware,
4730           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
4731           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
4732         * src/mcs51/main.c: added keyword banked,
4733           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
4734         * support/Util/SDCCerr.c,
4735         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
4736           needed for passing the bank and address to the trampoline
4737         * device/lib/mcs51/crtbank.asm: added for bankswitching
4738         * device/lib/mcs51/Makefile: added crtbank
4739
4740 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4741
4742         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
4743           for fields at offset 0 of a struct or union as reported
4744           on 2005-07-07 in the developer mailing list.
4745
4746 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
4747
4748         * src/SDCCmem.c: fixed bug 1238386
4749
4750 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4751
4752         * src/mcs51/peeph.def: added labelrefcounting for peepholes
4753           (patch #1144962), added peephole 300, enabled 259.x
4754         * doc/sdccman.lyx: removed screenshot and provided link instead
4755
4756 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4757
4758         * doc/sdccman.lyx: added section about debugging with ddd
4759         * doc/figures/ddd_example.eps: screenshot of debugging session
4760
4761 2005-07-04 Raphael Neider <rneider AT web.de>
4762
4763         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
4764           like CODE pointers, fixes #1115683
4765         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
4766           call, fixes bugs #1232211, #1228110,
4767           fixed wrong casts to pCodeFlow from pCodeInstructions
4768
4769 2005-07-04 Raphael Neider <rneider AT web.de>
4770
4771         * src/pic/gen.c (popGet): changed assert to allow for
4772           bit operands
4773         * (popGetAddr): changed signature to provide
4774           an additional index, patched all call sites
4775         * (genCmpEq): handle literal-like operands correctly
4776         * (genAddrOf): added sanity checks on __code/__data pointers
4777         * (genAssign): added handling of symbols from __code section
4778         * (gencjne): do not generate code for comparisons whose result
4779           is neither stored nor used, fixes bug #1171114
4780         * (AccLsh, AccRsh): operate on operand instead of WREG
4781         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
4782           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
4783           by known count
4784         * rewrote complete shift-by-literal logic, commented unused
4785           functions out
4786         * (genConstPointerGet): get multiple bytes (if result size > 1),
4787           fixed handling of non-immediate addresses
4788         * (genPointerGet): handle CODE pointers like CONST pointers
4789         * (genpic14Code): insert C-SRC lines as Cource-pCodes
4790         * ({aop,op}_isLitLike): NEW, single place to decide whether an
4791           operand is to be treated as a literal or not
4792         * (mov2w,genPcall,genCmpEq),
4793           src/pic/genarith.c: use aop_isLitLike() to decide between
4794           literal/register contents
4795         * (addSign): added missing offset
4796         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
4797           only emit comment in debug-mode,
4798           use {aop,op}_isLitLike throughout the file
4799         * src/pic/glue.c: fix initializers for pointers (work in progress)
4800         * src/pic/pcode.c (get_op): honor index on _const symbols
4801         * ({reset,dump}pCodeStatistics): NEW, estimate code size
4802         * (dumppBlock): added pCode size estimation
4803         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
4804           check for IS_SYMOP before OP_SYMBOL'ing
4805         * fixed indentation, compacted switch-statements
4806         * (allocReg): find free register and allocate it instead of
4807           allocating new registers all the time
4808         * (deassignLRs): prevent POINTER_GET's from being assigned the same
4809           registers as its operands (necessary only for multibyte GETs)
4810
4811 2005-07-01 Raphael Neider <rneider AT web.de>
4812
4813         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
4814           debugging .asm-output macros FENTRY + FEXIT
4815         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
4816           way... I wonder...
4817         * (emitpComment): NEW, printf to pCode
4818         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
4819           offset handling
4820         * (popGetAddr): NEW, variant of popGet to access an immediates
4821           high(er) bytes instead of the n'th byte of memory they reference,
4822           replaced popGet with popGetAddr where neccessary
4823         * (genDataPointerGet): reactivated and fixed implementation
4824         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
4825           accesses
4826         * (genDataPointerSet): fixed multibyte assignments
4827         * (genpic14Code): fixed --i-code-in-asm handling
4828         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
4829         * (genPlus): fixed index-out-of-bounds error
4830         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
4831         * src/pic/ralloc.c: added debugging output macro FENTRY2
4832         * (spillThis): fixed indentation, enbraced for-body for clarity
4833         * (rematStr): commented out as now unused
4834         * (regTypeNum): commented out special spill case (overwrites
4835           arbitrary values)
4836         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
4837
4838 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
4839
4840         * doc/sdccman.lyx: documented sfr16/sfr32,
4841           added example for using storage class with function pointers
4842         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
4843
4844 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
4845
4846         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
4847         * device/lib/_itoa.c,
4848         * device/lib/_ltoa.c: optimized codesize
4849         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
4850           but don't know how to suppress the double warning.
4851         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
4852         * support/Util/SDCCerr.c,
4853         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
4854
4855 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
4856
4857         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
4858           fixed old K&R prototypes
4859         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
4860         * device/lib/_gptrget.c,
4861         * device/lib/_gptrgetc.c,
4862         * device/lib/_gptrput.c: changed versions for new memory indicator values,
4863           also new versions for small generic pointers and banked generic pointers
4864         * src/port.h: added const_name
4865         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
4866         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
4867         * src/SDCCcse.c (findPrevIc): check all associative operators
4868         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
4869         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
4870         * src/SDCCmem.c: updated comments,
4871           set far-space to 0 for pdata, results in optimized code
4872         * src/SDCCmem.h: added macro CONST_NAME
4873         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
4874           moving the info into the highest bits, see also gptrget/gptrput
4875         * src/src.dsp: added sdcc.ico to project files
4876         * src/avr/gen.c (genCast): fixed bug 0x%d
4877         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
4878         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
4879           relation between ptr_type and DCL_TYPE,
4880           (genCast): fixed bug 0x%d
4881         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
4882           (CODE)" for const_name
4883         * src/hc08/gen.c (genCast): fixed bug 0x%d
4884         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
4885           (hc08_port): added "CONST (CODE)" for const_name
4886         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
4887           (aopForRemat, adjustArithmeticResult): disconnected direct relation
4888           between ptr_type and DCL_TYPE,
4889           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
4890           operand* and took AOP() inside function so sfr-ness can be checked,
4891           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
4892           new prototype,
4893           (genFunction, genEndFunction): optimized stack setup,
4894           (genMinus): optimized for literals with ending zeroes (in bytes),
4895           (genCast): fixed bug 0x%d
4896         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
4897           (mcs51_port): added "CONST (CODE)" for const_name
4898         * src/mcs51/peeph.def: made rule 226 more generic
4899         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
4900         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
4901         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
4902         * src/z80/main.c (z80_port): added NULL for const_name,
4903           (gbz80_port): added NULL for const_name
4904         * support/regression/tests/bug663539.c,
4905         * support/regression/tests/sfr16.c: new tests
4906
4907 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4908
4909         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
4910
4911 2005-06-24 Raphael Neider <rneider AT web.de>
4912
4913         * device/lib/pic16/libdev/pic18f[68][567]20.c:
4914           corrected typos...
4915         * device/include/pic16/signal.h: added USBIF
4916           and SIG_USB
4917
4918 2005-06-24 Raphael Neider <rneider AT web.de>
4919
4920         * device/lib/pic16/libdev/pic18f2455.c,
4921           device/include/pic16/pic18f2455.h: NEW
4922         * device/include/pic16/pic18fregs.h,
4923           device/lib/pic16/pics.all,
4924           src/pic16/device.c: added 18f2455
4925         * device/lib/pic16/libdev/pic18f[68][567]20.c,
4926           device/include/pic16/{pic18f[68][567].h,usart.h}:
4927           replaced MULTIPLE_USARTS define with more relaible
4928           compatibility sfrs (for USART access)
4929
4930 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
4931
4932         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
4933           and the output asm file line is printed on two lines.
4934
4935 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4936
4937         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
4938           BGT, BLE, BHI, and BLS instructions
4939         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
4940           genCmpEq): removed
4941         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
4942           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
4943           fixes bug #1216342
4944         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
4945
4946 2005-06-15 Raphael Neider <rneider AT web.de>
4947
4948         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
4949         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
4950         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
4951           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
4952           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
4953
4954 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4955
4956         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
4957           Marcel Telka in bug #1215704
4958
4959 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
4960
4961         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
4962           located in shared memory bank.
4963
4964 2005-05-31 Raphael Neider <rneider AT web.de>
4965
4966         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
4967           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
4968           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
4969
4970 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
4971
4972         * device/lib/_strncpy.c: fixed the fix
4973
4974 2005-05-26 Raphael Neider <rneider AT web.de>
4975
4976         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
4977           initializers with \0, bug #1208187
4978         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
4979           intializers with \0, bug #1208187
4980
4981 2005-05-26 Raphael Neider <rneider AT web.de>
4982
4983         * src/pic16/glue.c (pic16_printIvalChar): fixed string
4984           initializers with \0, bug #1208187
4985         * src/pic16/main.c (_process_pragma): added sanity checks
4986           for stack position and size, emit warnings when appropriate
4987
4988 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
4989
4990         * device/lib/_strncpy.c: fixed not filling with \0
4991
4992 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4993
4994         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
4995           createFunction),
4996         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
4997           compound_statement),
4998         * src/SDCCsymt.h,
4999         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
5000
5001 2005-05-24 Raphael Neider <rneider AT web.de>
5002
5003         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
5004
5005 2005-05-24 Raphael Neider <rneider AT web.de>
5006
5007         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
5008           TRISE definitions, closes bug #1162453
5009
5010 2005-05-22 Raphael Neider <rneider AT web.de>
5011
5012         * src/pic16/main.c (_process_pragma): check for missing
5013           arguments to pragmas code and udata
5014         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
5015           consistency fixes to match other headers (thanks to Jim Paris)
5016         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
5017
5018 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
5019
5020         * src/SDCCicode.c (isOperandEqual): fixed missing ;
5021
5022 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
5023
5024         * support/regression/tests/bug1198642.c: new test
5025         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
5026         * src/SDCCcse.c (findPrevIc): added comment, please have a look
5027         * support/scripts/resource.h,
5028         * support/scripts/resource.rc,
5029         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
5030         * support/scripts/sdcc.ico: added 32x32 icon
5031
5032 2005-05-18 Raphael Neider <rneider AT web.de>
5033
5034         * device/lib/pic16/libdev/pic18f*.c,
5035         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
5036           keywords to "__sfr" and "__at (X)"
5037         * device/include/pic16/pic18fregs.h: added pic18f4520
5038         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
5039           #1203088 (MPLAB compatibility)
5040
5041 2005-05-17 Raphael Neider <rneider AT web.de>
5042
5043         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
5044         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
5045         * device/lib/pic16/pics.all: added new devices
5046         * src/pic16/device.c: added support for pic18f4520
5047
5048 2005-05-16 Raphael Neider <rneider AT web.de>
5049         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
5050         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
5051         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
5052           convenience function for bit access
5053
5054 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
5055
5056         * device/lib/printf_large.c: fixed bug 1193299
5057         * support/regression/tests/bug1057979.c: added test %3.3s
5058
5059 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5060
5061         * device/include/mcs51/8051.h,
5062         * device/include/mcs51/8052.h: made parseable with lint
5063         * device/include/mcs51/lint.h: added include file for (sp)lint
5064         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
5065         * doc/cdbfileformat.lyx,
5066         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
5067
5068 2005-05-14 Raphael Neider <rneider AT web.de>
5069
5070         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
5071         * device/lib/pic16/libc/stdlib/itoa.c (new)
5072         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
5073         * device/lib/pic16/libio/Makefile: exclude subdir according to
5074           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
5075         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
5076         * src/pic16/gen.c (genFunction): prevent annoying warning
5077         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
5078           nameclashes on BeOS
5079         * support/cpp2/cppmain.c (cpp_output_string): new
5080         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
5081           fixes bug 1116802
5082
5083 2005-05-13 Borut Razem <borut.razem AT siol.net>
5084
5085         * src/SDCCmain.c (linkEdit): fixed bug 1195202
5086
5087 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5088
5089         * .version: changed to version 2.5.1; back to bleeding edge development
5090
5091 2005-05-11 Borut Razem <borut.razem AT siol.net>
5092
5093         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
5094           generate PDF version 1.3 documents
5095
5096 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5097
5098         * .version: changed to version 2.5.0
5099
5100 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5101
5102         * doc/sdccman.lyx: updated weblinks, index and smaller updates
5103
5104 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5105
5106         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
5107         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
5108         well as many smaller updates.
5109         * .version: changed to version 2.5.0-pre1
5110
5111 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5112
5113         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
5114
5115 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
5116
5117         * support/regression/tests/bug1185672.c: added
5118         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
5119           bug 1185672
5120         * src/mcs51/gen.c (genCall): added comments, made it look safer
5121         * src/mcs51/gen.c (genEndFunction): simplified
5122
5123 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
5124
5125         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
5126
5127 2005-04-14 Borut Razem <borut.razem AT siol.net>
5128
5129         * fixed bug 1045046 - SIGSEGV with really simple code?:
5130           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
5131           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
5132
5133 2005-04-14 Borut Razem <borut.razem AT siol.net>
5134
5135         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
5136           src/pic16/device.h: temporarily disabled experimental #inline pragma
5137           for 2.5.0 release
5138
5139 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
5140
5141         * device/include/z80/stdio.h,
5142         * device/include/z80/string.h: removed these highly incomplete files so
5143           SDCC can use the default ones in device/include/
5144
5145 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5146
5147         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
5148         gcc warning.
5149         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
5150         fix sdcpp warnings.
5151
5152 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
5153
5154         * device/include/malloc.h: removed redundant __reentrant prototypes
5155         * device/lib/_mullong.c: added working xstack variant in asm (C version
5156           doesn't pass regression tests)
5157         * device/lib/bpx.c: used __data and made bpx char for mcs51
5158         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
5159           (createFunction): fixed bug with xstackPtr
5160         * src/SDCCcse.c: corrected comments
5161         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
5162           (killDeadCode, eBBlockFromiCode): removed unused code
5163         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
5164           corrected comments
5165         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
5166           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
5167           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
5168           (genModOneByte): fixed warning in MSVC
5169         * src/mcs51/main.c (): added comments
5170         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
5171
5172 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
5173
5174         * src/SDCCmain.c (linkEdit): oops, changed one line too many
5175
5176 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
5177
5178         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
5179
5180 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
5181
5182         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
5183         characters arrays of larger size than the declared one.
5184
5185 2005-04-10 Borut Razem <borut.razem AT siol.net>
5186
5187         * src/pic/gen.c (genInline),
5188           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
5189           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
5190           (findNextInstruction), (findPrevInstruction),
5191           (findInstructionUsingLabel),
5192           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
5193         * src/pic/pcode.c (findLabel): added missing '\n'
5194         * src/src.dsp: added SDCCdwarf2.c to the project
5195
5196 2005-04-09 Borut Razem <borut.razem AT siol.net>
5197
5198         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
5199
5200 2005-04-08 Raphael Neider <rneider AT web.de>
5201
5202         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
5203           into the chain after a given one) and mergeDefmapSymbols (combine
5204           defmap entries for each symbol per pcode)
5205         * (createDefmap): have defmap entries merged in the end
5206         * (defmapReplaceSymRef): split defmap entries covering two accesses to
5207           a symbol before replacing one access type's symbol, merge symbols in
5208           the end (replacement symbol might already have an entry)
5209         * (assignValnums): keep reference to written WREG intact
5210
5211 2005-04-08 Raphael Neider <rneider AT web.de>
5212
5213         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
5214           Alpha)
5215
5216 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
5217
5218         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
5219         bytes
5220
5221 2005-04-07 Raphael Neider <rneider AT web.de>
5222
5223         * device/include/pic16/usart.h: added compatibility defines for
5224           devices with more than one USART
5225         * device/include/pic16/pic18f[68][567]20.h: activated above defines
5226
5227 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
5228
5229         * device/lib/Makefile.in: updated for port specific include
5230
5231 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
5232
5233         * support/regression/ports/mcs51/spec.mk: added mcs51 include
5234
5235 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
5236
5237         * device/include/8051.h,
5238         * device/include/8052.h,
5239         * device/include/at89S8252.h,
5240         * device/include/at89c55.h,
5241         * device/include/at89x051.h,
5242         * device/include/at89x51.h,
5243         * device/include/at89x52.h,
5244         * device/include/mcs51reg.h,
5245         * device/include/reg51.h,
5246         * device/include/reg764.h,
5247         * device/include/regc515c.h,
5248         * device/include/sab80515.h: (re)moved these 12 files
5249         * device/include/mcs51/8051.h,
5250         * device/include/mcs51/8052.h,
5251         * device/include/mcs51/at89S8252.h,
5252         * device/include/mcs51/at89c55.h,
5253         * device/include/mcs51/at89x051.h,
5254         * device/include/mcs51/at89x51.h,
5255         * device/include/mcs51/at89x52.h,
5256         * device/include/mcs51/mcs51reg.h,
5257         * device/include/mcs51/reg51.h,
5258         * device/include/mcs51/reg764.h,
5259         * device/include/mcs51/regc515c.h,
5260         * device/include/mcs51/sab80515.h: and added them here
5261
5262 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
5263
5264         * device/include/stdarg.h: changed SDCC specific keywords to double
5265           underlined form.
5266         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
5267           mcs51 and ds390.
5268         * device/include/hc08/mc68hc908gp32.h,
5269         * device/include/hc08/mc68hc908jb8.h,
5270         * device/include/hc08/mc68hc908jkjl.h,
5271         * device/include/hc08/mc68hc908qy.h: fixed comments
5272         * device/include/mcs51/README: updated
5273         * device/include/mcs51/c8051f120.h: added PINRSF
5274         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
5275         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
5276           amidst code. Also inline is not supported.
5277
5278 2005-04-06 Raphael Neider <rneider AT web.de>
5279
5280         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
5281         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
5282           callers stack/frame pointers
5283
5284 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
5285
5286         * device/include/pic16/usart.h: added, missing in previous commit,
5287         * device/include/pic16/adc.h: fixed typo,
5288         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
5289         commit,
5290         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
5291         <p18fxxx.inc>
5292         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
5293         uninitialized because a bug appears with gplink
5294         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
5295         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
5296         complains for unrecognised option
5297
5298 2005-04-05 Raphael Neider <rneider AT web.de>
5299
5300         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
5301           structs as well (using memcpy)
5302         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
5303           on ISRs (GOTO has no label)
5304         * src/pic16/device.h: added OF_OPTIMIZE_DF
5305         * src/pic16/main.c: added compiler switch --optimize-df to enable the
5306           new data flow analysis/optimization
5307         * src/pic16/pcode.c: added (prototypes for and implementation of)
5308           dataflow analysis functions, fixed pCodeInstructions' inCond and
5309           outCond values, made RCALL a branch instruction
5310         * (pic16_unlinkpCode): keep C line if possible
5311         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
5312           C line moved if possible
5313         * (pic16_getRegFrompCodeOp): NEW, improved version of...
5314         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
5315           to use new pic16_getRegFrompCodeOp (works for more SFRs)
5316         * (pic16_BuildFlow): fixed skip instructions with label (did not start
5317           new flow)
5318         * (pic16_getJumptabpCode): NEW, needed in...
5319         * (LinkFlow): fixed handling of jumptables, calls and conditional
5320           branches
5321         * (pic16_InsertCommentAfter): NEW
5322         * (pic16_pCodeReplace): made verbose and flow preserving
5323         * (AnalyzeFlow): added call to data flow analysis
5324         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
5325         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
5326         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
5327
5328 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5329
5330         * src/SDCCast.c (decorateType): fixed bug #1105626
5331
5332 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
5333
5334         * device/include/asm/pic16/features.h,
5335         * pic18f*.h headers,
5336         * device/include/pic16/adc.h,
5337         * device/include/pic16/delay.h,
5338         * device/include/pic16/i2c.h,
5339         * device/include/pic16/malloc.h,
5340         * device/include/pic16/stdio.h,
5341         * device/include/pic16/stdlib.h,
5342         * device/include/pic16/string.h,
5343         * device/lib/pic16/libc/stdio/printf_tiny.c,
5344         * device/lib/pic16/libc/stdio/printf_small.c,
5345         * device/lib/pic16/libc/stdio/strmgpsim.c,
5346         * device/lib/pic16/libc/stdio/strmmssp.c,
5347         * device/lib/pic16/libc/stdio/strmusart.c,
5348         * device/lib/pic16/libc/stdio/vfprintf.c,
5349         * device/lib/pic16/libc/stdlib/ltoa.c,
5350         * device/lib/pic16/libc/stdlib/putchar.c,
5351         * device/lib/pic16/libc/stdlib/x_ftoa.c,
5352         * device/lib/pic16/libc/stdlib/memchrpgm.c,
5353         * device/lib/pic16/libc/stdlib/memchrram.c,
5354         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
5355         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
5356         * device/lib/pic16/libio/adc/adcbusy.c,
5357         * device/lib/pic16/libio/adc/adcread.c,
5358         * device/lib/pic16/libio/adc/adcsetch.c,
5359         * device/lib/pic16/libio/usart/ubaud.c,
5360         * device/lib/pic16/libio/usart/ubusy.c,
5361         * device/lib/pic16/libio/usart/udrdy.c,
5362         * device/lib/pic16/libio/usart/uopen.c,
5363         * device/lib/pic16/libio/usart/uputc.c,
5364         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
5365         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
5366         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
5367         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
5368         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
5369         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
5370         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
5371         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
5372         specific keywords to double underlined form,
5373         * device/lib/pic16/libc/Makefile.rules,
5374         * device/lib/pic16/libsdcc/Makefile.rules,
5375         * device/lib/pic16/libm/Makefile,
5376         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
5377         to compile with C standard set in Makefile.common
5378         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
5379         rand.c and crc.c in compilation process,
5380         * device/lib/pic16/libsdcc/int/divuint.c,
5381         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
5382         `c' from signed to unsigned,
5383         * device/lib/pic16/startup/crt0.c,
5384         * device/lib/pic16/startup/crt0i.c,
5385         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
5386         keywords to double underlined form, bug fixes in _do_cinit function
5387         which prevented the correct initialization of the .idata segment,
5388         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
5389         core to enter a infinite loop
5390         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
5391
5392 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5393
5394         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
5395
5396 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5397
5398         * device/include/Makefile.in: add support for hc08 subdirectory
5399         * device/include/hc08/: new subdirectory
5400         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
5401         Lucas Loizaga, thanks!
5402         * device/include/hc08/mc68hc908qy.h,
5403         * device/include/hc08/mc68hc908gp32.h,
5404         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
5405         their own directory. Changed internal macro names to use the compiler
5406         reserved namespace. Changed SDCC specific keywords to double
5407         underlined form.
5408         * device/include/math.h,
5409         * device/include/malloc.h,
5410         * device/include/stdarg.h,
5411         * device/include/stdbool.h
5412         * device/include/string.h,
5413         * device/include/tinibios.h,
5414         * device/include/ds400rom.h,
5415         * device/include/8051.h,
5416         * device/include/8052.h,
5417         * device/include/80c51xa.h,
5418         * device/include/at89c55.h,
5419         * device/include/at89S8252.h,
5420         * device/include/at89x51.h,
5421         * device/include/at89x52.h,
5422         * device/include/ds80c390.h,
5423         * device/include/reg764.h,
5424         * device/include/regc515c.h,
5425         * device/include/sab80515.h,
5426         * device/include/mcs51/c8051f000.h,
5427         * device/include/mcs51/c8051f018.h,
5428         * device/include/mcs51/c8051f020.h,
5429         * device/include/mcs51/c8051f040.h,
5430         * device/include/mcs51/c8051f060.h,
5431         * device/include/mcs51/c8051f120.h,
5432         * device/include/mcs51/c8051f300.h,
5433         * device/include/mcs51/c8051f310.h,
5434         * device/include/mcs51/c8051f320.h,
5435         * device/include/mcs51/c8051f330.h,
5436         * device/include/mcs51/c8051f350.h,
5437         * device/include/z180.h: Changed SDCC specific keywords to double
5438         underlined form.
5439
5440 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
5441
5442         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
5443         18F4455,
5444         * (pic16_assignConfigWordValue): disable testing of configuration
5445         register value with config mask,
5446         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
5447         function with port->fun_prefix,
5448         * (genFunction): when generating a naked interrupt function never
5449         create an absolute segment placed in interrupt vector address, place
5450         the actual interrupt function at IVA instead, when an interrupt
5451         function is generated with unspecified interrupt then do not create
5452         the absolute section,
5453         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
5454         code for generating a call to generic pointer get/put function with
5455         a call to function pic16_callGenericPointer(),
5456         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
5457         the call to the generic pointer get/put functions with prefixing the
5458         function name with port->fun_prefix,
5459         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
5460         * src/pic16/main.c (_process_pragma): prefix function with
5461         port->fun_prefix,
5462         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
5463         calling assembler, old 18Fxxxx macro is deprecated,
5464         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
5465         PC_ASMDIR in while condition,
5466         * (findInstruction): add PC_ASMDIR in while condition,
5467         * (buildCallTree): prefix main with port->fun_prefix,
5468         * (pic16_pCode2str): fixed bug that didn't emit the memory access
5469         identifier for variable with banked access in instructions BTFSS,
5470         BTFSC, BCF, BSF, BTG
5471         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
5472         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
5473         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
5474         perform optimization when enviroment variable NO_REG_OPT is set,
5475         * (insideLRBlock): NEW, return 1 if register is inside an
5476         INF_LOCALREGS block,
5477         * (RemoveRegFromLRBlock): remove a register that is completely
5478         eliminated by register optimization, but it is still left in local
5479         register store/restore in/from stack block,
5480         * (Remove2pcodes): after removing register, check to see if it
5481         should be removed from local register store/restore in/from stack
5482         block,
5483         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
5484         DUMMY_READ_VOLATILE,
5485
5486         * device/include/pic16/adc.h: minor prototype modifications and
5487         update,
5488         * device/include/pic16/malloc.h: added GPL notice various
5489         modifications,
5490         * device/include/pic16/stdint.h: NEW, standard header for ints
5491         * device/include/pic16/delay.h: NEW, header for delay functions,
5492         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
5493         delay1mtcy,
5494         * device/include/pic16/signal.h: NEW, header providing helper macros
5495         for implementing signal handlers,
5496         * device/include/pic16/stdio.h: added prototypes for functions,
5497         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
5498         prototypes for stdin and stdout, added macro PUTCHAR to
5499         automatically implement putchar function prototype,
5500         * device/include/pic16/usart.h: modified and updated USART library,
5501         * device/lib/pic16/libio/adc/,
5502         * device/lib/pic16/libio/i2c: some modifications to improve library
5503         performance,
5504         * device/lib/pic16/libc/stdio/: modifications for the new printf*
5505         family of functions,
5506         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
5507         family of functions and other sources,
5508         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
5509         of the PIC18Fxx[28] devices,
5510         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
5511         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
5512         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
5513         _do_cinit function, because the previous failed when local variables
5514         where not placed in the same memory bank,
5515         * device/lib/pic16/libsdcc/char/: various modifications to improve
5516         library performance,
5517         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
5518         information on the new functions of the c library and more...
5519
5520 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5521
5522         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
5523
5524 2005-03-26 Raphael Neider <rneider AT web.de>
5525
5526         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
5527           if condition == CARRY)
5528         * (genCmp): adapted to new genSkipc semantics
5529         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
5530           on rIfx (genCmp was broken)
5531
5532 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5533
5534         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
5535         * src/z80/main.c (_keywords[]),
5536         * src/SDCCglobal.h (struct options),
5537         * src/SDCC.y,
5538         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
5539         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
5540         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
5541         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
5542         always available in leading double underscore form. The C99 support is
5543         mostly missing, but it's a start.
5544         * support/regression/tests/bug-227710.c: fixed nonconforming use of
5545         reserved identifier "__data".
5546
5547 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
5548
5549         * src/mcs51/peeph.def: fixed bug 1170013
5550
5551 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
5552
5553         * device/include/mcs51reg.h: fixed bug 842007
5554
5555 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5556
5557         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
5558         last time.
5559
5560 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5561
5562         * src/port.h (struct PORT),
5563         * src/avr/ralloc.c (avr_assignRegisters),
5564         * src/avr/main.c,
5565         * src/ds390/ralloc.c (ds390_assignRegisters),
5566         * src/ds390/main.c,
5567         * src/hc08/ralloc.c (hc08_assignRegisters),
5568         * src/hc08/main.c,
5569         * src/mcs51/ralloc.c (mcs51_assignRegisters),
5570         * src/mcs51/main.c,
5571         * src/pic/ralloc.c (pic14_assignRegisters),
5572         * src/pic/main.c,
5573         * src/pic16/ralloc.c (pic16_assignRegisters),
5574         * src/pic16/main.c,
5575         * src/xa51/ralloc.c (xa51_assignRegisters),
5576         * src/xa51/main.c,
5577         * src/z80/ralloc.c (z80_assignRegisters),
5578         * src/z80/ralloc.h,
5579         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
5580         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
5581         * src/SDCCcse.h,
5582         * src/SDCCdflow.c (computeDataFlow),
5583         * src/SDCCdflow.h,
5584         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
5585         * src/SDCCloop.h,
5586         * src/SDCCcflow.c (*),
5587         * src/SDCCcflow.h,
5588         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
5589         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
5590         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
5591         immedDom() returning wrong block; probably fixes bug #1160833)
5592
5593 2005-03-20 Borut Razem <borut.razem AT siol.net>
5594
5595         * support/scripts/inc2h.pl: WIN32 port
5596
5597 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
5598
5599         * device/lib/makefile.in: added abs.c and labs.c
5600
5601 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
5602
5603         * device/include/stdint.h: added
5604         * device/lib/abs.c: added
5605         * device/lib/labs.c: added
5606         * device/include/stdlib.h: added abs() and labs() prototypes
5607         * device/lib/libsdcc.lib: added abs and labs
5608         * device/include/float.h,
5609         * device/lib/_fsmul.c,
5610         * device/lib/printf_fast.c,
5611         * device/lib/printf_tiny.c: updated comments
5612
5613 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5614
5615         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
5616         bug #1164313
5617
5618 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5619
5620         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
5621         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
5622
5623 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
5624
5625         * device/lib/printf_large.c: removed inline assembly for portability and
5626           readability. Use printf_fast if speed or size are more important.
5627         * src/pic16/gen.c: removed conditions around use of DEBUGpc
5628         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
5629
5630 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
5631
5632         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
5633         prevent compiler warning
5634
5635 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
5636
5637         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
5638         moved to level 0 and declared as static. Also they are explicit
5639         placed in access bank. This was necessery because some times they
5640         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
5641         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
5642         optimizations. Currently only compare to unsigned char is implemented,
5643         * src/pic16/gen.c: added fReturnIdx array,
5644         * (struct resolvedIfx) is moved to gen.h and made public,
5645         * (struct _G): added sregsAlloc and sregsAllocSet fields,
5646         * (aopForSym): added an optimization to directly store in stack of
5647         the operand of a SEND iCode,
5648         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
5649         but as registers instead (AOP_REG) using the fReturnIdx array,
5650         * (pic16_freeAsmop): remove the freed register from the
5651         _G.sregsAlloc field,
5652         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
5653         a compare of 'WREG',
5654         * (pic16_popGetTempRegCond): changed function prototype, now
5655         function takes also a bitVector argument v which holds the current
5656         set of registers that are allocated for stack access by aopForSym,
5657         registers allocated in aopForSym for accessing stack symbols are not
5658         any more part of the functions usedRegs field,
5659         * (genCall): some times aopOp is called for a stack variable to be
5660         send, aopForSym might perform the push, if this is true make sure
5661         that genCall doesn't push the variable twice by testing _G.resDirect,
5662         * (genFunction): changed testing for unspecified interrupt number
5663         from 256 to INTNO_UNSPEC,
5664         * modified selection scheme of frame pointer generation. Previously
5665         if function did use local registers a frame pointer was generated,
5666         now a frame pointer is generated only if function has arguments
5667         (that need PLUSW2 register access), or has stack arguments, or the
5668         compiler is not instructed to omit the frame pointer,
5669         * (genEndFunction): before restoring local registers that were saved
5670         in the function preamble, also restore the registers that *might*
5671         have been allocated for stack access,
5672         * (genRet): removed some old comments,
5673         * (genCmp, the active (RN's) version): added a call to the
5674         pic16_genCmp_special function to perform the compare with a more
5675         robust and optimized way,
5676         * (genInline): a feature has been added in inline code generation,
5677         which allows a wildcard variable substitution when writing inline
5678         assembly. Code is incomplete and experimental therefore undocumented,
5679         * (genCast): changed order of aopOp for result and right to allow
5680         aopForSym to directly load the result if possible,
5681         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
5682         perform an optimized compare on some selected special occasions,
5683         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
5684         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
5685         generate an IVT any more,
5686         * src/pic16/main.c (pic16_optionsTable): added command line option
5687         --optimize-cmp,
5688         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
5689         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
5690         macros,
5691         * src/pic16/NOTES: Raphael Neider added in list of active developers
5692         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
5693         jumptable_end to prevent bug #,
5694         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
5695         inCond and outCond fields,
5696         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
5697         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
5698         turn off register spilling,
5699         * (packRegsForOneUse): synced with other ports' versions although it
5700         is not used currently,
5701         * (pic16_packRegisters): added an optimization while reading
5702         structure bitfields, some registers may be saved (malloc code is
5703         decreased by 80 bytes)
5704
5705 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
5706
5707         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
5708         left is a bitfield, if yes, then don't optimize assignment. Perhaps
5709         this can be optimized more?
5710
5711 2005-03-10 Raphael Neider <rneider AT web.de>
5712
5713         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
5714           genNearPointerGet): (hopefully) fixed access to bitfields via
5715           pointers (p->bitN = x; and x = p->bitN; failed)
5716
5717 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
5718
5719         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
5720
5721 2005-03-09 Raphael Neider <rneider AT web.de>
5722
5723         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
5724
5725 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
5726
5727         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
5728         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
5729           (regTypeNum): set REG_BIT type if necessary
5730         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
5731         * support/regression/tests/critical.c: check bug 1144613
5732
5733 2005-03-02 Raphael Neider <rneider AT web.de>
5734
5735         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
5736
5737 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5738
5739         * src/avr/ralloc.c (serialRegAssign),
5740         * src/ds390/ralloc.c (serialRegAssign),
5741         * src/hc08/ralloc.c (serialRegAssign),
5742         * src/mcs51/ralloc.c (serialRegAssign),
5743         * src/pic/ralloc.c (serialRegAssign),
5744         * src/pic16/ralloc.c (serialRegAssign),
5745         * src/xa51/ralloc.c (serialRegAssign),
5746         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
5747
5748 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
5749
5750         * src/SDCCast.c (decorateType): fixed bug 1124787
5751
5752 2005-02-20 Hubert Sack <sack AT digiplan.de>
5753         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5754
5755         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
5756         patch #1121755
5757
5758 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5759
5760         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
5761         to keep the correct label reference count when adding/removing references
5762         to labels. A peephole file using this is appended to patch #1144962.
5763
5764 2005-02-14 Raphael Neider <rneider AT web.de>
5765
5766         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
5767         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
5768         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
5769           retrievals of result operand's value on assignment
5770
5771 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
5772
5773         * device/include/pic16/string.h: modified prototype for memccpy()
5774         to memccpy(void *, void *, char, size_t)
5775         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
5776         check whether to omit frame pointer or not,
5777         * (genInline): convert all occurences of "\n" to LF in inline
5778         assembler blocks, this helps formatting the inline text,
5779         * (pic16_loadFSR0): modified prototype,
5780         * (genNearPointerGet, genNearPointerSet): reorganization of code,
5781         removed some 8051 legacy code,
5782         * (genPackBits): enabled handling bitfields exceeding one byte in size,
5783         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
5784         before allocating temporary registers in functions,
5785
5786 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
5787
5788         * support/regression/tests/bitvars.c: corrected the "fix"
5789
5790 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
5791
5792         * support/regression/tests/bitvars.c,
5793         * support/regression/tests/bitwise.c,
5794         * support/regression/tests/rotate.c: "fixed" problems on Alpha
5795
5796 2005-02-10 Raphael Neider <rneider AT web.de>
5797
5798         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
5799           different size for Alpha
5800         * src/pic16/gen.c (genCmpEq) : improved compare with 0
5801
5802 2005-02-09 Raphael Neider <rneider AT web.de>
5803
5804         * src/SDCC.lex(doPragma) : save and restore warning options as well
5805           (also added new stack plus clone- and copyAndFreeSDCCERRG())
5806         * have #pragma less_pedantic set the errorlevel to WARNING
5807           (fixes #1117001)
5808         * (cloneOptimize) : fixed wrong malloc's size
5809         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
5810           facilitate correct handling of #pragma (save|restore)
5811
5812 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
5813
5814         * src/mcs51/gen.c: removed non-standard C nameless struct/union
5815
5816 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
5817
5818         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
5819
5820 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
5821
5822         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
5823
5824 2005-02-02 Raphael Neider <rneider AT web.de>
5825
5826         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
5827         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
5828         * (pic16_storeForReturn): fixed to allow returning function pointers
5829         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
5830         * device/include/pic16/{stddef.h,stdbool.h}: added
5831
5832 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
5833
5834         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
5835
5836 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
5837
5838         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
5839         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
5840          appeared to be required
5841
5842 2005-01-31 Borut Razem <borut.razem AT siol.net>
5843
5844         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
5845           include/mcs51 and include/z80 directories to the package
5846
5847 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5848
5849         * src/hc08/gen.c (genFunction): fixed bug #1112752
5850
5851 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5852
5853         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
5854
5855 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5856
5857         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
5858
5859 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
5860
5861         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
5862
5863 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
5864
5865         * device/include/c8051fxxx.h: removed these 6 files
5866         * device/include/mcs51/c8051fxxx.h: added these 11 new files
5867
5868 2005-01-26 Raphael Neider <rneider AT web.de>
5869
5870         * src/pic16/gen.c (genAssign): fixed assignment from longs
5871           in codespace (were cut to three bytes)
5872         * (genDummyRead): implemented (except for CODESPACE...),
5873           fixed bug #1108575
5874         * src/pic16/glue.c (emitStatistics): beautified
5875         * device/lib/pic16/libm/Makefile: added include path
5876
5877 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5878
5879         * src/z80/gen.c (aopPut): fixed bug #1103902
5880
5881 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5882
5883         * device/lib/expf.c: fixed bug #1095792
5884
5885 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
5886
5887         * device/lib/pic16/libm: added Math library sources
5888
5889 2005-01-24 Raphael Neider <rneider AT web.de>
5890
5891         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
5892           to enable upcast to pCodeOpReg2 (there is no type tag to
5893           differenciate the two and pic16_popGet2p cast into PCOR2)
5894         * src/pic16/main.c (_process_pragma): fixed another malloc bug
5895           (sizeof(sectNames) changed to sizeof(sectName))
5896           Both patches fix segfaults under MinGW.
5897
5898 2005-01-23 Raphael Neider <rneider AT web.de>
5899
5900         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
5901           Safe_[mc]?alloc()'ed variables
5902         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
5903           of (byte sized) temporaries (assign them to WREG for now)
5904         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
5905           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
5906           this might fix SIGSEGVs on MinGW...
5907         * src/SDCCopt.c (killDeadCode): restored original behaviour
5908           (volatile operands might get thrown away though)
5909
5910 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
5911
5912         * src/pic16/gen.c: fixed bug #1106975,
5913         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
5914         pointer update, INTCON is saved, global interrupts are disabled and
5915         restored after updateing TOS.
5916         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
5917         * added function attribute 'shadowregs' to take advantage of shadow
5918         registers,
5919         * added function attribute 'wparam' as an alternative to the wparam
5920         pragma,
5921         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
5922         user declares a non-ISR function as 'shadowregs',
5923         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
5924
5925 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
5926
5927         * .version: bumped version number to 2.4.8
5928         * device/lib/pic16/pics.all: list of PIC18F devices supported by
5929         pic16 port,
5930         * device/lib/pic16/libio/i2c/: I2C module support library,
5931         * device/include/pic16/i2c.h: I2C support library header,
5932         * device/lib/pic16/libc/stdio/: standard IO support sources,
5933         * (printf_small.c): printf_small() source, supports float print,
5934         * (printf_tiny.c): printf_tiny() source, does not support floats,
5935         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
5936         enable global optimizations for entire library source, other
5937         Makefiles in the source tree are also modified to reflect this,
5938         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
5939         function,
5940         * doc/sdccman.lyx: updated to reflect new changes,
5941         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
5942         sym->onStack if-case,
5943         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
5944         sbit, idata, _idata, xdata, _xdata,
5945         * added pragma library, to link an external library, (see doc),
5946         * removed command line options, --pomit-config-words, --pomit-ivt,
5947         --pleave-reset-vector,
5948         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
5949         when calling assembler to reflect memory model used, also define
5950         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
5951         reflect stack model used,
5952         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
5953         on stack return NULL,
5954
5955 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
5956
5957         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
5958           of the operands is volatile. Fixes #1020220
5959
5960 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
5961
5962         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
5963         * (OptimizeRegUsage): make sure that there is really no other flow where
5964           the first pCode is used
5965
5966 2005-01-22 Raphael Neider <rneider AT web.de>
5967
5968         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
5969           to fix #1106967 (pCode->seq are not set up correctly)
5970
5971 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5972
5973         * src/SDCCglue.c (glue): make sure code area is declared before the
5974         static initialization area.
5975
5976 2005-01-21 Raphael Neider <rneider AT web.de>
5977
5978         * device/lib/Makefile.in: fixed test for pic16 install dir
5979         * device/lib/pic16/*/Makefile*: modified compile flags to enable
5980           optimizations
5981         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
5982           added --optimize-goto compiler switch and pragma wparam documentation
5983         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
5984         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
5985           and PRODH closing bug #1071770 (peephole optimizer)
5986
5987 2005-01-19 Raphael Neider <rneider AT web.de>
5988
5989         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
5990           cmdLine buffers (used when calling sdcpp...) are large enough
5991           (MAX_PATH=256 truncates arguments leading to system halts when
5992           used in MinGW...)
5993         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
5994         * (genUminus): rewritten to for efficiency
5995         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
5996           used uninitialized in some cases)
5997         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
5998           copy the third byte from the int -- now assumes 0x80 (data memory)
5999         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
6000           operands (genAddLit expects the iCode's operands to swapped as
6001           well), fixed leftover bytes (crashed for short left operands)
6002         * (pic16_genMinusDec): performance improvements, removed false
6003           PIC14 emitSKPNCs
6004         * (pic16_genMinus): fixed to cope with differently sized operands
6005         * src/pic16/glue.c (pic16_glue): added new banksel optimization
6006           for --obanksel > 1
6007         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
6008         * src/pic16/graph.[ch]: implementation of directed graphs, used by
6009           new banksel optimization
6010         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
6011           analysis for temporary registers (segfaults...)
6012         * src/pic16/peeph.def: added rule
6013
6014 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
6015
6016         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
6017         which converts a float number to its ASCII representation
6018         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
6019         functions to convert the fractional and integer part of a float to ASCII,
6020         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
6021         realloc.c): added _MALLOC_SPEC to explicit place variables in data
6022         ram
6023         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
6024         _STATMEM macros,
6025         * device/include/pic16/adc.h: added GPL info,
6026         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
6027         a pCodeOp as tested operand,
6028         * (genNearPointerGet): optimized bit testing, does not use
6029         intermediate register for bit value, test directly instead with
6030         BTFSS, BTFSC, works only for single bits,
6031         * (genpic16Code): dump the name of the iCode in the asm,
6032         * src/pic16/ralloc.c (decodeOp): removed static declaration and
6033         renamed to pic16_decodeOp,
6034         * (serialRegAssign): do not allocate a temporary register for iCode
6035         sequences that test a single bit for 1/0
6036
6037 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
6038
6039         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
6040         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
6041         access stack and frame pointers. They are initially assigned to
6042         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
6043         accessing SFRs. Updated all occurences of modification of stack or
6044         frame pointer in gen.c and pcode.c,
6045         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
6046         assigning of a literal value to pointers,
6047         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
6048         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
6049         selected
6050
6051 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
6052
6053         * doc/sdccman.lyx: update documentation about stack pragma, added
6054         some info for stack memory models
6055
6056 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6057
6058         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
6059
6060 2005-01-08 Raphael Neider <rneider AT web.de>
6061
6062         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
6063           udata sections to fix bug #1097823
6064
6065 2005-01-05 Raphael Neider <rneider AT web.de>
6066
6067         * src/pic16/gen.c (genGenericShift): added handling of differently
6068           sized left operand and result
6069
6070 2005-01-04 Raphael Neider <rneider AT web.de>
6071
6072         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
6073         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
6074           to hold the condition bit)
6075         * added new version of genCmp (old code available via #define)
6076         * added new version of genShiftLeft/genShiftRight in a generic
6077           way, now supports shifting by negative values
6078         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
6079           shiftCount (expected by genGenericShift)
6080         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
6081         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
6082           dump
6083         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
6084           is an invalid literal too...)
6085
6086 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
6087
6088         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
6089         from Raphael Neider,
6090         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
6091         for 8-bit literals. This fixes some literal operands which are sign
6092         extended to 16-bits ints when instruction needs only 8-bits.
6093
6094 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
6095
6096         * device/lib/logf.c: added mcs51 assembly version
6097         * device/lib/expf.c: added mcs51 assembly version
6098         * device/lib/_logexpf.c: new shared asm code for expf and logf
6099         * device/include/math.h: add defines for assembly math library
6100         * device/lib/Makefile.in: build new _logexpf.c
6101         * device/lib/libfloat.lib: use new _logexpf.c
6102
6103 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
6104
6105         * src/pic/device.c
6106         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
6107           device types which have less than 0x7f registers.
6108
6109 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
6110
6111         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
6112
6113 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
6114
6115         * device/lib/printf_fast.c: only build on supported arch.
6116         * device/lib/printf_tiny.c: only build on supported arch.
6117         * device/lib/printf_fast_f.c: only build if asm float lib
6118         * device/lib/_fsget1arg.c: only build if asm float lib
6119         * device/lib/_fsget2args.c: only build if asm float lib
6120         * device/lib/_fsnormalize.c: only build if asm float lib
6121         * device/lib/_fsreturnval.c: only build if asm float lib
6122         * device/lib/_fsrshift.c: only build if asm float lib
6123         * device/lib/_fsswapargs.c: only build if asm float lib
6124         * device/include/stdio.h: don't provide print_fast,
6125           print_fast_f, print_tiny prototypes if --xstack used
6126
6127 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
6128
6129         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
6130         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
6131           to the SOURCES
6132
6133 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
6134
6135         * device/lib/printf_fast_f.c: same as printf_fast, but
6136           with floating point enabled
6137         * device/lib/printf_fast.c: minor tweaks
6138         * device/include/stdio.h: add printf_fast_f
6139
6140 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
6141
6142         * src/SDCCmain.c: make --float-reent default for mcs51
6143         * device/lib/_fsadd.c: added mcs51 assembly version
6144         * device/lib/_fssub.c: added mcs51 assembly version
6145         * device/lib/_fsmul.c: added mcs51 assembly version
6146         * device/lib/_fsdiv.c: added mcs51 assembly version
6147         * device/lib/_fseq.c: added mcs51 assembly version
6148         * device/lib/_fsneq.c: added mcs51 assembly version
6149         * device/lib/_fsgt.c: added mcs51 assembly version
6150         * device/lib/_fslt.c: added mcs51 assembly version
6151         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
6152         * device/lib/Makefile.in: add _fscmp to build
6153         * device/lib/libfloat.lib: add _fscmp to build
6154
6155 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
6156
6157         * device/lib/_fs2slong.c: added mcs51 assembly version
6158         * device/lib/_fs2sint.c: added mcs51 assembly version
6159         * device/lib/_fs2schar.c: added mcs51 assembly version
6160         * device/lib/_fs2ulong.c: added mcs51 assembly version
6161         * device/lib/_fs2uint.c: added mcs51 assembly version
6162         * device/lib/_fs2uchar.c: added mcs51 assembly version
6163         * device/lib/_slong2fs.c: added mcs51 assembly version
6164         * device/lib/_sint2fs.c: added mcs51 assembly version
6165         * device/lib/_schar2fs.c: added mcs51 assembly version
6166         * device/lib/_ulong2fs.c: added mcs51 assembly version
6167         * device/lib/_uint2fs.c: added mcs51 assembly version
6168         * device/lib/_uchar2fs.c: added mcs51 assembly version
6169         * device/include/float.h: added #define to select asm vs c
6170
6171 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
6172
6173         * device/lib/printf_fast.c: improvements to float output
6174         * device/include/float.h: add defines for assembly float library
6175         * device/lib/_fsget1arg.c: receive 1 float arg
6176         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
6177         * device/lib/_fsnormalize.c: normalize a float
6178         * device/lib/_fsreturnval.c: return float, various helper routines
6179         * device/lib/_fsrshift.c: right shift a float's mantissa
6180         * device/lib/_fsswapargs.c: swap 2 floats
6181         * device/lib/Makefile.in: build these 6 new files for mcs51
6182         * device/lib/libfloat.lib: add these 6 files to the library
6183
6184 2004-12-26 Borut Razem <borut.razem AT siol.net>
6185
6186         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
6187           built by gcc 3.4.2
6188
6189 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
6190
6191         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
6192           and fully reentrant and register bank neutral.
6193         * device/lib/printf_fast.c: added float (not enabled by default),
6194           added compact/slower integer (also not enabled by default),
6195           improved size/speed of fast integer code, other minor changes
6196         * device/include/stdio.h, device/lib/Makefile.in,
6197           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
6198
6199 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
6200
6201         * src/pic16/pcode.c: declaring variables other than at the start of a
6202           block is not supported in C by VC6.
6203
6204 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
6205
6206         * applied a previous patch from Raphael Neider that wasn't included
6207         in the previous commits, which fixes infinite loops within jumptable
6208         improvements,
6209         * made some fixes that previous patches introduced
6210
6211 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
6212
6213         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
6214         that fixes an issue with AOP_PCODE asmop's offset,
6215         * (pic16_popCopyReg): update instance field too,
6216         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
6217         function of pic port,
6218         * (genCmp, genAnd, genAssign),
6219         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
6220
6221 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
6222
6223         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
6224         variables initial values to idata section,
6225         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
6226         variables in some functions. This utilizes parmBytes field of iCode
6227         structure to hold the offset of the variable in stack. (might be
6228         able to use the stack field too?)
6229         * applied patch from Raphael Neider # ### , # ###
6230         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
6231         variable initial values in idata section,
6232         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
6233         for static variables with initial value
6234         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
6235         applied fix in while loop from Raphael Neider.
6236
6237 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
6238
6239         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
6240         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
6241         * src/ds390/ralloc.c (serialRegAssign): spill bits
6242         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
6243         * support/Util/SDCCerr.c,
6244         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
6245         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
6246         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
6247
6248 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
6249
6250         * device/include/sdcc-lib.h: inserted LGPL, added includes
6251           asm/ds390/features.h and asm/mcs51/features.h
6252         * device/include/asm/default/features.h,
6253         * device/include/asm/gbz80/features.h,
6254         * device/include/asm/z80/features.h: added empty _AUTOMEM
6255           and _STATMEM
6256         * device/include/asm/ds390/features.h,
6257         * device/include/asm/mcs51/features.h: added files with defines for
6258           _AUTOMEM and _STATMEM indicating automatic and static storage class
6259         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
6260         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
6261         * src/SDCCicode.c (geniCodeCast),
6262         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
6263         * src/SDCCloop.c (loopInduction): removed unused variable lr
6264         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
6265           to convertToFcall to include char modulo (RFE 1065037), added check
6266           if left operand is unsigned and use abs of literal value
6267         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
6268           as it doesn't work after conversion from peephole.def to peephole.rul
6269         * src/mcs51/gen.c (toBoolean): added check for size,
6270           (genModOneByte): optimized code for signed char modulo a literal
6271           power of 2 (thanks to Hubert Sack),
6272           (genRRC): removed unnecessary "clr c",
6273           (genRLC): replaced "add a,acc" with cheaper "rlc a"
6274         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
6275           jump optimization,
6276           swapped rules 256.c and 256.d,
6277           extended 256.d by using new multiple checks (thanks Erik),
6278           added rules 256.e and 256.f,
6279           updated rule 261.a and 261.b to new generated code
6280         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
6281
6282 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6283
6284         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
6285           induction related bugs, including first part of bug #1074377
6286
6287 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
6288
6289         * applied patch from bug-report #1076292,
6290         * applied patches for genAnd and Goto-optimizations for Raphael
6291         Neider,
6292         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
6293         dump a less iCode information,
6294         * src/pic16/device.h (pic16_options_t): added field debgen,
6295         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
6296         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
6297         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
6298         puclic,
6299         * (various functions): added macros FENTRY and FENTRY2 to functions,
6300         to emit function prologue,
6301         * (various functions): fixed indentation,
6302         * (genNearPointerGet): fixed loading of FSR0,
6303         * (genPackBits): applied patch from Raphael Neider to fix updating
6304         of FSR0 and touching only the modified bits,
6305         * src/pic16/genarith.c (various functions): added macros FENTRY to
6306         emit function prologue in comments,
6307         * src/pic16/pcode.h: added functions debugf2, debugf3,
6308         * src/pic16/ralloc.c: partial fix for packForPush caused
6309         segmentation fault,
6310
6311 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6312
6313         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
6314           <stsp AT users.sourceforge.net> with reversed byte order
6315         * support/regression/tests/rotate.c: added (ds390 skips some tests)
6316
6317 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6318
6319         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
6320           bug #1074377
6321         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
6322         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
6323
6324 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
6325
6326         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
6327
6328 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6329
6330         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
6331           conditions,
6332           (setFromConditionArgs): friendly operand parser for peephole rules,
6333           (operandBaseName, operandsNotRelated): new peephole condition
6334           "operandsNotRelated" -- similar to "operandsNotSame", but takes
6335           architecture specific register naming into account, handles n-way
6336           comparisons, and supports quoted literals
6337         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
6338
6339 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6340
6341         * src/mcs51/peeph.def: fixed bug #1076940
6342
6343 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
6344
6345         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
6346
6347 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6348
6349         Adding support for replacing ljmps with sjmps in jumptables
6350         generated for switch statements. For now you need to set the
6351         environment variable SDCC_SJMP_JUMPTABLE to enable this.
6352         Now 4 algorithms for mcs51 jumptable generation are used:
6353         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
6354         addresses loaded pc-relative for up to 112 cases and stack-pushing
6355         target addresses loaded with offset from dptr for up to 256 cases.
6356
6357         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
6358         * src/mcs51/main.c: adapted constants for switch table generation
6359         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
6360
6361 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
6362
6363         * device/lib/printf_large.c (_print_format): fixed bug 1073386
6364         * support/regression/tests/bug1057979.c: added test for bug 1073386
6365
6366 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
6367
6368         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
6369         compilers
6370
6371 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
6372
6373         * src/pic16/device.h,
6374         * src/pic16/genarith.c,
6375         * src/pic16/glue.c,
6376         * src/pic16/main.c,
6377         * src/pic16/pcode.c: applied patches #1068154 and #1070213
6378
6379 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
6380
6381         Large cummulative patch for pic16 port.
6382         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
6383         to call when a stack overflow occurs,
6384         * (malloc.h): added CVS Id tag,
6385         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
6386         variable,
6387         * added libc directory. The current version of LibC contains string
6388         functions, ctype functions and macros and some functions of the
6389         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
6390         be extensively tested in the future. Standard disclaimer here.
6391         Library is not automatically build yet. But one can build it by
6392         invoking 'make' inside the libc directory.
6393         * added ADC library under libio. Preliminary version yet.
6394
6395         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
6396         * src/pic16/gen.c (aopForRemat): asmop size is filled by
6397         aopForRemat() now and not by pic16_aopOp(),
6398         * (pic16_popGetTempReg): removed warning messgae when allocating
6399         temporary registers, its a buggy feature and will be removed,
6400         * (pic16_popGet): set register instance field in AOP_CRY,
6401         * (pic16_outBitC): fixed for results in size greater than 1,
6402         * (genUminusFloat): fixed for pic16, ported code from mcs51,
6403         * (pic16_storeForReturn): optimized return of 0,
6404         * (genCmp): experimental code for new genCmp which uses PIC18's
6405         special compare&skip instructions. Initial tests fail some times
6406         with variables grater than 1 byte in size, so new code is disabled,
6407         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
6408         a single bit,
6409         * (genCast): began a fix to optimize the casting of a bit to another
6410         bit, now assigning a bitfield to another bitfield will fail, sorry,
6411         * src/pic16/main.c: disabled the use of lr-support feature,
6412         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
6413         * added some function prototypes, added function _debugf prototype,
6414         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
6415         bits with offset (case PO_GPR_BIT),
6416         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
6417         command line,
6418         * (isBankInstruction): modified to return 0 for no banking instruction,
6419         and 1 for banking instruction,
6420         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
6421         caused stop processing pCodes after a inline assembly block,
6422         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
6423         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
6424         registers when it shouldn't,
6425         * src/pic16/ralloc.c (allocReg): add preliminary support for
6426         supporting a limited set of temporary registers,
6427
6428 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6429
6430         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
6431           genDataPointerSet): ensure assignments always copy in MSB to LSB
6432           order,
6433           (loadRegFromAop): recognize CLRH optimization,
6434           (genFunction): optimize RECEIVE iCodes in reentrant functions
6435
6436 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6437
6438         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
6439           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
6440           selected.
6441         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
6442         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
6443           contiguous with data
6444
6445 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6446
6447         * device/lib/_gptrget.c (_gptrget),
6448         * device/lib/_gptrgetc.c (_gptrgetc),
6449         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
6450           instead of sjmp to ret
6451         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
6452           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
6453
6454 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
6455
6456         * .version: bumped version to 2.4.7
6457         * device/lib/_gptrget.c (_gptrget): is now _naked
6458         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
6459         * device/lib/_gptrput.c (_gptrput): is now _naked
6460         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
6461           (createFunction): fixed xstack
6462         * src/SDCCglue.c (emitMaps): set allocation required for bit area
6463         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
6464           or bit either,
6465           (geniCodeCritical): store original interrupt state in an iTemp bit
6466           var unless stack-auto
6467         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
6468         * src/SDCCmain.c (setIncludePath): added include/target to search path
6469         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
6470         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
6471           prototype,
6472           (processFuncArgs): put bit vars in bit area
6473         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
6474           unsaveRBank): fixed xstack,
6475           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
6476           (genFunction, genEndFunction): fixed xstack,
6477           (genAssign): optimization don't walk backwards through mem
6478         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
6479         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
6480         * support/regression/Makefile: also make library (for stack-auto) when
6481           making "all" and added "test-mcs51-xstack-auto"
6482         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
6483         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
6484         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
6485         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
6486         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
6487           make-library by MAKE_LIBRARY
6488         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
6489           regression tests for xstack
6490         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
6491         * support/regression/tests/critical.c: test for critical on mcs51
6492
6493 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6494
6495         * support/regression/ports/ucz80/spec.mk: use include and lib files from
6496           built version of sdcc instead of installed version
6497
6498 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
6499
6500         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
6501         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
6502           vprintf.c now
6503         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
6504         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
6505           WARNING: remove device/lib/build/z80/printf.o by hand when
6506           updating from previous build!
6507         * device/lib/z80/printf.c: updated comment
6508         * support/regression/tests/bug1057979.c: test all ports now
6509         * support/regression/tests/bug1065458.c: file added
6510
6511 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6512
6513         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
6514           *_start and *_end symbols for static functions
6515
6516 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
6517
6518         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
6519           and search crt0.o in all library paths,
6520           (setIncludePath): proper handling of --nostdinc,
6521           (setLibPath): proper handling of --nostdlib
6522         * support/regression/Makefile,
6523         * support/regression/ports/ds390/spec.mk,
6524         * support/regression/ports/gbz80/spec.mk,
6525         * support/regression/ports/hc08/spec.mk,
6526         * support/regression/ports/mcs51/spec.mk,
6527         * support/regression/ports/mcs51-large/spec.mk,
6528         * support/regression/ports/mcs51-stack-auto/spec.mk,
6529         * support/regression/ports/z80/spec.mk: use include and lib files from
6530           built version of sdcc instead of installed version
6531         * doc/sdccman.lyx: fixed typo in --nostdinc
6532
6533 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
6534
6535         * src/pic/pcode.c,
6536         * src/pic/device.c,
6537         * src/pic/ralloc.c,
6538         * src/pic/gen.c : added support to generate code for struct bit fields.
6539
6540 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
6541
6542         * as/xa51/xa_version.h,
6543         * device/include/errno.h,
6544         * device/include/regc515c.h,
6545         * device/lib/_itoa.c,
6546         * device/lib/_ltoa.c,
6547         * device/lib/ser_ir_cts_rts.c,
6548         * sim/ucsim/xa.src/glob.cc,
6549         * sim/ucsim/xa.src/inst_gen.cc,
6550         * sim/ucsim/xa.src/xa_bit.cc,
6551         * sim/ucsim/xa.src/xa_sfr.cc,
6552         * sim/ucsim/z80.src/inst_dd.cc,
6553         * sim/ucsim/z80.src/inst_fdcb.cc,
6554         * support/scripts/keil2sdcc.pl,
6555         * src/pic16/pic16.dsp,
6556         * src/pic16/pic16a.dsp: corrected cvs line endings
6557         * device/lib/printf_large.c: fixed bug 1057979
6558         * src/pic16/gen.c: fixed non-C standard code
6559         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
6560         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
6561         * support/regression/ports/mcs51/support.c: reload T1 asap
6562         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
6563           pdata use and clear idata startup behaviour
6564         * support/regression/tests/bug1057979.c: added
6565
6566 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
6567
6568         * device/examples/ds390/ow390/ad26.h,
6569         * device/examples/ds390/ow390/cnt1d.h,
6570         * device/examples/ds390/ow390/crcutil.c,
6571         * device/examples/ds390/ow390/ownet.h,
6572         * device/examples/ds390/ow390/owsesu.c,
6573         * device/examples/ds390/ow390/swt12.h,
6574         * device/examples/ds390/ow390/swtoper.c,
6575         * device/examples/ds390/ow390/temp10.h,
6576         * device/examples/ds390/ow390/thermodl.c,
6577         * device/examples/ds390/tinitalk/tinitalk.dsp,
6578         * device/examples/ds390/tinitalk/tinitalk.dsw,
6579         * device/examples/mcs51/clock/hw.h,
6580         * device/examples/mcs51/simple2/go.bat,
6581         * device/examples/serialcomm/windows/serial.h,
6582         * device/examples/xa51/dummy.c,
6583         * device/examples/xa51/hello.c,
6584         * device/include/80c51xa.h,
6585         * device/include/at89x051.h: corrected cvs line endings
6586
6587 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
6588
6589         * src/pic16/main.c (options): added command line --gstack, to trace
6590         stack over/under flows,
6591         * added pragma 'wparam' to allow passing first byte of function
6592         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
6593         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
6594         call to __gstack_test function and sets up the symbol as extern,
6595         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
6596         * popaop): added call to pic16_testStackOverflow,
6597         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
6598         wparamList list,
6599         * (genCall, genPcall): now all parameters are passed via stack
6600         except in functions that are pass to wparam pragma in which WREG is
6601         used too,
6602         * (genPcall): REENTRANT flag is checked to see if variable prototype
6603         contains reentrant keyword, don't call a non-reentrant function, via
6604         a reentrant function pointer or vice versa, functions are never
6605         passed via WREG,
6606         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
6607         D.Winkler,
6608         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
6609         SIGSEGV when accessing a NULL register stucture,
6610         * (pic16_printGPointerType): modified to handle UPPER modifier for
6611         function initializers, changed prototype of function to simpler one,
6612         * (pic16_printIvalFuncPtr): check to see if function is already
6613         added in externs list,
6614         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
6615         optimized a move from W to SFR with a move to the same register
6616         later after a CALL,
6617         * device/lib/pic16/debug: NEW directory, contains debug features
6618         which are enabled when linking with libdebug.lib, currently command
6619         line option --gstack enables stack pointer tracing for over/under
6620         flow, corresponding sources are in debug/gstack
6621
6622 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
6623
6624         * doc/sdccman.lyx: updated SDCC version,
6625         * (PIC16 port): update list of command line options,
6626         * src/pic16/device.h (structure pic16_options_t): added field gstack
6627         to enable stack overflow tracing on push/pops,
6628         * src/pic16/device.c (statistics structure): added statistics
6629         structure,
6630         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
6631         pic16_dump_int_registers): increase statistics counters for each
6632         * variable which is encountered
6633         * (pic16_dump_usection): emit each .udata variable to its own udata
6634         section,
6635         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
6636         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
6637         parameters via stack, otherwise use old scheme,
6638         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
6639         assembler output file,
6640         * src/pic16/main.c: added command line options --gstack to enable
6641         push/pop tracing for stack overflow,
6642         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
6643         instructions): added size of each instruction,
6644         * (pic16_countInstruction): estimate size of instructions in
6645         the_pFile list, inline assembly blocks are not counted,
6646         * (pic16_FixRegisterBanking): trace previous register usage, when
6647         banksel optimizations is greater than 0, don't emit a redudant
6648         banksel directive,
6649
6650 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
6651
6652         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
6653         * src/pic16/ralloc.c : applied same fix for pic16.
6654         * src/pic/gen.c : tidied it up a little.
6655
6656 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6657
6658         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
6659         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
6660
6661 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6662
6663         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
6664
6665 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6666
6667         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
6668         non-reentrant function __modsint in the interrupt function (thus
6669         corrupting math operations during serial I/O)
6670         * device/lib/ser_ir.c: as above, changed buffersize
6671         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
6672         256.c,d for zeroing
6673         * doc/Makefile: added option -t for rsync
6674
6675 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6676
6677         * src/SDCCast.h (struct ast),
6678         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
6679
6680 2004-10-20 Borut Razem <borut.razem AT siol.net>
6681
6682         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
6683         package
6684
6685 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
6686
6687         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
6688         makefile targets,
6689         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
6690         support functions to replace long sequences of MOVFF's from access
6691         bank registers to stack and vice versa,
6692         * src/pic16/device.h: added new field opt_flags, where optimization
6693         flags can be set to enable certain features,
6694         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
6695         * pBlock, (genFunction, genEndFunction): surroung loop for
6696         saving/loading used registers in stack with PC_INFO pCodes,
6697         INF_LREGS. Code in between can then be optimized by pCode optimizer
6698         to support function calls,
6699         * (genDataPointerSet): fixed bug which loaded float fields in
6700         structures with corrupt data,
6701         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
6702         in a standard way debug info on stderr. Feature used for developing
6703         and debugging only,
6704         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
6705         obsolete chunks of code,
6706         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
6707         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
6708         * pic16/src/pcode.c (pic16_newpCodeInfo,
6709         * (pic16_newpCodeOpLocalRegs),
6710         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
6711         feature,
6712         * (pic16_pCodeConstString): printing of the initial value of a
6713         symbol as a comment is inhibited since parsing was already done by
6714         copyStr and output is corrupt,
6715         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
6716
6717 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6718
6719         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
6720
6721 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
6722
6723         * as/mcs51/lkarea.c: removed old K&R style,
6724           (lnksect): changed check on boundary error,
6725           (lnksect2): changed check on boundary error,
6726           (lnksect2): extend XSTK to end of page if size = 1
6727         * as/mcs51/lkmain.c: removed old K&R style,
6728           (Areas51): create l_IRAM symbol
6729         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
6730         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
6731           model-mcs51-stack-auto, added model-mcs51-xstack-auto
6732         * device/lib/_mullong.c: added version to be compiled with xstack
6733         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
6734         * device/lib/mcs51/crtxclear.asm: clear pdata as well
6735         * device/lib/mcs51/crtxstack.asm: fixed comment
6736         * src/SDCCglue.c: maxInterrupts defaults to 0,
6737           (emitMaps): added pdata,
6738           (createInterruptVect): (re)moved default,
6739           (glue): added pdata,
6740           (glue): moved __start__xstack to XSTK with default size 1
6741         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
6742           and options.float_rent when options.stackAuto is set,
6743           (linkEdit): only write XDATA_NAME if provided on command line
6744         * src/SDCCmem.h,
6745         * src/SDCCmem.c: added pdata
6746         * src/port.h: added pdata_name to PORT
6747         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
6748           (saveRegisters, unsaveRegisters): removed usage of B,
6749           (genMinus): fixed accumulator clash,
6750           (genJumpTab): added comment, this needs another look
6751         * src/mcs51/gen.c: added check for "B in use" paranoia,
6752           added pushB() and popB()
6753         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
6754           chance
6755         * src/avr/main.c,
6756         * src/ds390/main.c,
6757         * src/hc08/main.c,
6758         * src/mcs51/main.c,
6759         * src/pic/main.c,
6760         * src/pic16/main.c,
6761         * src/xa51/main.c,
6762         * src/z80/main.c: (reset_regparms) made void parameter explicit and
6763           added PSEG (PAG,XDATA) or NULL to port specifier
6764         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
6765         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
6766           (_mcs51_genInitStartup): removed __start__xstack equ,
6767           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
6768         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
6769         * src/z80/gen.c (_rleAppend): fixed warnings
6770         * support/regression/tests/zeropad.c: added pdata test
6771         * .version: bumped to 2.4.6
6772
6773 2004-10-17 Borut Razem <borut.razem AT siol.net>
6774
6775         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
6776         as a part of nightly build
6777
6778 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
6779
6780         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
6781         WREG holds the first byte function parameters,
6782         * (aopForSym): take special case for symbols which are in FARSPACE
6783         but in CODESPACE too,
6784         * (assignResultValue): modified to take into account _G.useWreg,
6785         * (genCall): don't use wreg for parameter passing when function is
6786         declared as reentrant, too, added optimization INCF to stack
6787         pointer when stack parameter count is 1,
6788         * (genFunction, genEndFunction): refurnished and fixed to not using
6789         wreg for passing parameters when function has varargs or is
6790         reentrant, fixed bug with symbol name compare for generating
6791         functions in absolute address,
6792         * (pic16_storeForReturn): refurnished,
6793         * (genCmp): began writing a new version of the function, not ready
6794         yet, therefore it is disabled,
6795         * (genAssign): do not read code memory when assigning a function to
6796         a pointer function,
6797         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
6798         array of characters, not pointer,
6799         * (pic16initialComments): in debug mode emit an .ident directive for
6800         the assembler,
6801         * (_process_pragma): emit a new warning type (internal to pic16)
6802         when setting stack to default length, emit a similar warning when
6803         placing a function at absolute address and address is not word aligned
6804         * (_pic16_parseOptions): added 'return TRUE' statement,
6805         * (_pic16_linkEdit): if compiling a source, then add the source's
6806         file object, first in the list of objects to link,
6807
6808 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
6809
6810         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
6811         * src/pic/main.c : removed VC warning.
6812         * src/pic/gen.c : changed comment.
6813
6814 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
6815
6816         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
6817         reference to a deprecated symbol _GPTRREG was causing failure to
6818         link. Thanks G. M. Gallant for the info.
6819
6820 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
6821
6822         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
6823         comments for Bugs item #954788.
6824
6825 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
6826
6827         * src/pic16/device.c (pic16_dump_gsection,
6828         * pic16_groupRegistersInSection): handle symbols declared to be in
6829         access bank differently,
6830         * src/pic16/gen.c (struct _G): added field resDirect,
6831         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
6832         send values read from stack directly to result and don't allocate
6833         temporary values,
6834         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
6835         same registers,
6836         * (pic16_sameRegsOfs): NEW,
6837         * (freeAsmop): if _G.resDirect is set then do not mark registers as
6838         free because they were not allocated from temporary pool,
6839         * pic16_popRegFromString): workaround to fix a problem with
6840         allocating variables twice or never,
6841         * (genGenPointerGet): using PRODL instead of FSR0H,
6842         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
6843         instead of FSR0H,
6844         * (genAssign): take advantage of the _G.resDirect flag,
6845         * (genCast): around line 11844, use mov2f instead of directly
6846         MOVFF'ing between operands to account for literal values,
6847         * src/pic16/genutils.c: some new debug functions for gpsim have been
6848         added,
6849         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
6850         float with integer part only,
6851         * src/pic16/main.c (_process_pragma): handle pragma udata access to
6852         place variables in access bank
6853         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
6854         updated sources to reflect recent changes in gen.c
6855
6856 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
6857
6858         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
6859         sources that searched for headers in installation path, now the
6860         device/include/pic16 is used,
6861         * src/pic16/glue.c (pic16glue),
6862         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
6863         .line directives if not in debug mode, this suppresses assembler's
6864         warnings for ignored directives
6865
6866 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
6867
6868         * src/port.h: made reset_regparms prototype void parameter explicit.
6869         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
6870         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
6871         * doc/sdccman.lyx: documented warning disabling and how to use
6872           printf_large to make it print floats.
6873         * device/include/stdbool.h: NEW
6874         * device/lib/_atof.c,
6875         * device/lib/_divuint.c,
6876         * device/lib/_divulong.c,
6877         * device/lib/expf.c,
6878         * device/lib/printf_large.c,
6879         * device/lib/sincosf.c,
6880         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
6881         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
6882           a completely reentrant lib.
6883
6884 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
6885
6886         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
6887         * device/include/pic16/stdio.h: fixed bug with colon
6888
6889 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
6890
6891         * device/include/pic16/stdio.h,
6892         * device/include/pic16/stdlib.h,
6893         * device/include/pic16/math.h: NEW
6894         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
6895         declared as _naked to reduce overhead
6896         * device/lib/Makefile.in (target port-specific-objects-pic16):
6897         changed * to *.* so to ignore the CVS directory,
6898         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
6899         stacked variables back in stack,
6900         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
6901         corruption
6902
6903 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
6904
6905         * .version: bumped version number to 2.4.5
6906         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
6907         * support/Util/SDCCerr.c (messages structure): added entry for
6908         W_POSSBUG2
6909
6910         Large cumulative patch for pic16 port and libraries.
6911         * device/include/pic16/sdcc-lib.h,
6912         * device/include/pic16/stdarg.h,
6913         * device/include/asm/pic16/features.h,
6914         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
6915         * device/include/pic16/float.h: changes reentrant keyword with
6916         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
6917         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
6918         updated target build-libraries to include objects from gptr,
6919         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
6920         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
6921         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
6922         all function headings,
6923         * src/SDCCmain.c: added global parameter userIncDirsSet,
6924         * (parseCmdLine): when option -I is encountered add directory to
6925         userIncDirsSet too,
6926         * src/version.awk: added space between control and long,
6927         * src/pic16/NOTES: added some notes for the port,
6928         * src/pic16/gen.c: added prototype for mov2fp function,
6929         * (fReturnpic16[]): properly named return value registers,
6930         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
6931         * (aopForSym): added code to handle symbols with onStack flag set,
6932         symbols onStack are allocated PTRSIZE bytes,
6933         * (aopFreeAsmop): handles special case where asmops are stack objects,
6934         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
6935         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
6936         added argument lock to trace flaws in allocating temporary registers
6937         when developing port,
6938         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
6939         * (pic16_popRegFromString): reenabled allocating a direct register
6940         from string,
6941         * (assignResultValue): various beautifications,
6942         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
6943         referenced function argument,
6944         * (genIpush): reenabled to allow stacked arguments, handles only
6945         ic->parmPush iCodes,
6946         * (genCall, genPcall): major changes to allow for variable argument
6947         functions, fixed a bug with falsely restoring stack pointer after
6948         returning from call,
6949         * (genFunction): pending code for critical function,
6950         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
6951         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
6952         * (genNearPointerGet): fixed bug with indirect reading, was always
6953         reading from INDF0
6954         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
6955         pointers,
6956         * (genAddrOf): rewrote code to take address of a stacked function parameter
6957         * (genCast): fixed casting to generic pointer type,
6958         * src/pic16/gen.h: added AOP_STA,
6959         * (struct asmop): added field stk,
6960         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
6961         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
6962         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
6963         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
6964         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
6965         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
6966         generic pointers,
6967         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
6968         and library paths,
6969         * (pic16_port structure): generic pointer size is set to 3,
6970         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
6971         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
6972         compiler warning,
6973         * src/pic16/ralloc.c (allocReg): prevent allocating register when
6974         operand is an iTemp,
6975
6976 2004-09-24 Martin Helmling <mh AT octo-soft.de>
6977
6978         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
6979         * debugger/mcs51/simi.c: addapt new syntax of s51
6980
6981 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
6982
6983         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
6984         * src/pic16/pcode.c: commented out some calls to free() in order to
6985         fix bug #989576,
6986
6987 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6988
6989         * src/SDCCicode.h,
6990         * src/SDCCicode.c (isiCodeInFunctionCall),
6991         * src/avr/ralloc.c (selectSpil),
6992         * src/pic/ralloc.c (selectSpil),
6993         * src/pic16/ralloc.c (selectSpil),
6994         * src/ds390/ralloc.c (selectSpil),
6995         * src/hc08/ralloc.c (selectSpil),
6996         * src/xa51/ralloc.c (selectSpil),
6997         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
6998         stack in the middle of a function call sequence (fixes bug #1020268)
6999         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
7000         costs associated with the minimum switch case.
7001
7002 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7003
7004         * src/SDCC.lex: fixed bug #1030549
7005
7006 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7007
7008         * src/SDCCcse.h (struct cseDef),
7009         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
7010         over a function call if the CSE is derived from a symbol whose
7011         address has been taken (fixes bug #1029883)
7012         * support/regression/tests/bug-1029883: a new regression test for
7013         this bug
7014
7015 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7016
7017         * src/hc08/gen.c (emitinline): fixed bug #1029778
7018         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
7019         to a cast object is no longer a syntax error ("fixes" bug #1030006,
7020         and starts toward RFE #905167)
7021
7022 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
7023
7024         * src/pic16/gen.c (mov2f): New function to move an operand to
7025         another without considering if it is a literal or a register,
7026         * (pic16_sameRegs): don't check if they are both AOP_REG,
7027         * (AccRsh): removed andmask=0 lines,
7028         * (genLeftShift): duplicated to be improved in future versions,
7029         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
7030         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
7031         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
7032         * (pic16initMnemonics): added initialization for POC_INFSNZW,
7033         * (insertBankSwitch): fixed inserting banksel directives algorithm
7034         for instructions that follow a skip instruction, this fixes a report
7035         for broken subtraction code generation,
7036         * src/pic16/ralloc.c (deassignLRs): do not free register if current
7037         iCode is a left op, just in case result and right share the same
7038         registers
7039
7040 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7041
7042         * src/hc08/main.c,
7043         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
7044         preservation of HX
7045         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
7046         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
7047         on 2004-09-12; it was buggy
7048
7049 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
7050
7051         * src/SDCCsymt.h: removed RESULT_CHECK
7052         * src/SDCCast.c,
7053         * src/SDCCglue.c,
7054         * src/SDCCval.c,
7055         * src/pic/glue.c,
7056         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
7057
7058 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
7059
7060         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
7061         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
7062         configuration values no more rejected by compiler, they are assigned
7063         to configuration registers with a warning message instead,
7064         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
7065         the for-loop so last conf register is emitted too,
7066         * (_pic16_initPaths): link library libsdcc.lib by default,
7067         * (_hasNativeMulFor): modified test for multiplication according to
7068         Raphael Neider's remarks. Integer multiplication is also done with
7069         support functions,
7070         * device/include/pic16/pic18fregs.h: corrected type error in while
7071         testing and including 18f6720 header file
7072
7073 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
7074
7075         * src/pic16/device.h (pic16_options): removed field use_crt,
7076         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
7077         until an optimization to handle single bits is added,
7078         * (pic16_loadFSR0): moved before genUnpackBits,
7079         * (genAnd): some white lines removed,
7080         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
7081         leave_reset flags in pic16_options when using crt modules,
7082
7083 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
7084
7085         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
7086           for bugs 898889 & 979599. Also used some safer print instructions.
7087
7088 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
7089
7090         * src/pic16/device.h (pic16_options_t): added field use_crt,
7091         crt_name, no_crt,
7092         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
7093         catch a probable future bug,
7094         * src/pic16/gen.c: aopIdx function commented out,
7095         * (genAssign): commented out old code which used aopIdx,
7096         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
7097         code, added if conditionals to take into account the --use-crt
7098         command line options,
7099         * src/pic16/main.c (pic16_optionsTable): added new command line
7100         options, --use-crt= and --no-crt,
7101         * (_pic16_linkEdit): now the proper crt object is added in the
7102         linker command line except than when --no-crt is specified,
7103         * src/pic16/pcode.c,
7104         * src/pic16/pcode.h: added some structures and functions for a new
7105         optimization scheme to compansate for instruction overhead between
7106         same iCodes, this scheme is currently under development and is not
7107         working in any way,
7108         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
7109         to && operator,
7110         * device/lib/pic16/startup/crt0i.c,
7111         * device/lib/pic16/startup/crt0iz.c: added global char variable
7112         __uflags to force the generation of an idata section
7113
7114 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
7115
7116         * doc/Makefile,
7117         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
7118         * doc/sdccman.lyx: updated sdcc version to 2.4.4
7119
7120 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7121
7122         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
7123         Frieder) and clarified the default code optimization mode
7124
7125 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7126
7127         * src/SDCC.lex (doPragma, process_pragma),
7128         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
7129         "opt_code_size", and "opt_code_balanced"
7130         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
7131         regrouped options by category, added support for category headers
7132         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
7133         and "--opt-code-size"
7134         * doc/sdccman.lyx: documented these new options and pragmas
7135         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
7136         preference into account
7137
7138 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
7139
7140         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
7141           geniCodePreDec): Fixed bug 904237 by generating a warning
7142         * src/SDCCerr.h,
7143         * src/SDCCerr.c: added warning W_SIZEOF_VOID
7144
7145 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
7146
7147         * src/pic/device.c : When no max ram set validate full memory range.
7148         * src/pic/pcode.c,
7149         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
7150
7151 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
7152
7153         * device/lib/_gptrget.c,
7154         * device/lib/_gptrput.c: updated comment
7155         * device/lib/calloc.c,
7156         * device/lib/free.c,
7157         * device/lib/malloc.c,
7158         * device/lib/realloc.c: added LGPL, made them reentrant-safe
7159         * src/SDCCcse.c (cseBBlock),
7160         * src/SDCCicode.c (printOperand, geniCodeArray),
7161         * src/SDCCicode.h (struct operand): fixed bug 868103
7162         * support/regression/tests/bug-868103.c: added
7163         * src/SDCCast.c (searchLitOp),
7164         * src/SDCCcse.h (struct cseDef),
7165         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
7166         * src/SDCCicode.h (struct operand),
7167         * src/SDCCsymt.h (struct sym_link),
7168         * src/avr/gen.c (hasInc),
7169         * src/ds390/gen.c (hasInc),
7170         * src/hc08/gen.c (genPlusIncr, hasInc),
7171         * src/mcs51/gen.c (hasInc),
7172         * src/pic16/glue.c (pic16_printIvalChar),
7173         * src/pic16/ralloc.c (regWithIdx),
7174         * src/xa51/gen.c (hasInc) : removed warnings
7175         * src/SDCCast.c (createBlock): added comment ???
7176         * src/hc08/ralloc.c: updated comments
7177
7178 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7179
7180         * doc/sdccman.lyx: updated section on switch statements, added
7181         section about semaphore locking
7182         * doc/Makefile: added option -info for latex2html
7183         * device/lib/_gptrget.c,
7184         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
7185
7186 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
7187
7188         * src/pic/device.h,
7189         * src/pic/device.c,
7190         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
7191          maxram is less than 0x100.
7192
7193 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
7194
7195         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
7196
7197 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7198
7199         * src/port.h,
7200         * src/mcs51/main.c,
7201         * src/ds390/main.c,
7202         * src/z80/main.c,
7203         * src/hc08/main.c,
7204         * src/pic/main.c,
7205         * src/pic16/main.c,
7206         * src/avr/main.c,
7207         * src/xa51/main.c
7208         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
7209         a jump table is the best form for a switch statement, including
7210         automatic insertion of missing cases to make the case range
7211         continuous. Developed in collaboration with Frieder Ferlemann.
7212
7213 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7214
7215         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
7216         accumulator result if it needs sign extension
7217
7218 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
7219
7220         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
7221
7222 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
7223
7224         * device/lib/gbz80/printf.c,
7225         * device/lib/z80/printf.c: removed define for NULL
7226
7227 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
7228
7229         * as/xa51/xa_link.c,
7230         * device/examples/ds390/ow390/ad26.c,
7231         * device/examples/ds390/ow390/cnt1d.c,
7232         * device/examples/ds390/ow390/counter.c,
7233         * device/examples/ds390/ow390/ds2480.h,
7234         * device/examples/ds390/ow390/ds2480ut.c,
7235         * device/examples/ds390/ow390/findtype.c,
7236         * device/examples/ds390/ow390/gethumd.c,
7237         * device/examples/ds390/ow390/owllu.c,
7238         * device/examples/ds390/ow390/ownetu.c,
7239         * device/examples/ds390/ow390/swt12.c,
7240         * device/examples/ds390/ow390/swtloop.c,
7241         * device/examples/ds390/ow390/temp.c,
7242         * device/examples/ds390/ow390/temp10.c,
7243         * device/examples/ds390/ow390/thermo21.c,
7244         * device/examples/ds390/ow390/tinilnk.c,
7245         * device/examples/ds390/ow390/tstfind.c,
7246         * device/examples/serialcomm/windows/serial.cpp,
7247         * device/examples/serialcomm/windows/test_serialcomm.cpp,
7248         * device/include/reg51.h: fixed line endings for cvs
7249
7250 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7251
7252         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
7253         packRegsForAccUse, packRegisters): new accumulator register
7254         packing algorithm
7255         * support/regression/ports/hc08/support.c (_putchar): suppress
7256         warning of unused variable
7257         * src/SDCCicode.c: added SWAP entry to codeTable
7258
7259 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
7260
7261         * device/lib/sprintf.c: forgot to add this file before previous commit
7262
7263 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
7264
7265         * src/pic16/gen.c (genPackBits): added operand right in function
7266         parameters, load result directly if p_type is POINTER (that is
7267         called by genNearPointerSet)
7268         * (genUnPackBits): added operand left in function parameters,
7269         * (genNearPointerGet, genNearPointerSet): prevent the loading of
7270         FSR0 if accessing bitfields,
7271
7272 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
7273
7274         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
7275           _print_format; updated printf, sprintf, vsprintf
7276         * device/include/asm/default/features.h: corrected comment/define
7277         * device/lib/Makefile.in: added sprintf.c
7278         * device/lib/libsdcc.lib: added sprintf module
7279         * device/lib/printf_large.c,
7280         * device/lib/vprintf.c,
7281         * device/lib/sprintf.c: totally refactored printf_large and vprintf
7282           into these 3 files
7283         * support/regression/Makefile: changed ALL_PORTS into a usefull default
7284         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
7285         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
7286           hc08 test
7287         * support/regression/tests/zeropad.c: define idata as data for hc08
7288
7289 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7290
7291         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
7292         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
7293         labels are referenced at least once (even if a reference is not found)
7294         * src/hc08/gen.c (emitcode): set isComment flag for comments
7295         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
7296         loads), rules 6a..6b (optimize jumps to return)
7297
7298 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7299
7300         * device/lib/acosf.c (acosf),
7301         * device/lib/asinf.c (asinf),
7302         * device/lib/atanf.c (atanf),
7303         * device/lib/ceilf.c (ceilf),
7304         * device/lib/cosf.c (cosf),
7305         * device/lib/coshf.c (coshf),
7306         * device/lib/cotf.c (cotf),
7307         * device/lib/fabsf.c (fabsf),
7308         * device/lib/floorf.c (floorf),
7309         * device/lib/log10f.c (log10f),
7310         * device/lib/logf.c (logf),
7311         * device/lib/sinf.c (sinf),
7312         * device/lib/sinhf.c (sinhf),
7313         * device/lib/sqrtf.c (sqrtf),
7314         * device/lib/tanf.c (tanf),
7315         * device/lib/tanhf.c (tanhf),
7316         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
7317         replaced all instances of "reentrant" in the library functions
7318         defined in math.h with this macro.
7319         * support/regression/tests/float_trans.c: reenabled test for hc08
7320
7321 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
7322
7323         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
7324         erroneously deleted
7325
7326 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7327
7328         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
7329         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
7330         multi-byte volatile operands are used
7331         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
7332         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
7333         initialization to area GSINIT0 so that it would always precede
7334         any static initializers in GSINIT
7335         * support/regression/tests/zeropad.c: fixed idata define for hc08
7336         * support/regression/tests/bug-927659.c,
7337         * support/regression/tests/float_trans.c: disabled tests for hc08
7338         pending missing library routines
7339         * .version: increased version number to 2.4.4 - hc08 port now passes
7340         regression tests
7341
7342
7343 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
7344
7345         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
7346         * Makefile.common.in,
7347         * as/Makefile,
7348         * as/hc08/Makefile.in,
7349         * as/mcs51/Makefile.in,
7350         * as/z80/Makefile.in,
7351         * debugger/mcs51/Makefile.in,
7352         * device/include/Makefile.in,
7353         * device/lib/Makefile.in,
7354         * doc/Makefile,
7355         * link/Makefile,
7356         * link/z80/Makefile.in,
7357         * packihx/Makefile.in,
7358         * sim/ucsim/main_in.mk,
7359         * sim/ucsim/avr.src/Makefile.in,
7360         * sim/ucsim/doc/Makefile.in,
7361         * sim/ucsim/gui.src/serio.src/Makefile.in,
7362         * sim/ucsim/hc08.src/Makefile.in,
7363         * sim/ucsim/s51.src/Makefile.in,
7364         * sim/ucsim/xa.src/Makefile.in,
7365         * sim/ucsim/z80.src/Makefile.in,
7366         * src/Makefile.in,
7367         * support/cpp2/Makefile.in,
7368         * support/librarian/Makefile,
7369         * support/makebin/Makefile: added DESTDIR to the install path proposed
7370         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
7371         * doc/sdccman.lyx: added DESTDIR documentation
7372
7373 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
7374
7375         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
7376         instruction for interrupt handlers, use fast returns when returning
7377         from high priority interrupts
7378
7379 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7380
7381         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
7382         code generation
7383         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
7384         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
7385         bugs, ported much of Bernhard's code from mcs51
7386         * src/mcs51/gen.c (genSend),
7387         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
7388         than one when calling a reentrant function
7389         * device/lib/_mullong.c: defined an alternate struct layout for big
7390         endian ports (hc08)
7391
7392 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7393
7394         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
7395         test
7396
7397 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7398
7399         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
7400         are sane and complete before asking the port its prefered parameter
7401         passing method (fixes bug #1017633)
7402         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
7403         and _ret3
7404
7405 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7406
7407         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
7408         problem in bitfields >= 8 bits.
7409
7410 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
7411
7412         * src/SDCCsymt.c: undid changes that were not meant to be committed
7413
7414 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
7415
7416         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
7417
7418 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
7419
7420         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
7421           copied and wrong bit got inverted
7422
7423 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7424
7425         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
7426         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
7427         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
7428         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
7429         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
7430         assignments to bitfields at known addresses
7431         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
7432         reads from bitfields at known addresses
7433         * src/hc08/ralloc.c (packRegisters),
7434         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
7435         genhc08Code): optimize pointer get values used as conditionals
7436         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
7437         and branch
7438
7439 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7440
7441         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
7442         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
7443         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
7444         as conditionals
7445
7446 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7447
7448         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
7449
7450 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7451
7452         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
7453         related problems
7454
7455 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
7456
7457         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
7458
7459 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7460
7461         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
7462         mcs51 port
7463
7464 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
7465
7466         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
7467
7468 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7469
7470         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
7471         cases use more compact code.
7472
7473 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
7474
7475         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
7476
7477 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7478
7479         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
7480
7481 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7482
7483         * src/SDCCsymt.h,
7484         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
7485         parameter of changePointer() from symbol* to sym_link*
7486         * src/SDCCast.c (decorateType): call changePointer() for CAST op
7487         * src/SDCCsymt.c (compareType): void* type is castable to other
7488         pointers, but not necesarily an exact match.
7489         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
7490         is no longer blindly treated as an exact match.
7491         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
7492
7493 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
7494
7495         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
7496
7497 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
7498
7499         * src/pic/gen.c,
7500         * src/pic/pcode.c,
7501         * src/pic/ralloc.h,
7502         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
7503
7504 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
7505
7506         * src/pic/device.c,
7507         * src/pic/device.h,
7508         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
7509
7510 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7511
7512         * src/mcs51/gen.c (emitcode): fixed bug #992819
7513
7514 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
7515
7516         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
7517           there's no need to make it worse
7518
7519 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7520
7521         * src/mcs51/ralloc.c (deassignLR),
7522         * src/ds390/ralloc.c (deassignLR),
7523         * src/hc08/ralloc.c (deassignLR),
7524         * src/z80/ralloc.c (deassignLR),
7525         * src/pic/ralloc.c (deassignLR),
7526         * src/pic16/ralloc.c (deassignLR),
7527         * src/avr/ralloc.c (deassignLR),
7528         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
7529         rlivePoint): fixed another part of bug #971834
7530
7531 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7532
7533         * src/z80/main.c: enabled "critical" keyword
7534         * src/z80/mappings.i,
7535         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
7536         functions (fixes bug #979646)
7537         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
7538
7539 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7540
7541         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
7542           such as c:\mydir.
7543
7544 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
7545
7546         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
7547           doesn't disable too much optimizations
7548
7549 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
7550
7551         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
7552
7553 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
7554
7555         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
7556
7557 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
7558
7559         * src/pic/gen.c tidied up tabs
7560         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
7561         * src/pic/main.c tidied up tabs
7562         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
7563         * src/pic/pcoderegs.c tidied up tabs
7564         * src/pic/ralloc.c tidied up tabs
7565
7566 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
7567
7568         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
7569         to S_FIXED for pic16 port and when symbol is not in level 0,
7570         allocate for S_REGISTER storage class and pic16 port, too,
7571         * src/pic16/device.h: prototype for checkSym,
7572         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
7573         * (pic16_assignConfigWordValue): test the value and the mask to
7574         validate that the value is suitable for the configuration word,
7575         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
7576         collect extern declared symbols, don't emit symbol twice, check
7577         first if symbol is in publics set first,
7578         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
7579         * added command line '--fstack' which enables an experimental
7580         feature for stack access, too buggy to be used yet...
7581         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
7582         * (pic16_allocDirReg): when register has storage class S_REGISTER
7583         allocate in pic16_dynAccessRegs,
7584         * device/include/pic16/pic18f????.h: modified configuration word
7585         naming convention, words started as CONFIG0H but should be CONFIG1H
7586
7587 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
7588
7589         * device/include/mcs51reg.h: fixed bug 970993
7590
7591 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
7592
7593         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
7594         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
7595         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
7596         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
7597         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
7598         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
7599           error/warning numbers,
7600           added function setWarningDisabled()
7601         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
7602         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
7603           _memcmp.c _memmove.c calloc.c realloc.c free.c
7604         * support/regression/tests/malloc.c: added tests for new functionality
7605         * support/regression/tests/zeropad.c: added tests for truncated initializers
7606           and initialized char arrays starting with '\x0'
7607         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
7608
7609 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
7610
7611         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
7612
7613 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7614
7615         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
7616         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
7617         peephole 177.e. Thanks to anonymous
7618
7619 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
7620
7621         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
7622         function isn't used in the source but referenced as a
7623         variable initializer then declare it as extern in .asm file
7624
7625 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
7626
7627         * .version: increased version number to 2.4.3
7628
7629         Adding version extension according to ChangeLog CVS revision
7630         * src/Makefile.in (target all): added dependency 'version.h'
7631         * (rule version.h): added rule to create version.h from ChangeLog,
7632         * (rule dep): added dependency version.h,
7633         * src/version.awk: AWK script to create version.h
7634         * src/SDCCdwarf2.c (dwWriteModule),
7635         * src/SDCCglue.c (initialComments),
7636         * src/SDCCmain.c (printVersionInfo): modified to write after
7637         version string the version extension number,
7638         * src/SDCCutil.c: included "version.h"
7639         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
7640         number,
7641         * src/SDCCutil.h: added prototype for getBuildNumber
7642
7643         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
7644         includeDirsSet, too,
7645         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
7646         const char [] is found in function prototype...
7647
7648         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
7649         moving to WREG with source is already in WREG,
7650         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
7651         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
7652         * (aopForSym): stack'ed symbols are partially supported, added
7653         if-clause to support symbols in FARSPACE,
7654         * (sameRegs): added test for AOP_ACC to see if registers are same,
7655         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
7656         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
7657         * (pic16_popRegFromString): will not allocate a new register if it
7658         doesn't find one by name, bug may have introduced...
7659         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
7660         * (genIpush): revived to use pic16 port's stack,
7661         * (genAddrOf): added incomplete case for stack'ed operand,
7662         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
7663         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
7664         can handle multibyte operands,
7665         * src/pic16/glue.c (pic16_printIval*): some debug info added,
7666         * (pic16initialComments): added message for MPLAB compatibility
7667         mode enabled,
7668         * src/pic16/main.h: prototype for pic16_mplab_comp,
7669         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
7670         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
7671         * (_pic16_linkEdit): NEW, handles link stage, transferred here
7672         because of increased complexity of procedure,
7673         * (_process_pragma): stack pragma changed to format 'stack pos len',
7674         emit symbol '_stack_end' to conform with gplink,
7675         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
7676         to search for register,
7677         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
7678         PO_GPR_REGISTER,
7679         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
7680         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
7681         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
7682         case for PO_GPR_REGISTER,
7683         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
7684         dies, the new era is ahead !...
7685         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
7686         pic16_dynInternalRegs,
7687         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
7688         * (pic16_allocDirReg): minor optimizations and bug fixes,
7689         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
7690
7691         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
7692         load stack and frame pointer with address of 'stack_end' symbol
7693
7694 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
7695
7696         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
7697         without source code but only variable initializers
7698
7699 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
7700
7701         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
7702         external are not declared as extern to reduce overhead while linking
7703
7704 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
7705
7706         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
7707
7708 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
7709
7710         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
7711           Yee Keat for the patch
7712         * src/SDCCast.c (decorateType): fixed bug #979599
7713         * src/ds390/gen.h: removed local fReturnSizeDS390
7714         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
7715         * src/ds390/gen.c (genAnd, genOr, genXor),
7716         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
7717
7718 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
7719
7720         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
7721         add relFilesSet to $3, manipulate $2 to handle linking of object
7722         files without source files in command line,
7723         * device/include/pic16 (all headers): added ID location macros,
7724         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
7725         entries for ID location bytes,
7726         * (pic16_assignIdByteValue): NEW,
7727         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
7728         added field dumpcalltree to pic16_options_t,
7729         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
7730         is used instead of pic16_Gstack_base_addr, check if (ifx) before
7731         emitting rFalseIfx label after check_carry label,
7732         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
7733         pic16_emitDIRegs), NEW
7734         * (pic16glue): dump .calltree file when option --calltree found,
7735         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
7736         * (_pic16_genAssemblerPreamble): emit ID locations after
7737         configuration registers,
7738         * (pic16_linkCmd): modifications of the link command,
7739         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
7740         * (pic16_pCodeInitRegisters): don't init stack registers,
7741         * (pic16_findPrevInstruction): fixed bug,
7742         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
7743         bug with immediate registers,
7744         * (buildCallTree): traces stack push and pop,
7745         * (pct2): dump also stack usage for each function,
7746         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
7747         * (pic16_allocDirReg): various modifications,
7748         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
7749         fixed to 1,
7750
7751 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
7752
7753         * src/pic16/pcode.c: removed buggy double colon
7754
7755 2004-07-01 Borut Razem <borut.razem AT siol.net>
7756
7757         * support/scripts/sdcc.nsi: added include/pic16 to setup
7758
7759 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
7760
7761         * device/lib/Makefile.in: fixed bug in target objects-pic16,
7762         * device/lib/pic16/Makefile: prefixed with dash (-) command under
7763         target 'clean',
7764         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
7765         specific command line arguments. Also added sample lkr script
7766         for placing a variable at a specific memory bank.
7767         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
7768         at a specific memory bank,
7769         * (pic16_dump_isection): fixed bug which caused string literals to
7770         be omitted when dumping idata section,
7771         * (pic16_groupRegistersInSection): added code to handle registers
7772         in specific memory banks,
7773         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
7774         public, all references are renamed too,
7775         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
7776         AOP_DPTR2,
7777         * (pic16_storeForReturn): added case to handle when dest is WREG,
7778         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
7779         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
7780         pic16_rel_udata, check to see if that register is marked as being
7781         a member of a specific memory bank,
7782         * (pic16_printIvalCharPtr): added code to add string literals either
7783         to code or the idata sections,
7784         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
7785         also accept the 'udata' pragma,
7786         * src/pic16/main.h: new structure types sectName and sectSym
7787         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
7788         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
7789         * (pic16_findPrevInstruction): fixed, it returned nothing,
7790         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
7791         instruction combinations,
7792         * (pic16_FixRegisterBanking): heavily reorganised,
7793         * (pic16_AnalyzeBanking): if generating banksel directives is
7794         disabled, then don't call FixRegisterBanking at all,
7795         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
7796         completely removed,
7797         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
7798
7799 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
7800
7801         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
7802         Phuah Yee Keat <yk.phuah AT nestac.com>
7803
7804 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
7805
7806         * src/pic16/glue.c (pic16createInterruptVect): function now emits
7807         correctly the IVT even if it is relocated to some other location
7808
7809 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
7810
7811         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
7812         * device/include/pic16/pic18f2220.h: NEW,
7813         * device/lib/pic16/libdev/pic18f2220.c: NEW,
7814         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
7815         * src/pic16/device.c (struct Pics16): added info for 18f2220,
7816         * src/pic16/device.h (struct pic16_options): added ivt_loc and
7817         nodefaultlibs, ivt_loc is the location of the interrupt vector
7818         table, and nodefaultlibs signs that default libraries should not be
7819         linked in link stage,
7820         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
7821         according to --ivt-loc argument,
7822         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
7823         when pragma stack is found,
7824
7825 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7826
7827         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
7828         256 (range check), 257 (do while), 258.a-f (bit banging
7829         f.e. on 3-wire SPI bus)
7830
7831 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7832
7833         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
7834         variables used exclusively within a loop
7835
7836 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
7837
7838         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
7839
7840 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7841
7842         * src/SDCClrange.c (computeClash): fixed bug #971834
7843
7844 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7845
7846         * src/mcs51/gen.c (genCmp): fixed bug #975903
7847         * src/hc08/gen.c (operandsEqu),
7848         * src/ds390/gen.c (operandsEqu),
7849         * src/z80/gen.c (operandsEqu),
7850         * src/pic/gen.c (operandsEqu),
7851         * src/pic16/gen.c (operandsEqu),
7852         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
7853         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
7854
7855 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7856
7857         * src/SDCCcse.c (cseBBlock): fixed bug #966963
7858
7859 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
7860
7861         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
7862         default case in switch statement,
7863         * glue.c (pic16_initPointer): expr is initialised via decoarteType
7864         to eliminate problem with initialisation of pointers, but problem
7865         still exists,
7866         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
7867         * (emitStaticSegment): removed various lines emitting debug info,
7868         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
7869         added processor registers for utilizing EEPROM,
7870         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
7871         configurable and set 8
7872
7873 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
7874
7875         * .version: increased version number to 2.4.2,
7876
7877         Cumulative patch for pic16 port
7878         * src/pic16/device.c: changed scheme to dump initial values for
7879         variables in idata segment, all print_idata* functions were removed,
7880         now the pic16_printIval* will be called,
7881         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
7882         * _pic16_printPointerType, pic16_printPointerType,
7883         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
7884         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
7885         NEW, similar to the respective functions in SDCCglue.c,
7886         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
7887         way, emitting hex bytes,
7888         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
7889
7890 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7891
7892         * src/avr/ralloc.c (serialRegAssign),
7893         * src/xa51/ralloc.c (serialRegAssign),
7894         * src/pic/ralloc.c (serialRegAssign),
7895         * src/pic16/ralloc.c (serialRegAssign),
7896         * src/hc08/ralloc.c (serialRegAssign),
7897         * src/z80/ralloc.c (serialRegAssign),
7898         * src/ds390/ralloc.c (serialRegAssign),
7899         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
7900
7901 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7902
7903         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
7904         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
7905
7906 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
7907
7908         Cumulative patch for pic16 port:
7909         * src/pic16/device.h (typedef PIC16_device) modified fields for
7910         defining microcontrollers,
7911         * src/pic16/device.c: added new info for all devices in Pics16 array,
7912         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
7913         to be optimised out by the pCode optimiser,
7914         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
7915         specially, bug reported by G.M. Gallant,
7916         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
7917         as force'd so that cannot be optimised out by pCode optimiser,
7918         * src/pic16/pcode.c,
7919         * src/pic16/pcodepeeph.c,
7920         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
7921         they are disabled by default, but can be enabled explicit with
7922         command argument --denable-peeps, for testing,
7923         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
7924         --pomit-ivt in COMPILE_FLAGS
7925
7926 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
7927
7928         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
7929           compilation on MSVC
7930
7931 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
7932
7933         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
7934
7935 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7936
7937         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
7938         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
7939
7940 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
7941
7942         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
7943         would only assign 0x300001 register.
7944
7945 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
7946
7947         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
7948         in COMPILE_FLAGS. Thanks to G. Gallant for report.
7949
7950 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7951
7952         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
7953         for ds80c400
7954         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
7955         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
7956         added peephole 254 (left shift), 255 (jump table)
7957
7958 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
7959
7960         * device/lib/Makefile.in: removed comment line with model-pic16,
7961         * (target port-specific-objects-pic16): the libraries and objects
7962         are copied to the build directory form the device/lib/pic16/bin
7963         directory
7964
7965         Cumulative patch concerning pic16 port:
7966         * library directory has been re-organized,
7967         * added support for PIC18F1220,
7968         * added headers and library sources for chips 18f1220,18f6520,
7969         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
7970
7971         * configuration registers setting has changed, now each supported
7972         device has a complete description of the registers it uses,
7973         * all initialisations are moved to idata sections, these section
7974         can be absolute or relocatable,
7975         * fixed initialisation of codespace variables,
7976         * fixed warning about PCLATU and gpsim,
7977         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
7978         * (genAssign): use table reads when assigning from variables in codespace,
7979         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
7980         char/int variables placed in codespace,
7981         * (pic16_emitConfigRegs): NEW, emits a list with configuration
7982         registers set in .asm file, no need for --pomit-config-words anymore,
7983         * (pic16glue): some 8051 legacy segments are commented out
7984         (to be removed completely),
7985         * added support for alternative assembler and linker with --asm=
7986         and --link= command line arguments,
7987         * peepholes are disabled automatically in the port, no need to
7988         specify on command line,
7989         * port supports natively char/int/long multiplication, but converts
7990         all divisions to support functions,
7991         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
7992         to the file set in variable $2,
7993         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
7994         strings in ASCII format and not in hex,
7995         * ralloc.c (serialRegAssign): added a triplet of conditional calls
7996         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
7997         allocate proper register if iCodes aren't temporary,
7998
7999 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
8000
8001         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
8002
8003 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
8004
8005         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
8006         is commented out
8007
8008 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8009
8010         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
8011         computed address is reused
8012         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
8013         multi-byte bitfields
8014
8015 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
8016
8017         * src/z80/gen.c: (genArrayInit): must check for pointers too
8018
8019 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
8020
8021         * support/regression/tests/zeropad.c: never meant to commit the
8022           nestedstruct test: removed, added check for GCC version
8023
8024 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
8025
8026         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
8027         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
8028         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
8029           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
8030           bugs 928906 and 954082 half-empty initializers
8031         * src/SDCCsymt.h,
8032         * src/SDCCsymt.c (getAllocSize): added for above fix
8033         * src/z80/gen.c (genArrayInit): fixed bug 741044
8034         * support/regression/tests/zeropad.c: added tests
8035
8036 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
8037
8038         * src/pic16/device.c (pic16_dump_section): corrected bug which
8039         caused some symbols of the libraries to be misplaced
8040
8041 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
8042
8043         * src/pic16/glue.c,
8044         * src/pic16/ralloc.h,
8045         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
8046         to fix conflict with pic port
8047
8048 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
8049
8050         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
8051         externs configuration variables,
8052         * src/pic16/ralloc.h,
8053         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
8054         prototype in header, commented out some debug messages
8055
8056 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
8057
8058         * src/pic16/glue.c,
8059         * src/pic16/main.c,
8060         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
8061         for gpasm COFF object generation. Thanks to D. Hawkins for
8062         his patch info
8063
8064 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8065
8066         * src/ds390/main.c,
8067         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
8068         Brock for spotting this)
8069         * src/ds390/gen.c (genEndFunction),
8070         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
8071         interrupt handler and critical. Disable push/pop optimizations when
8072         peephole optimizations disabled.
8073
8074 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
8075
8076         Updated pic16 library sources and headers.
8077         * device/lib/pic16/pic18f*/ ,
8078         * device/include/pic16/*.h: modified to handle structured SFR
8079         definitions
8080
8081 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
8082
8083         * src/port.h (PORT structure): added hook initPaths, now each
8084         port can declare its own default search paths,
8085         which can been seen with the --print-search-dirs option,
8086         see pic16 port for example,
8087         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
8088         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
8089         * (doPrintSearchDirs): NEW, replaces in a central manner the
8090         printing of search dirs which was split in set*Paths functions,
8091         * (main): added call to port->initPaths and doPrintSearchDirs,
8092         * src/avr/main.c,
8093         * src/ds390/main.c,
8094         * src/hc08/main.c,
8095         * src/izt/i186.c,
8096         * src/izt/tlcs900h.c,
8097         * src/mcs51/main.c,
8098         * src/pic/main.c,
8099         * src/pic16/main.c: modified port structures to reflect addition of
8100         initPaths hook,
8101
8102         * src/pic16/device.c (regCompare): registers are finally sorted by name,
8103         * (pic16_dump_section): for registers in same address reserve memory once,
8104         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
8105         to no_banksel,
8106         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
8107         result is greater in size than right or left,
8108         * (pic16_genUMult8X8_8): there are some cases where the result can
8109         be 16 bits size, so handle these,
8110         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
8111         * (pic16_outBitC): modified to emit pcodes,
8112         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
8113         or not,
8114         * (genDivOneByte): implemented algorithm to divide 8-bits,
8115         * (genCmp): uncommented goto, but issues still exist,
8116         * (genAnd): fixed a bug with variables >8bits,
8117         * (genPackBits): optimization added that uses BCF/BSF to change a
8118         single bit,
8119         * (genAssign): fixed bug when assigning floating point literals,
8120         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
8121         __sdcc_gsinit_startup label,
8122         * src/pic16/main.c (_pic16_init): removed search directory
8123         initialisations,
8124         * (_pic16_initPaths): NEW, used to initialise search directories,
8125         * (_hasNativeMulFor): support functions for all except char/int
8126         multiplication, and char division,
8127         * (PIC16_port struct): modified entry for native mul support,
8128         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
8129         no_banksel option,
8130         * (buildCallTree): call to register_usage is ifdef'ed out,
8131
8132 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8133
8134         * device/include/string.h: applied Stas Sergeev's patch to make this
8135         header file compatible with the preprocessor -Wundef option
8136         * src/SDCCmain.c (main): abort compilation if preprocessor reports
8137         failure (fixes bug #941458)
8138
8139 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8140
8141         * src/SDCCopt.c (killDeadCode): fixed bug #907733
8142         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
8143         that the variable, not the function, should be static
8144         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
8145         to be consistent with non-literal case
8146
8147 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8148
8149         * src/SDCCast.c (isConformingBody): fixed bug #949967
8150         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
8151         convilong): fixed bug #952086
8152
8153 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8154
8155         * src/SDCCmem.c (allocVariables): fixed bug #955321
8156
8157 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8158
8159         * src/hc08/main.c (_hc08_genAssemblerEnd),
8160         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
8161         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
8162         completely eliminated the use of a temporary file
8163         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
8164         when more than one file linked
8165         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
8166
8167 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8168
8169         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
8170         which fixes bug #543481
8171         * support/regression/tests/bug-751703.c: fixed comments left from a
8172         cut and paste error
8173         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
8174         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
8175         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
8176         scopes
8177         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
8178         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
8179         are now changed to underscores in moduleName
8180
8181 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8182
8183         * as/mcs51/lkmem.c: better fix for bug #954173
8184
8185 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
8186         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8187
8188         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
8189         * device/include/c8051f000.h,
8190         * device/include/c8051f120.h,
8191         * device/include/c8051f300.h,
8192         * device/include/c8051f310.h,
8193         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
8194         PWM16) and detab'ed
8195
8196 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8197
8198         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
8199         and mailing lists, doc'ed --no-peep-comments, removed reference
8200         to knoppix (newest version has no LyX/LaTeX), other minor changes
8201         * src/SDCCglue.c (glue): save 2 bytes stack space with
8202         option --main-return. The ljmp could probably be avoided too
8203
8204 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8205
8206         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
8207
8208 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8209
8210         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
8211         * src/SDCCopt.c (isLocalWithoutDef),
8212         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
8213         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
8214         (credit to Maarten Brock for patch #949363, on which this is based)
8215         * support/regression/tests/bug-751703.c: some test cases of extern used
8216         within inner scopes.
8217
8218 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8219
8220         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
8221         SPEC_STRUCT
8222         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
8223         struct definitions
8224         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
8225         dwWriteLabel): fix to create valid debugger symbols even when
8226         the module name has non-alphanumeric symbols in it
8227         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
8228         when a variable's allocation has been optimized away
8229
8230
8231 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8232
8233         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
8234         * src/hc08/main.c,
8235         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
8236         * src/mcs51/main.c,
8237         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
8238         * src/ds390/main.c,
8239         * src/z80/gen.c (z80_emitDebuggerSymbol),
8240         * src/z80/main.c,
8241         * src/pic/gen.c (pic14_emitDebuggerSymbol),
8242         * src/pic/main.c,
8243         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
8244         * src/pic16/main.c,
8245         * src/avr/gen.c (avr_emitDebuggerSymbol),
8246         * src/avr/main.c,
8247         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
8248         * src/xa51/main.c,
8249         * src/SDCCdebug.c (emitDebuggerSymbol),
8250         * src/SDCCdebug.h,
8251         * src/port.h: added a debugger struct to the port struct. Added a
8252         callback for defining debugger symbols
8253
8254         * src/SDCCast.c (createLabel),
8255         * src/SDCC.y (labeled_statement): mark all compiler generated labels
8256         with isitmp = 1
8257         * src/SDCCicode.h,
8258         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
8259         iCode back to the ast for the function
8260
8261         * src/hc08/ralloc.c (hc08_assignRegisters),
8262         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
8263         unneeded fields from the regs struct.
8264         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
8265         pushReg() & pullReg() functions instead of emitcode()
8266
8267         * src/hc08/gen.c (genLabel, genhc08Code),
8268         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
8269
8270         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
8271         debugger hooks
8272
8273         * src/hc08/gen.c (genEndFunction, genhc08Code),
8274         * src/hc08/gen.h,
8275         * src/mcs51/gen.c (genEndFunction, gen51Code),
8276         * src/mcs51/gen.h,
8277         * src/ds390/gen.c (genEndFunction, gen390Code),
8278         * src/ds390/gen.h,
8279         * src/z80/gen.c (genEndFunction, genZ80Code),
8280         * src/z80/gen.h,
8281         * src/z80/z80.h,
8282         * src/pic/gen.c (genEndFunction, genpic14Code),
8283         * src/pic/gen.h,
8284         * src/pic16/gen.c (genEndFunction, genpic16Code),
8285         * src/pic16/gen.h,
8286         * src/avr/gen.c (genEndFunction, genAVRCode),
8287         * src/avr/gen.h,
8288         * src/xa51/gen.c (genEndFunction, genXA51Code),
8289         * src/xa51/gen.h,
8290         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
8291         specific code to cdbFile.c and out of the backend code generators
8292
8293         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
8294         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
8295         starting address is now 0
8296
8297         * as/hc08/asm.h,
8298         * as/hc08/m08pst.c,
8299         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
8300         assembler directive for DWARF support
8301         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
8302
8303         * src/src.dsp,
8304         * src/Makefile.in,
8305         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
8306
8307 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8308
8309         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
8310         and inappropriate peephole optimization in jump tables
8311
8312 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8313
8314         * as/hc08/m08pst.c,
8315         * src/SDCCglue.c: sdccopt works for the hc08 port now
8316
8317 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
8318
8319         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
8320
8321 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8322
8323         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
8324
8325 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8326
8327         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
8328         rules
8329         * src/SDCCmain.c,
8330         * src/SDCCglobl.h,
8331         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
8332         comments from the peephole optimizer replacement rules
8333         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
8334         symbols
8335         * src/SDCCcse.c (updateSpillLocation),
8336         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
8337         equivalents
8338         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
8339         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
8340         objects far pointers
8341
8342 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8343
8344         * src/SDCCsymt.h: a missing part of my last change
8345         * src/pic/ralloc.c (regTypeNum),
8346         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
8347
8348 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8349
8350         * src/SDCCicode.h,
8351         * src/SDCCicode.c (aggrToPtrDclType),
8352         * src/SDCCptropt.h,
8353         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
8354         ptrPseudoSymConvert),
8355         * src/pic/ralloc.c (regTypeNum),
8356         * src/pic16/ralloc.c (regTypeNum),
8357         * src/hc08/ralloc.c (regTypeNum),
8358         * src/ds390/ralloc.c (regTypeNum),
8359         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
8360         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
8361
8362 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8363
8364         * link/z80/lkmain.c (afile),
8365         * as/hc08/lkmain.c (afile),
8366         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
8367         prevent a pointer problem when a filename has no directory and
8368         no extension specified.
8369
8370 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8371
8372         * link/z80/lkmain.c (afile): allow periods in directory names
8373         * link/z80/lkmain.c (afile),
8374         * as/mcs51/lkmain.c (afile),
8375         * as/hc08/lkmain.c (afile): allow linker script file to have an
8376         extension other than ".lnk"
8377         * link/z80/lklex.c (getfid),
8378         * link/z80/lkmain.c (parse),
8379         * as/mcs51/lklex.c (getfid),
8380         * as/mcs51/lkmain.c (parse),
8381         * as/hc08/lklex.c (getfid),
8382         * as/hc08/lkmain.c (parse): Support comments in the linker script
8383         file on lines by themselves and after filenames
8384
8385 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8386
8387         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
8388
8389 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8390
8391         * src/z80/peeph-z80.def: removed some peephole rules that don't
8392         work with multibyte arithmetic (fixed bug #937126)
8393         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
8394         to registers and not global variables
8395         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
8396         geniCodePreInc, geniCodePostDec, geniCodePreDec,
8397         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
8398         checking for assignments not internally generated (fixed bug #931895)
8399         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
8400         structure member (fixed bug #930072)
8401
8402 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8403
8404         * src/SDCCmain.c (linkEdit),
8405         * src/hc08/main.c (_hc08_parseOptions),
8406         * as/hc08/Makefile.in,
8407         * as/hc08/aslink.h,
8408         * as/hc08/asm.h,
8409         * as/hc08/m08pst.c,
8410         * as/hc08/lkrloc.c (relr, rele),
8411         * as/hc08/lkarea.c (lnkarea)
8412         * as/hc08/lkmain.c (afile, parse),
8413         * as/hc08/lkelf.c: support for ELF output
8414         * as/hc08/lks19.c (s19),
8415         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
8416
8417 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8418
8419         * as/mcs51/lkihx.c: Fixed bug #899105.
8420
8421 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8422
8423         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
8424         .dsp files from Unix to DOS.
8425
8426 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8427
8428         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
8429         function pointers; we have been compliant for several months now.
8430         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
8431         change that was accidently commented out
8432         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
8433         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
8434         bug #922319
8435
8436 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8437
8438         * src/hc08/gen.c: output of all of the internal debugging information
8439         is now controlled by the D() macro; it is disabled by default
8440
8441 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8442
8443         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
8444         harder to keep the same registers during a CAST iCode
8445         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
8446         long via int can be done in a single cast, if the signedness is
8447         correct.
8448         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
8449         putchar() in tinibios.c in ds390's library
8450
8451 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
8452
8453         * src/SDCCast.c (decorateType): fixed bug #898889,
8454         cast result of a literal complement too
8455         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
8456         fixed check for bitfields
8457
8458 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
8459
8460         * src/SDCCicode.c (geniCodeLogic): made it static,
8461         (geniCodeLogicAndOr): added in order to fix bug #905492,
8462         (ast2iCode): fixed bug #905492
8463         * support/regression/tests/bug-905492.c: added
8464         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
8465         (processParms): fixed bug #927659: don't copy parms, this will clear
8466         decorated flag
8467         * support/regression/tests/bug-927659.c: added
8468
8469 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
8470
8471         * src/SDCCast.c (addCast): don't cast float to char
8472         * device/lib/libsdcc.lib: added _memmove
8473
8474 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
8475
8476         * device/lib/large/Makefile: fixed parallel execution by
8477         replacing `make` by `$(MAKE)`
8478
8479 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8480
8481         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
8482         offsets (fixes bug #923936)
8483
8484 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
8485
8486         * device/lib/small/Makefile: fixed parallel execution by
8487         replacing `make` by `$(MAKE)`
8488
8489 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
8490
8491         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
8492
8493 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
8494
8495         * src/pic/gen.c (genCpl): multi-byte complements were not working.
8496         * src/regression/Makefile: Regression test was not running.
8497
8498 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
8499
8500         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
8501         complement if possible
8502         * src/SDCCval.c (valComplement),
8503         * src/SDCCicode.c (operandOperation): fixed complement of literal
8504         * support/regression/tests/onebyte.c (testComplement): added
8505
8506 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
8507
8508         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
8509         return an optimized tree; actually replace actParm with the new tree
8510         * src/SDCCast.h: added some parantheses to remove side effects
8511         * support/regression/tests/bug-920866.c
8512
8513 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
8514         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
8515         Bit operands were not being handled properly in the pic14 port.
8516         (now src/regression/add.c passes again).
8517
8518 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8519
8520         * src/SDCC.y (labeled_statement): case and default no longer require
8521         a following statement (RFE #893037)
8522
8523 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8524
8525         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
8526         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
8527         disabled (fixes bug #916294)
8528         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
8529         "mov a,acc"; patch provided by Lenny Story
8530         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
8531
8532 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8533
8534         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
8535         functions
8536         * src/ds390/gen.c (genFunction, genEndFunction),
8537         * src/ds390/ralloc.c (ds390_assignRegisters),
8538         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
8539         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
8540         pushed if there are parameters passed on the stack. Also, a cleaner
8541         way to decide if r0/r1 should be pushed/popped. (Together they fix
8542         bug #918693)
8543
8544 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8545
8546         * doc/sdccman.lyx,
8547         * device/lib/mcs51/crtpagesfr.asm,
8548         * device/lib/mcs51/crtxinit.asm,
8549         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
8550         to avoid confusion with Si Lab's SFRPAGE register.
8551
8552 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8553
8554         * src/SDCCglue.c (emitMaps): allow public sfr variables
8555         * src/SDCCglue.c (initialComments): include compiler build date
8556         with compiler version and put the timestamp of the generated
8557         assembly file on a serperate line to be less confusing.
8558         * src/port.h: added genInitStartup hook
8559         * src/avr/main.c,
8560         * src/ds390/main.c,
8561         * src/hc08/main.c,
8562         * src/pic/main.c,
8563         * src/pic16/main.c,
8564         * src/xa51/main.c,
8565         * src/z80/main.c: genInitStartup initialize as NULL (default to
8566         historical behaviour)
8567         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
8568         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
8569         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
8570         library instead of hard coding it into the compiler.
8571         * support/regression/ports/mcs51-stack-auto/spec.mk,
8572         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
8573         * device/lib/mcs51/Makefile,
8574         * device/lib/small/Makefile,
8575         * device/lib/large/Makefile,
8576         * device/lib/mcs51/crtpagesfr.asm,
8577         * device/lib/mcs51/crtstart.asm,
8578         * device/lib/mcs51/crtxclear.asm,
8579         * device/lib/mcs51/crtxinit.asm,
8580         * device/lib/mcs51/crtclear.asm,
8581         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
8582         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
8583         and into user configurable files.
8584         * device/lib/clean.mk: clean mcs51 directory too
8585         * support/regression/tests/longlit.c: added static to T1 declaration
8586         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
8587         accesses in the initialization code
8588
8589 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8590
8591         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
8592         OSCTRIMVAL as noted in bug #916008
8593
8594 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8595
8596         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
8597         in loops with multiple exits (reported as incorrect registers
8598         used by Martin Helmling in Sdcc-user list)
8599
8600 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8601
8602         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
8603         made ds390 register extensions look less like error messages
8604
8605 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8606
8607         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
8608         reported by Adam Wozniak in Sdcc-user list
8609
8610 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
8611
8612         * src/SDCCast.c (decorateType): fixed with bug and promotion in
8613         arithmetic optimizations, added debug output
8614
8615 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
8616
8617         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
8618         * sdcc.spec: updated and split sdcc into 3 rpms
8619         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
8620         needed for literals of LEFT_OP and '+'
8621         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
8622         introduced RESULT_TYPE_NOPROM
8623         (geniCodeMultiply): fixed logic for decision if mul is optimized to
8624         left shift
8625         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
8626         limited promotion to int only for '*'
8627         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
8628
8629 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
8630
8631         * src/pic16/gen.c (genSkip),
8632         (genc16bit2lit), (gencjneshort): commented out
8633         (is_LitOp): new helper function, checks operand type
8634         (genCmpEq): rewritten
8635
8636 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
8637
8638         * support/regression/tests/bug-908454.c: added
8639
8640 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
8641
8642         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
8643         * src/SDCCicode.c (usualBinaryConversions): op needs int type
8644         (geniCodeCast): cosmetic, don't preserve bit storage class
8645         (geniCodeLeftShift): added promotion
8646         (geniCodeLogic): fixed regression
8647         * src/SDCCsymt.c (computeTypeOr): accept bits too
8648         (compareType): 2nd part of fix for bug #908454, needed for bitfields
8649
8650 2004-03-07  Borut Razem <borut.razem AT siol.net>
8651
8652         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
8653
8654 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
8655
8656         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
8657         version of pic16_genPackRegisters which does not check if ic is a
8658         CAST operator,
8659         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
8660         function cause string1.c regression test fails
8661
8662 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
8663
8664         * sim/ucsim/configure.in,
8665         * sim/ucsim/configure,
8666         * sim/ucsim/doc/Makefile.in: use docdir
8667         * src/SDCC.y: fixed sbit atrributes
8668         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
8669         * src/SDCCast.c (decorateType): |^& need special promotion handling
8670         * src/SDCCast.h,
8671         * src/SDCCsymt.h: moved definition of RESULT_TYPE
8672         * src/SDCCsymt.h (computeType),
8673         * src/SDCCicode.c: computeType() needs op
8674         * src/SDCCsymt.c (checkTypeSanity),
8675         * doc/sddman.lyx: "plain" bitfields are unsigned
8676         * src/SDCCsymt.c (computeTypeOr): added
8677         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
8678         |^& ops
8679         * src/SDCCval.c (val*): computeType() needs op
8680         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
8681         * support/regression/tests/onebyte.c: added tests for |^&
8682
8683 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
8684
8685         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
8686         for writing icode into asm output.
8687
8688 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
8689
8690         * src/pic16/device.c: added some debug lines enabled
8691         with macro DEBUG_CHECK,
8692         * src/pic16/genarith.c: more debug in genPlus,
8693         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
8694         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
8695         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
8696         * (aopForSym): onStack symbols are re-placed in data memspace,
8697         and onStack flag is cleared,
8698         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
8699         copy temporary pcodeop,
8700         * (genPcall): added warning for not updating PCLATU,
8701         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
8702         always true for pic16 port,
8703         * (genMultOneWord): NEW, supports integer multiplication,
8704         * (genMult): modified to call genMultOneWord,
8705         * (ifxForOp): added warning when return NULL,
8706         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
8707         flag is set before call to operandFromSymbol for implicit
8708         added structures,
8709         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
8710         options.intlong_rent are set by default,
8711         * (_hasNativeMulFor): modified to allow port generation of integer
8712         multiplication,
8713         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
8714         set regtype to REG_SFR for all registers, restricting seting the
8715         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
8716
8717 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8718
8719         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
8720         more than 500 times in the regression tests
8721
8722 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8723
8724         * support/Util/SDCCerr.h,
8725         * support/Util/SDCCerr.c,
8726         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
8727         enumerator_list),
8728         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
8729         for symbol conflicts.
8730         * support/valdiags/tests/enum.c,
8731         * support/valdiags/tests/tentdecl.c,
8732         * support/valdiags/tests/struct.c: expect possible error messages
8733         referring to original symbol definitions.
8734         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
8735         * src/SDCCsymt.h,
8736         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
8737
8738 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
8739
8740         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
8741
8742 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
8743
8744         * src/pic16/ralloc.c (newReg): fixed bug #908929
8745
8746 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8747
8748         * src/ds390/gen.c: added missing #include "main.h"
8749
8750 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
8751
8752         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
8753         checking if symbol is already in set,
8754         * src/pic16/device.h: prototype for checkAddSym,
8755         * src/pic16/gen.c: (_G): added entry interruptvector,
8756         * (assignResultValue): removed some commented out lines,
8757         * (genFunction): check for ISR via sym->type, absolute section for
8758         interrupt code is created via a new pBlock, the goto instruction is
8759         placed now correctly at the interrupt vector position, changed all
8760         references from ivec to _G.interruptvector,
8761         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
8762         is the interrupt is a high priority one, same for return from ISR,
8763         * src/pic16/glue.c: changed all calls of addSetHead for publics and
8764         externs to calls of checkAddSym,
8765         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
8766         pic16_pcode_verbose flag is set,
8767         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
8768         * src/pic16/pcoderegs.c: message about how many registers are saved
8769         will only be emitted if pic16_pcode_verbose flag is set,
8770
8771 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8772
8773         * src/ds390/ralloc.h,
8774         * src/ds390/ralloc.c (ds390_regWithIdx),
8775         * src/ds390/gen.c (emitcode),
8776         * src/ds390/main.h,
8777         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
8778         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
8779         ds390operandCompare, getRegsRead, getRegsWritten,
8780         initializeAsmLineNode): customized instruction size calculation for
8781         ds390, started basis for some register optimizations
8782         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
8783         corresponding assembly output
8784         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
8785         missing push/pop of r0/r1. Optimized push/pops
8786
8787 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8788
8789         * src/mcs51/main.c (instructionSize): fixed ACALL size
8790         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
8791
8792 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
8793
8794         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
8795         the sorting of rlist with NULL elements
8796         * (print_idataType, print_idata): NEW to create idata sections
8797         * src/pic16/device.h: idataSymSet new variable
8798         * src/pic16/gen.c (genFunction): fixed some bugs in string
8799         comparing, improved the absolute section creation for ISRs,
8800         added FSR0L/FSR0H in registers that are saved in an ISR,
8801         * (genInline): fixed the processing of inline snippets,
8802         now they undergo no process by the peephole optimizer
8803         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
8804         are placed in idataSymSet,
8805         * (pic16emitStaticSeg): extern symbols are added in externs,
8806         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
8807         switching when aboslute variables are placed in access bank memory
8808         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
8809         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
8810         commented out with #if,
8811         * (pic16_packRegisters): reintroduce the check for CAST because some
8812         symbols are not correctly handled,
8813         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
8814         pCodeInstruction instead of pCode,
8815         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
8816         pCodeAsmDir definition,
8817         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
8818         directive, then the argument directive is emitted without the leading
8819         tab, hack for inline labels which must be in the first column,
8820         * (compareLabel,pic16_findNextInstruction),
8821         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
8822         * (insertBankSwitch): modified for the new pCodeAsmDir,
8823
8824 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8825         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
8826
8827         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
8828         instance,
8829         * (pushSide): commented out with #if,
8830         * (assignResultValue): fixed some typos in saving
8831         registers,
8832         * (genPcall): FIXED and sync'ed with genCall,
8833         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
8834         * (genNearPointerGet): fixed to handle some more cases,
8835         implementation scheme via table reads,
8836         * (genConstPointerGet): modified to access code memory correct,
8837         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
8838         and improved to handle some cases
8839         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
8840         instead of "RETLW" for init data
8841         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
8842         not IN_DIRSPACE, work around to reduce bank switching when aboslute
8843         variables are placed in access bank memory (<0x80 and >=0xf80),
8844         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
8845         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
8846         TBLWT_POSTDEC,TBLWT_PREINC
8847         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
8848         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
8849         directives
8850         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
8851         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
8852         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
8853         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
8854
8855 2004-02-29  Borut Razem <borut.razem AT siol.net>
8856
8857         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
8858         support/Util/findme.h, support/Util/system.h: enhance binary relative
8859         search for lib and include by using findProgramPath()
8860
8861 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8862
8863         * src/SDCCpeeph.h,
8864         * src/SDCCpeeph.c (pcDistance),
8865         * src/port.h,
8866         * src/mcs51/ralloc.h,
8867         * src/mcs51/ralloc.c (mcs51_regWithIdx),
8868         * src/mcs51/main.h,
8869         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
8870         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
8871         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
8872         size calculation port specific, started basis for some register
8873         optimizations
8874         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
8875         missing push/pop of r0/r1. Optimized push/pops
8876         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
8877         * device/lib/_modsint.c (_modsint),
8878         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
8879         and stack version so regression tests pass
8880
8881 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
8882
8883         * src/Makefile.in (dep): include SLIBOBJS in dependency check
8884         * src/SDCCast.c (decorateType): catch another small optimization
8885         with '?' operator
8886         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
8887         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
8888         modified to finally use computeType() all over SDCC,
8889         see Feature Request #877103
8890         * src/SDCCval.h: cosmetic
8891         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
8892         valCompare(); regression tested in muldiv.c
8893         * support/regression/tests/muldiv.c (testMod): mod sign follows
8894         dividend only
8895
8896 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
8897
8898         * src/SDCCast.c (decorateType): fixed bug #902362
8899         * doc/INSTALL.txt: fixed install instructions for win32
8900
8901 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
8902
8903         * device/include/Makefile.in (install): fixed by replacing spaces
8904         by tabs
8905         * doc/README.txt,
8906         * doc/INSTALL.txt: updated for release
8907         * doc/sdccman.lyx: added warning for --xstack being buggy
8908
8909 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
8910
8911         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
8912         to eliminate build warnings.
8913         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
8914
8915 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
8916            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8917
8918         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
8919         removed -penable-stack, added comment for stack pragma, added
8920         warning for not initializing the stack/frame registers, removed
8921         comment at interrupts section
8922
8923         Stack is made permanent, there is no ability to disable stack usage.
8924         * src/pic16/device.h,
8925         * src/pic16/device.c: removed all references to USE_STACK macro,
8926         * src/pic16/device.c (pic16_dump_section): when no elements in
8927         rlist, free rlist before return,
8928         * (pic16_dump_int_registers): NEW, internal registers are a new set
8929         of general purpose registers reused by each function,
8930         * (checkAddReg): returns 1 if registers is added to set,
8931         * (pic16_groupRegistersInSection): when a registers is of type
8932         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
8933         * src/pic16/device.h: memRange and Assigned Memory are deleted,
8934         SRCASECMP macro is moved here from device.c
8935         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
8936         PO_PCLATU, PO_PRODL, PO_PRODH,
8937         * (pic16_pCodeOpType, genMinus,
8938         changed compares to "a" register, with AOP_ACC,
8939         * (pic16_genPlus): fixed some bugs and indented properly,
8940         * (pic16_addSign): changed size to size+offset in the MOVWF
8941         instruction,
8942         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
8943         multiply 8-bit operand by literal, result is 8-bit,
8944         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
8945         multiply 2 8-bit operand, result is 8-bit,
8946         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
8947         genUMult8X*_16,
8948         * src/pic16/gen.c: changed accUse to contain WREG only,
8949         * (pic16_emitcomment): renamed to pic16_emitpcomment,
8950         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
8951         true, do not use immediate addressing any more unless sym is a
8952         pointer in codespace,
8953         * (aopForRemat): do not use immediate addressing when symbol not in
8954         codespace and when symbol's address is requested,
8955         * (aopOp): for-loop in if(sym->accUse) is modified for the new
8956         accUse size (= 1),
8957         * (aopGet): added case for AOP_ACC and don't return "accumulator
8958         bug" but WREG instead,
8959         * (popGetTempReg): pushes contents of temporary register in stack,
8960         * (popReleaseTempReg): pops contents of temporary register from
8961         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
8962         * (pic16_popGet): separated case AOP_ACC to return register WREG
8963         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
8964         or PO_IMMEDIATE and initializes their instance/offset appropriately,
8965         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
8966         the use of immediate pointers to certain cases only.
8967
8968         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
8969         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
8970         * (assignResultValue, genCall, genRet): modified to use the new
8971         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
8972         genPcall is still broken,
8973         * (genFunction): added code to create 'A' type pBlocks when
8974         interrupt functions are generated, code not extensively tested yet,
8975         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
8976         * (genEndFunction): modified so ISRs pop stored registers from stack,
8977         * (genMultOneByte): cleanup,
8978         * (AccRsh): added flag andmask, to and result with appropriate mask,
8979         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
8980         * (genDataPointerGet): fixed and reenabled its use,
8981         * (genNearDataPointerGet): bugs fixed,
8982         * (genDataPointerSet): bugs fixed,
8983         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
8984         pic16_DumpSymbol, pic16_DumpOp,
8985         * src/pic16/genutils.h: function prototypes for the above functions,
8986         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
8987         pointers,
8988         * (pic16emitRegularMap): many many many improvements, but needs a
8989         major cleanup,
8990         * src/pic16/main.c: enable_stack in pic16_options is removed,
8991         * (_pic16_parseOptions): removed command line options -penable-stack,
8992         * (_process_pragma): emit stack symbol only when stack pragma is
8993         processed,
8994         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
8995         redirected to FSR0L/FSR0H pair,
8996         * (pic16_get_op, pic16_get_op2): modifications and improvements,
8997         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
8998         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
8999         for immediates,
9000         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
9001         * (dumpPicOptype): NEW,
9002         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
9003         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
9004         with movff instruction,
9005         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
9006         added pic16_int_regs, some packRegsFor* functions are commented out,
9007         because produce errors,
9008         * src/pic16/NOTES: minor modifications
9009
9010 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9011
9012         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
9013         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
9014         --pack-iram.
9015         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
9016         * as/mcs51/lkaomf51.c: fixed bug #895763
9017
9018 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
9019
9020         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
9021
9022 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9023
9024         * doc/sdccman.lyx: added details about the HC08 storage classes and
9025         interrupts, fixed the register usage info for z80 & gbz80
9026
9027 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
9028
9029         * doc/sdccman.lyx: added more pic16 port documentation
9030         * device/include/pic16/: added header pic18fregs.h
9031
9032 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
9033
9034         * doc/sdccman.lyx: added Vangelis' contribution
9035
9036 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9037
9038         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
9039         extend to the next CALL or PCALL, not just to the next CALL.
9040
9041 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
9042
9043         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
9044
9045 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9046
9047         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
9048         bug #895752 and a better fix for bug #716790
9049
9050 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9051
9052         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
9053
9054 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9055
9056         * doc/sdccman.lyx: minor changes, minor changed
9057
9058 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
9059
9060         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
9061         which can't handle SDCC_NEWONEBYTEOPS,
9062         (geniCodeMultiply): removed conversion from mult to shift for pic14
9063         and pic16
9064
9065 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9066
9067         * src/hc08/gen.h,
9068         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
9069         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
9070         thus fixing bug #895406
9071
9072 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
9073
9074         * device/lib/_modsint.c,
9075         * device/lib/_modslong.c: sign follows divisor only
9076         * src/hc08/gen.c (genMultOneByte): if result size is 1,
9077         signs or signedness can be ignored
9078         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
9079         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
9080         added optimization for IFX,
9081         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
9082         arguments;
9083         reenabled optimization for IFX, which was removed on 2004-01-11
9084         * src/SDCCast.h: added return type IFX
9085         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
9086         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
9087         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
9088         SDCC_OLDONEBYTEOPS selects the old behaviour
9089         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
9090         changed again and commented promotion rule
9091         * src/SDCCval.c (valDiv): promotion no longer necessary
9092         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
9093         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
9094         rewritten
9095         * support/regression/tests/onebyte.c: added
9096
9097 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
9098
9099         * gen.c (genInline): reverted to old code for assemnling inline
9100         code because of bug reported James Chadd
9101
9102 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
9103
9104         * ralloc.h: missing declarations from previous patch,
9105         seems that patch for ralloc.h was never applied, fixed
9106
9107 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
9108            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
9109
9110         * pcode.c,
9111         * pcode.h,
9112         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
9113         indirect addressing. Marked FSR0 as deprecated
9114         * gen.c (pointerCode): commented out, not needed now
9115         (pic16_popGet2p): new MOVFF helper function
9116         (genGenPointerGet),
9117         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
9118         (shiftRLong): removed duplicate debugging info
9119
9120 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9121
9122         * src/ds390/gen.c (genNearPointerGet),
9123         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
9124         optimization with bits, but not bitfields.
9125         * src/ds390/ralloc.c (packRegisters),
9126         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
9127
9128 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
9129
9130         * src/SDCCcse.c (algebraicOpts): copy operands before modification
9131
9132 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9133
9134         * src/SDCCsymt.h,
9135         * src/SDCCicode.c (operandFromSymbol),
9136         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
9137         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
9138         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
9139         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
9140         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
9141         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
9142         bug #892038
9143         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
9144         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
9145         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
9146         * src/SDCCsymt.c (newSymbol),
9147         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
9148         enumerator_list),
9149         * src/SDCCval.h,
9150         * src/SDCCval.c (newiList): fixed bug #885705
9151
9152 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9153
9154         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
9155         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
9156
9157 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9158
9159         * device/include/c8051f120.h,
9160         * device/include/c8051f300.h,
9161         * device/include/c8051f310.h: added/updated header files for Silicon
9162         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
9163         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
9164         in new section Submitting patches
9165
9166 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9167
9168         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
9169         genFarPointerGet, genCodePointerGet, genGenPointerGet,
9170         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
9171         genGenPointerSet),
9172         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
9173         genFarPointerGet, genCodePointerGet, genGenPointerGet,
9174         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
9175         genGenPointerSet),
9176         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
9177         genFarPointerGet, genCodePointerGet, genGenPointerGet,
9178         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
9179         genGenPointerSet),
9180         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
9181         genFarPointerGet, genCodePointerGet, genGenPointerGet,
9182         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
9183         genGenPointerSet): fixed bug #892400
9184         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
9185         to eliminate build warnings.
9186         * src/SDCCast.c (processParms),
9187         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
9188         fixed bug 751859
9189         * support/valdiag/valdiag.py: added GCC to the list of defines active
9190         when compiling with gcc
9191
9192 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9193
9194         * support/Util/SDCCerr.h,
9195         * support/Util/SDCCerr.c,
9196         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
9197         with an incomplete type (fixed bug #883734)
9198         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
9199
9200 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9201
9202         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
9203
9204 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9205
9206         * src/SDCCast.c (decorateType),
9207         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
9208         function pointer implementation
9209         * support/regression/tests/funptrs.c: added tests to verify both forms
9210         of function pointers work correctly. Added tests to verify parameters
9211         are passed in the correct order.
9212
9213 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
9214
9215         * device.c (regCompare): registers are sorted by ascending
9216         address and increasing size,
9217         * main.c (_pic16_finaliseOptions): removed the declaration
9218         of compiler macro MCU. Now a macro of the format pic18fxxxx
9219         will be defined from the command line
9220
9221 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
9222             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
9223
9224         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
9225         PCOP_RLCF was overwritten!
9226         * gen.c (genSkip): commented out calls to pic16_emitcode,
9227         * (genCmpEQ): fixed "long" compares, only high word did get compared,
9228         * (genlshTwo),
9229         * (genRRC): added debugging info,
9230         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
9231         overwritten while shifting,
9232         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
9233         overwritten while shifting,
9234         * (AccLsh),
9235         * (AccRsh),
9236         * (shiftLLeftOrResult),
9237         * (shiftRLeftOrResult),
9238         * (shiftRLong),
9239         * (shiftLLong): Implemented with pic16_emitpcode
9240         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
9241         * (genLeftShift): Fixed bug, operand for shift by variable always
9242         was "and"ed with 0x0f,
9243         * (genLeftShiftLiteral),
9244         * (genrshTwo),
9245         * (genRightShiftLiteral): added debugging info,
9246         * (genrshFour): added comment,
9247         * (genRightShift): determined signedness from operand "left"
9248         instead of "result"
9249
9250 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9251
9252         * src/SDCCicode.c (geniCodeParms),
9253         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
9254         function pointers, fixed function pointer bugs #861242 and #861896
9255
9256 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9257
9258         * device/include/c8051f000.h,
9259         * device/include/c8051f120.h,
9260         * device/include/c8051f300.h: added header files for Silicon
9261         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
9262
9263 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
9264
9265         * src/SDCCast.c (processParams): added new type flow and restructured
9266         (gatherAutoInit): added new type flow
9267         (addCast): cosmetic changes
9268         (getLeftResultType): added new type flow for array indices, patch
9269         provided by Stas, see FR #877103
9270         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
9271         array index patch by Stas
9272         * src/SDCCast.h: added prototype getResultTypeFromType()
9273         * src/SDCCval.h,
9274         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
9275         * src/pic/glue.c (pic14emitStaticSeg),
9276         * src/pic16/glue.c (pic16emitStaticSeg),
9277         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
9278         for initialization of symbols
9279         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
9280         * support/Util/SDCCerr.h:
9281         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
9282         * .version: bumped version number to 2.3.8
9283         * device/include/Makefile.in (install),
9284         * doc/Makefile (install): changed to 'rm `find ...`' construct to
9285         avoid warnings
9286
9287 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
9288
9289         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
9290         Slade Rich fixed an optimization bug
9291         * src/pic/pcodepeep.c,
9292         * src/pic/pcoderegs.c
9293         * doc/Makefile (install): added test for directory
9294
9295 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9296
9297         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
9298         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
9299         * src/pic/ralloc.c (getRegPtr, getRegGpr),
9300         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
9301         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
9302         * as/mcs51/asexpr.c (term),
9303         * as/hc08/asexpr.c (term): fixed bug #887146
9304
9305 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9306
9307         * src/z80/gen.c (genMult): handle single byte result product
9308         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
9309         DUMMY_READ_VOLATILE (fixed bug #886367)
9310
9311 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
9312
9313         * support/regression/tests/libmullong.c: fixed logic, on little endian
9314         hosts we ended without a mullong_wrapper()
9315
9316 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9317
9318         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
9319         virus/worm forged address usage.
9320
9321 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
9322
9323         Fixed promotion, it should be done on AST level:
9324         * src/SDCCast.c (addCast): added promotion to int
9325         (decorateType): updated call to upCast()
9326         * src/SDCCicode.c (geniCodeLeftShift): removed call to
9327         usualUnaryConversions()
9328
9329 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
9330
9331         * support/regression/tests/literalop.c (mulWrapper): Added a
9332         wrapper to remove integer overflow warnings.
9333
9334         * support/regression/tests/float_trans.c: Made work on host.
9335
9336         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
9337         location of sz80.
9338
9339         * support/regression/generate-cases.py (main): Changed from inline
9340         to a main method.
9341
9342         * doc/Makefile (install): Changed to depth first to get rid of
9343         missing directory install warning.
9344
9345         * as/Makefile (install-doc): Made work on Mac.
9346
9347 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
9348
9349         * src/SDCCast.c: added an additional type flow in decorateType() of
9350         opposite direction, see feature request #860006; it's enabled at runtime
9351         by setting the environment variable SDCC_NEWTYPEFLOW
9352         * src/SDCCast.h: changed prototype of decorateType()
9353         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
9354         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
9355         'char' to 'int' can be omitted, if both operands are 'unsigned char';
9356         see feature request #877103
9357         * src/SDCCval.c: updated call of decorateType()
9358         (valBitwise): fixed bug #882876
9359         (valMinus): added promotion
9360         (valLogicAndOr): result is unsigned
9361         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
9362         * src/SDCCsymt.c (computeType),
9363         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
9364         must not cause an unsigned operation
9365         * src/pic/glue (pic14emitRegularMap),
9366         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
9367
9368 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
9369
9370         * src/pic/pcode.c (PCodeID): commented out left over debug code
9371
9372 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
9373
9374         * support/valdiag/tests/overflow.c: added shift tests
9375         * src/pic/device.c,
9376         * src/pic/gen.c,
9377         * src/pic/gen.h,
9378         * src/pic/glue.c,
9379         * src/pic/main.c,
9380         * src/pic/pcode.c,
9381         * src/pic/pcode.h,
9382         * src/pic/pcodepeep.c,
9383         * src/pic/pcoderegs.c,
9384         * src/pic/ralloc.c,
9385         * src/pic/ralloc.h: applied patch from Slade Rich;
9386         added support for multiple code pages and multiple RAM banks on the
9387         PIC 14 port. The ASM files now no longer simply assume all the
9388         code / RAM are in the same page / bank. This means the linker can
9389         safely allocate code/RAM of separate ASM files to different pages/banks.
9390         * doc/sdccman.lyx: added Slade's tips
9391         * src/mcs51/peeph.def: fixed bug #880768
9392
9393 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9394
9395         * src/hc08/ralloc.c (rematStr): fixed bug #879282
9396         * src/SDCCast.c (decorateType): fixed bug #880197
9397
9398 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
9399
9400         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
9401         getopt.h.
9402
9403         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
9404         strtof is not part of C89 and isn't included with Mac OS X.
9405
9406 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9407
9408         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
9409         shiftL2Left2Result): fixed bug #879326
9410         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
9411         (genMultOneByte): fixed bug in signed vs unsigned multiplication
9412         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
9413         address fetch for clr instruction
9414         * device/lib/hc08/_mulint.c: created optimized assembly version
9415         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
9416
9417 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
9418
9419         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
9420         proposed in FR #877103
9421
9422 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
9423
9424         * src/SDCCval.c (cheapestVal): added missing checks
9425         * src/SDCCicode.c (usualBinaryConversions): fixed condition
9426         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
9427
9428 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
9429
9430         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
9431         equal operands
9432
9433 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
9434
9435         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
9436         loaded with the linker search paths (-L arguments) and the libraries
9437         to be linked with the current source (-l arguments). Changes
9438         currently will affect only the pic16 port.
9439         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
9440         include path the port specific paths and port specific libraries,
9441         * gplink command now contains the $3 argument,
9442         * src/pic16/device.h,
9443         * src/pic16/device.c,: structure PIC_device is made public and
9444         renamed to PIC16_device, the same for variable Pics which is renamed
9445         to Pics16. Updated all references to them.
9446         * src/pic16/glue.c (pic16glue): corrected bug with code
9447         initialization which bypassed the variable initializations block.
9448
9449         * device/lib/pic16/Makefile.rules: removed --penable-stack from
9450         COMPILE_FLAGS and added the --nostdinc option
9451
9452 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9453
9454         * device/include/mc68hc908jb8.h: Register defs for another member
9455         of the hc08 family. Contributed by Bjorn Bringert - thanks!
9456
9457 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
9458
9459         Documenting changes from previous commits.
9460         * configure.in (version 1.56),
9461         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
9462         when generating output files to configure the pic16 library,
9463         but now I've commented it out, since gputils aren't installed in the
9464         SF compile farm, so library won't compile
9465
9466         * device/lib/Makefile.in (version 1.56): initially I've added in
9467         target 'all' the prerequestive 'model-pic16' so it compiled the
9468         pic16 library, but now I've commented it out for the same reasons
9469         above,
9470         * added targets 'model-pic16' and 'objects-pic16' to compile the
9471         library
9472         * added target 'port-specific-objects-pic16' to handle the
9473         generated libraries and copy them into the build/ directory
9474         * added target 'clean-intermediate-pic16' to clean intermediate
9475         files into pic16 directory
9476         * in target 'installdirs' added line to create directory pic16 in
9477         the installation path
9478
9479         * device/include/Makefile.in (version 1.11): in target 'install'
9480         added lines to copy all header files to installation path,
9481         * in target 'installdirs' added line create directory for pic16
9482         headers in the installation path
9483
9484 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
9485
9486         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
9487          a function call
9488
9489 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
9490
9491         * configure,
9492         * device/lib/configure.in,
9493         * device/lib/configure: fixed for autoconf 2.57
9494
9495 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9496
9497         * src/z80/main.c (_parseOptions): fixed the portmode= command line
9498         option so that it actually works. Made it specific to the z80, since
9499         the gbz80 doesn't have these kinds of I/O ports.
9500
9501 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9502
9503         * device/include/z180.h,
9504         * device/lib/_memcpy.c,
9505         * device/lib/_memmove.c,
9506         * device/lib/_mulint.c,
9507         * device/lib/ser_ir.c,
9508         * device/lib/ser_ir_cts_rts.c,
9509         * device/lib/_strcmp.c,
9510         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
9511         * src/z80/main.c (_process_pragma): add support for pragmas bank and
9512         portmode; added deprecation warning for bank= and protmode= forms.
9513         Also, guard against buffer overflow.
9514         * src/z80/gen.c (aopGet): generate better code for sfr banked read
9515
9516 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9517
9518         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
9519         changed interrupt vector table generation to only emit declared vectors.
9520         * device/include/Makefile.in: added missing backslash
9521         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
9522
9523 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
9524
9525         Mainly changes to support compilation of the device libraries
9526         * src/pic16/device.c: stack is allocated via symbol and not
9527         via literal number. The symbol is placed in the corresponding
9528         position of the data ram
9529         * (pic16_dump_section): relocatable and absolute uninitialized
9530         data are now emitted in sorted order to reduce section naming,
9531         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
9532         weren't marked as being in the access bank,
9533
9534 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
9535
9536         Added portion of GNU PIC Library under the directory
9537         device/include/pic16 and device/lib/pic16. These files
9538         contain the declarations of SFRs for the PIC18Fxx2 devices.
9539         The directory is initialized via configure from toplevel.
9540
9541 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
9542
9543         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
9544         the spilllocations to be compared correctly
9545
9546 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
9547
9548         * src/SDCCast.c (decorateType): fixed bug introduced today
9549
9550 2004-01-12  Borut Razem <borut.razem AT siol.net>
9551
9552         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
9553         doc/sdccman.lyx: upper case pragmas are deprecated
9554
9555 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
9556
9557         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
9558         in simpler and even better code
9559
9560 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
9561
9562         * src/SDCCicode.c (operandOperation): fixed bug #874819
9563         * src/SDCCast.c (decorateType): fixed
9564         char foo (unsigned long ul) { return ul > 0; }
9565
9566 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9567
9568         * doc/sdccman.lyx: Moved and added some sections, small changes
9569         all over. Telling LaTeX to be less strict with word spacing
9570         to better keep the right margin. Changed some notes about
9571         maintainance of the ports in section 3.2.1 - is it OK like this?
9572
9573 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
9574
9575         SDCC source changes:
9576         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
9577         convilong): modified to inform the pic16 port that builtin functions
9578         are external
9579
9580         PIC16 PORT specific changes:
9581         * src/pic16/device.c pic16_dump_equates() added,
9582         processor registers declared internally by the port are emitted in
9583         the translation as equates,
9584         * src/pic16/gen.c: inline code is passed unprocessed to the
9585         translation,
9586         * (pic16_popGetLit2): fnuction modified to take second operand as
9587         pCodeOp pointer and not as literal,
9588         * (popRegFromIdx): prefixed with pic16_,
9589         * (pic16_popCombine2): modified to receive already allocated pCode
9590         operands,
9591         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
9592         * (genFunction): initializes local stack frame and pushes on stack
9593         all the registers used by this function,
9594         * (genEndFunction): restores all registers from stack and restores
9595         stack frame,
9596         * src/pic16/glue.c (pic16emitRegularMap): various changes and
9597         improvements,
9598         * (pic16glue): changed the program startup sequence,
9599         * added new dbName code 'A' for functions placed in absolute section
9600         * src/pic16/main.c: added function attribute _naked,
9601         * added pragma 'code' to place a fnuction at an absolute address,
9602         * added command line arguments --debug-ralloc and --pcode-verbose,
9603         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
9604         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
9605         * (pic16_newpCodeOpLit2): modified to take the second operand as
9606         pCodeOp pointer,
9607         * (pic16_printpBlock): modified to emit each function in a separate
9608         section,
9609         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
9610         UPPER for immediate operands,
9611         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
9612         instruction,
9613         * src/pic16/peeph.def: all peepholes with movff are commented out,
9614         because there is a problem in the pcode peep optimizer,
9615         * src/pic16/ralloc.c: the register allocator can now reuse local
9616         function symbols for another function. This saves register usage.
9617         * src/pic16/ralloc.h: added flag isLocal in structure regs,
9618
9619         Added file src/pic16/NOTES with information about program writing on
9620         the current port version.
9621
9622 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9623
9624         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
9625         and peephole 252 (array access)
9626
9627 2004-01-09  Borut Razem <borut.razem AT siol.net>
9628
9629         * src/SDCCmain.c : fixed #872250: -l command line defined library
9630           files are scanned before standard library files
9631
9632 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9633
9634         * src/SDCCast.c (decorateType): fixed bug #874046
9635
9636 2004-01-09  Borut Razem <borut.razem AT siol.net>
9637
9638         * support/scripts/sdcc.nsi: remove previous installation
9639
9640 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9641
9642         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
9643         bytes for last interrupt vector (mcs51)
9644         * sdcc.spec: fixed typo
9645
9646 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9647
9648         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
9649         gen51Code): more efficient parameter receive for --model-large
9650         ("bug" #845294)
9651
9652 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9653
9654         * src/ds390/main.c,
9655         * src/z80/main.c: added missed needLinkerScript flags (more than
9656         one port structure defined in these file)
9657         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
9658         bug #795325
9659
9660 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
9661
9662         * src/SDCCmain.c: removed various references to DEFAULT_PORT
9663         * src/port.h: added flag needLinkerScript in port->linker
9664         structure to inform whether to create a .lnk file or not,
9665         * src/avr/main.c,
9666         * src/ds390/main.c,
9667         * src/hc08/main.c,
9668         * src/mcs51/main.c,
9669         * src/pic/main.c,
9670         * src/pic16/main.c,
9671         * src/xa51/main.c,
9672         * src/z80/main.c: changed appropriately to configure
9673         needLinkerScript flag
9674         * src/pic/gen.c,
9675         * src/pic16/gen.c (genAddrOf): fixed bug #863624
9676         * src/pic/glue.c: added variable udata_section_name to
9677         override default uninitialized data segment definition for
9678         devices only with SHAREBANK memory (reported from Erik Epetrich)
9679         * (pic14emitOverlay): modified to emit a commented overlay segment
9680         directive when no overlay data exist
9681         * (picglue): modified to emit uninitialized data segment
9682         according to udata_section_name
9683         * src/pic/main.c (_pic14_parseOptions): added command line
9684         options --udata-section-name=[name] to override default
9685         udata definition name
9686         * modified _linkCmd and _asmCmd to include compiler passed
9687         arguments via -W option
9688         * src/pic16/main.c: added $l in _asmCmd, changed extension for
9689         object file from '.rel' to '.o' in port->linker structure,
9690         changed size of fptr from 2 to 3 in port structure
9691
9692 2004-01-07  Borut Razem <borut.razem AT siol.net>
9693
9694         * support/scripts/sdcc.nsi: update PATH
9695         * support/scripts/sdcc.ico: craeted
9696
9697 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
9698
9699         * device/include/Makefile.in: fix install
9700         * doc/Makefile: fix install
9701
9702 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9703
9704         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
9705         in bug #860505
9706         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
9707         how the function variable allocation summary is displayed; also
9708         include information about variables allocated to the overlay
9709         segment
9710
9711 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9712
9713         * as/mcs51/lkmain.c: Help about -Y option
9714         * as/mcs51/lkarea.c: Fixed gcc warnings
9715
9716 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
9717
9718         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
9719         fixed warning
9720         * support/valdiag/tests/overflow.c: added
9721         * src/SDCCast.c (decorateType),
9722         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
9723         LEFT_OP (left shift)
9724
9725 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9726
9727         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
9728         (default behaviour).
9729
9730 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9731
9732         A python script to validate compiler diagnostic messages. It can be
9733         used to verify that sdcc complains about bad c source code and
9734         gives a good location of the error.
9735         * support/valdiag/Makefile,
9736         * support/valdiag/valdiag.py,
9737         * support/valdiag/tests/*
9738
9739 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9740
9741         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
9742         * src/SDCCsymt.c (newEnumType),
9743         * src/SDCCsymt.h
9744         * support/Util/SDCCerr.c,
9745         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
9746         enum related bugs.
9747         * support/regression/tests/enum.c: added test for enum values that
9748         require at least 2 bytes of storage.
9749
9750 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
9751
9752         * src/common.h: added ifndef/define/endif macros
9753         around the header file.
9754         Bug reported from Jesus Calvino-Fraga
9755
9756 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
9757
9758         * sdcc.spec: updated
9759         * device/include/Makefile.in: don't install CVS directories
9760         * device/lib/Makefile.in: added removal of CVS directories after install
9761         * doc/Makefile: fixed install, added local_icons
9762         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
9763         * src/mcs51/gen.c (genRightShift): fixed bug #870788
9764         * src/ds390/gen.c (genRightShift): fixed bug #870788
9765         * src/SDCCast.c (decorateType): fixed bug #870781
9766
9767 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
9768
9769         PIC16 port related changes:
9770         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
9771         added variable stackPos,
9772
9773         * gen.c: genCall, assignResultValue: added support for
9774         pushing/retrieving function parameters to/from stack,
9775         genFunction,genEndFunction: setup stack frame for the
9776         generated function,
9777         genAddrOf: will be changed according to bug 863624
9778
9779         * added files genutils.c and genutils.h which contain gen*
9780         debugged and optimised functions extracted from gen.c
9781
9782         * glue.c: added variable 'externs' which holds extern symbols,
9783         pic16emitRegularMap: is modified to properly handle relocatable
9784          symbols under the new scheme,
9785         pic16createInterruptVect: is modified
9786         pic16printPublics: is modified to emit 'global' assembler directives,
9787         added pic16_printExterns to print extern symbols,
9788         pic16glue: initializes stack/frame pointer in the beginning of
9789         the assembly output. Temporary hack, will be corrected later,
9790         because gplink yet does not support stack and SDCC does not
9791         yet support a type of crt0.o object to create the final binary.
9792
9793         * Removed many lines that contain 8051 legacy code.
9794         * The code is finally placed under a 'code' directive.
9795         * Added port specific options.
9796
9797         * _process_pragma: simplified since now we do not need *special*
9798         include file to define SFR registers. But a separate header
9799         will be needed. This will be developed later.
9800         * _pic16_parseOptions: added, parses port specific options:
9801         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
9802         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
9803         --preplace-udata-with=
9804
9805         * _pic16_setDefaultOptions: modified to initialize section names,
9806         but hack is temporarly out of order since it needs improvement.
9807         * _pic16_genAssemblerPreamble: configuration words are emitted by
9808         their address instead of their name. This part is incomplete and
9809         supports only the 18Fxx2 devices. Other devices will emit an error
9810         during assembly since they do not contain the same set of config
9811         registers
9812         * _pic16_genIVT: is modified,
9813
9814         * pcode.c: added definitions for some hardware registers that are needed
9815         for stack support
9816         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
9817         All PCI entries are updated. Now LFSR is supported.
9818         * Removed pic16_pciTRIS is mentioned by mdubuc in source
9819         * added pic16_newpCodeOpLit2 to support instructions with
9820         two literal arguments
9821         * pic16_pCode2str: corrected code that emits assembler instructions
9822         with two literal operands and those that have an access bit modifier
9823         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
9824         this fixes a bug which caused some labels to be lost, when an
9825         assembler directive was added, i.e. banksel,
9826         * pic16_FixRegisterBanking: improved logic that causes the insertion
9827         of bank switching,
9828         * InlineFunction: functions that are called once, are not any more
9829         inlined. This can be a port option in the future,
9830
9831         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
9832
9833         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
9834         hold the corresponding uninitialized symbols,
9835         * pic16_allocProcessorRegister: registers have explicit marked the
9836         accessBank field,
9837         * pic16_allocInternalRegister: registers are explicit marked as
9838         not used,
9839         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
9840         processing list, so bit registers were lost,
9841         *
9842
9843         * ralloc.h: added field 'accessBank' and original symbol operand
9844         in register definition,
9845         * removed the field isMapped from register definition,
9846
9847         ** Several functions have been removed from various sources:
9848         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
9849         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
9850         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
9851         pic16_assignRelocatableRegisters
9852
9853         ** others have been introduced:
9854         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
9855         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
9856
9857 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
9858
9859         * support/scripts/inc2h.pl: changed definition of BIT_AT
9860         to emit 'sbit at' instead of 'bit at'. This was a request.
9861
9862         PIC16 port related preliminary changes:
9863         * gen.c: prefixed function popRegFromString with
9864         pic16_ and all references to it corrected
9865         * pcode.c: all pic16_pc_* hardware registers prefixed
9866         with underscore (_),
9867         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
9868         * ralloc.c: newReg(): when register is REG_SFR then
9869         set address to rIdx,
9870         pic16_allocProcessorRegister(): marks register wasUsed=0
9871         pic16_writeUsedRegs(): added a call to assign processor
9872         registers via pic16_assignFixedRegisters
9873
9874 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9875
9876         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
9877         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
9878         variables in unused register banks.  Also the SSEG is placed
9879         wherever there is enough space for it, and IDATA can be anywhere
9880         in internal RAM.  For now compile using -Wl-Y[stack_size].
9881         The mem file is different for this option as well, since it
9882         makes no sense of talking about DSEG lenght.
9883
9884 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
9885
9886         * src/SDCClrange.c: fixed bug 869095 that caused segfault
9887         in certain cases, e.g. when ROM assignment, patch provided
9888         from Albert den Haan.
9889
9890 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
9891
9892         Many signedness and type propagation fixes:
9893         * src/SDCCicode.c: made geniCodeCast() static
9894         replaced SPEC_ by IS_ (cosmetic)
9895         (operandOperation): fixed div and mod operation
9896         (usualBinaryConversions): added support for promotion of char
9897         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
9898         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
9899         (geniCodeAdd): an array index will stay unsigned, even if promoted
9900         from char to int
9901         (geniCodeArray): ditto
9902         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
9903         * src/SDCCsymt.c (computeType): added more support for char;
9904         promotion of char is selectable by promoteCharToInt, fixed signedness
9905         for all cases
9906         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
9907         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
9908         * src/SDCCval (val*): replaced signedness calculation by
9909         computeType()
9910         rearranged if-branches (cosmetic)
9911         (valShift): added warning W_SHIFT_CHANGED
9912         (valCompare): fixed problem with different types
9913         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
9914         * support/regression/tests/literalop.c: added many cases
9915         * support/regression/tests/ast_constant_folding.c: changed finally to
9916         'unsigned int'
9917         * .version: new year, new version: 2.3.7
9918         * src/SDCCmain.c (main): applied patch #866468
9919         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
9920         provided by Scott Bronson
9921         * doc/sdccman.lyx: updated documentation for sdcdb
9922         updated and added chapter tips
9923
9924 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9925
9926         * src/SDCCsymt.h: missing from yesterday's commits
9927
9928 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9929
9930         * src/SDCC.y (struct_or_union_specifier),
9931         * support/Util/SDCCerr.c,
9932         * support/Util/SDCCerr.h: verify that struct & union tags are used
9933         as declared.
9934
9935 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9936
9937         * src/SDCCglobl.h: missing from yesterday's commits
9938
9939 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9940
9941         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
9942         sft_attributes, struct_declaration, parameter_declaration,
9943         type_name, start_block, declaration_list),
9944         * src/SDCC.lex (check_type): support redefinition of typedef names
9945
9946 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9947
9948         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
9949         aligned xdata arrays. Erik helped me with the if clause.
9950
9951 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9952
9953         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
9954         warning
9955
9956 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9957
9958         * src/SDCCast.h,
9959         * src/SDCCast.c (newAst_),
9960         * src/SDCCicode.h,
9961         * src/SDCCicode.c (ast2iCode, newiCode),
9962         * src/SDCCglobl.h,
9963         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
9964         expr, statement, expression_statement, selection_statement,
9965         iteration_statement, expr_opt, jump_statement): foundation for tracking
9966         sequence points
9967         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
9968         point code too)
9969
9970 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9971
9972         * support/Util/SDCCerr.c,
9973         * src/SDCCast.h,
9974         * src/SDCCast.c (createCase, createDefault, decorateType),
9975         * src/SDCClabel.c (labelUnreach),
9976         * src/SDCC.y (labeled_statement, jump_statement): More improvements
9977         to error messages.
9978         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
9979         (with thanks to Stas Sergeev)
9980         * device/include/time.h,
9981         * device/lib/time.c (CheckTime): suppress unreachable code warning
9982
9983 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9984
9985         * src/SDCCast.c (createIvalCharPtr),
9986         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
9987         bug #753752)
9988         * support/regression/tests/nullstring.c: tests for these two bugs
9989
9990 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9991
9992         * support/Util/SDCCerr.h,
9993         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
9994         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
9995         about storage class and 'at' used inside struct or union
9996         * src/SDCCBBlock.c (iCodeFromeBBlock),
9997         * src/SDCCcse.c (ifxOptimize),
9998         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
9999         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
10000         printIval, emitStaticSeg, emitOverlay),
10001         * src/SDCClabel.c (deleteIfx),
10002         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
10003         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
10004         gatherAutoInit, processParms),
10005         * support/Util/SDCCerr.h,
10006         * support/Util/SDCCerr.c (werrorfl): Support for better error location
10007         reporting for post-parse errors.
10008
10009 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10010
10011         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
10012         implicit casts via union; they don't work on big endian systems
10013         (possible fix for bug #861138)
10014
10015 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10016
10017         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
10018         * src/mcs51/main.c: fixed the fix for bug #737001
10019
10020 2003-12-15  Borut Razem <borut.razem AT siol.net>
10021
10022         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
10023
10024 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10025
10026         * support/makebin/makebin.c: put output in binary mode
10027
10028 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10029
10030         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
10031         xdata and data memory on startup. Set the environment variable
10032         SDCC_NOGENRAMCLEAR to disable this.
10033         * src/mcs51/peephole.def,
10034         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
10035         (allows non-interrupt and interrupt code to safely compete for a resource
10036         without the non-interrupt code having to disable interrupts)
10037
10038 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10039
10040         * src/SDCCicode.c (geniCodeAdd),
10041         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
10042         with valFromType if type might be a pointer and host is big endian).
10043         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
10044         types, not just integer types.
10045         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
10046         multiply defined with mismatching "at" address.
10047
10048 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10049
10050         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
10051         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
10052         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
10053         with embedded nulls (fixed bug #753752)
10054
10055 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10056
10057         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
10058         Apparently this did not see much testing (endless loop)
10059
10060 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10061
10062         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
10063
10064 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10065
10066         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
10067         gracefully handle NULL memmap pointers
10068
10069 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10070
10071         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
10072         instead of deleting the iCode when an operand is volatile
10073         * src/z80/gen.c (genDummyRead),
10074         * src/mcs51/gen.c (genDummyRead),
10075         * src/ds390/gen.c (genDummyRead),
10076         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
10077         not just IC_RIGHT
10078         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
10079         * src/SDCC.y: fixed bug #850420
10080
10081 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10082
10083         Applied z80 i/o port patch from Peter Townson and fixed some operators
10084         to better handle operands in A register.
10085         * device/include/z180.h
10086         * src/SDCC.y
10087         * src/SDCCglue.c
10088         * src/z80/gen.c
10089         * src/z80/gen.h
10090         * src/z80/main.c
10091         * src/z80/peeph-z80.def
10092         * src/z80/peeph.def
10093         * src/z80/z80.h
10094
10095 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10096
10097         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
10098
10099 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10100
10101         * device/lib/hc08/_mullong.c: Removed extra #endif
10102
10103 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10104
10105         * sim/ucsim/hc08.src/inst.cc,
10106         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
10107         carries from x to h
10108         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
10109         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
10110         * device/include/stdarg.h: fixed varargs for hc08
10111         * device/lib/Makefile.in,
10112         * device/lib/hc08/Makefile,
10113         * device/lib/hc08/_mulint.c,
10114         * device/lib/hc08/_mullong.c: fixed some endian problems
10115
10116 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10117
10118         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
10119         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
10120         * device/lib/_gptrget.c,
10121         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
10122
10123 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10124
10125         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
10126         * src/SDCCast.c (astErrors): fixed bug #846007
10127         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
10128
10129 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10130
10131         * src/SDCCast.c (decorateType): disabled a transformation I added in
10132         revision 1.188 (access to fields of a structure at an absolute address);
10133         it breaks with bitfields, extern declarations, and gcse analysis.
10134         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
10135         could be assigned through a pointer, so don't complain.
10136         * src/SDCCast.c (astErrors),
10137         * src/SDCCast.h,
10138         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
10139
10140 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
10141
10142         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
10143         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
10144         output of __config directives, since gpasm now supports them
10145         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
10146         pre-processor macro, i.e. -DMCU=p18f452
10147         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
10148         and modified to handle 'cast' icode similarly to '=' icode
10149         * src/pic16/device.h (typedef struct PIC_device): added field
10150         'extMIface' to indicate that chip has external memory interface
10151         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
10152         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
10153         18F8720
10154
10155 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10156
10157         * src/SDCC.y (pointer): fixed bug #846006
10158         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
10159         * src/SDCCast.c (decorateType): fixed bug #846009
10160         * src/ds390/peeph.def,
10161         * src/ds390/gen.c (genAnd, genOr),
10162         * src/mcs51/peeph.def,
10163         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
10164
10165 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10166
10167         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
10168         * src/SDCCdflow.c
10169         * src/SDCCcse.c
10170         * src/SDCCcse.h
10171         * src/SDCCBBlock.h
10172         * src/SDCCBBlock.c
10173
10174 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
10175
10176         fixed bug #845089
10177         * src/SDCCbitv.h,
10178         * src/SDCCbitv.c: added function to free a bitvector
10179         * src/SDCClrange.h,
10180         * src/SDCClrange.c: added function to recompute the liveranges
10181         * src/avr/ralloc.c,
10182         * src/ds390/ralloc.c,
10183         * src/hc08/ralloc.c,
10184         * src/mcs51/ralloc.c,
10185         * src/pic/ralloc.c,
10186         * src/pic16/ralloc.c,
10187         * src/xa51/ralloc.c,
10188         * src/z80/ralloc.c: recompute the liveranges after register packing
10189
10190 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
10191
10192         * src/SDCCloop.c (newInduction): fixed bug #845630
10193
10194 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10195
10196         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
10197         inadvertantly left behind from my 2003-11-12 change
10198
10199 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10200
10201         Updated headers I neglected to commit yesterday.
10202         * src/SDCClrange.h,
10203         * src/SDCCicode.h
10204
10205 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10206
10207         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
10208         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
10209         * src/SDCCopt.c (eBBlockFromiCode),
10210         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
10211         the creation of the key hash table from the sequencing so it can be used
10212         earlier (for some GCSE bug fixes still pending)
10213
10214 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10215
10216         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
10217         * support/regression/tests/addsub.c: testing genPlus shortcut
10218
10219 2003-11-15  Borut Razem <borut.razem AT siol.net>
10220
10221         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
10222
10223 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10224
10225         * src/SDCCcse.c (cseBBlock): fixed bug #527779
10226         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
10227         ordering is immaterial.
10228         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
10229
10230 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10231
10232         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
10233         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
10234         (SIGSEV) of bug #840381
10235         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
10236         unlink new file before rename if new and old filenames are the same)
10237
10238 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10239
10240         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
10241         uninitialized variables) for the mcs51. Set environment variable
10242         SDCC_GENRAMCLEAR to test.
10243         xdata initialization slightly shorter
10244
10245 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10246
10247         * src/SDCCsymt.h,
10248         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
10249         #838241 & 780691 (basicly the same bug)
10250         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
10251         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
10252
10253 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
10254
10255         * src/SDCCmain.c (linkEdit): "fix" #834252
10256
10257 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10258
10259         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
10260         * src/SDCCast.h,
10261         * src/SDCC.y: fixed bug #819403
10262
10263 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10264
10265         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
10266         the reentrant attribute.
10267         * src/hc08/gen.c (genPackBits): added missing stack readjustment
10268         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
10269         simulation
10270         * src/SDCCast.c (decorateType): fixed bug with storage class not being
10271         updated during pointer dereference; f.e. ~(((char *)1)*) was being
10272         erroneously reduced to a literal.
10273         * src/hc08/ralloc.c (packRegisters, rematStr),
10274         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
10275         some cases
10276
10277 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10278
10279         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
10280         * doc/sdccman.lyx: changed from 'article' to 'book'
10281         * doc/Makefile: readded test_suite_spec and cdbfileformat
10282
10283 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
10284
10285         * device/include/stdlib.h: include malloc.h to comply with ANSI
10286         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
10287
10288 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10289
10290         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
10291         * doc/clean.mk: also remove *.out files
10292         * doc/sdccman.lyx: some additions, larger top/bottom margins
10293
10294 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10295
10296         * src/SDCC.y: fixed bug #837365
10297         * support/regression/tests/bitopcse.c
10298         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
10299         a symbol (might be valop instead)
10300         * device/lib/Makefile.in: added errno.c to HC08SOURCES
10301         * device/lib/clean.mk: added hc08 to the cleaning list
10302
10303 2003-11-04  Borut Razem <borut.razem AT siol.net>
10304
10305         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
10306           made 2003-11-04
10307         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
10308           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
10309           malloc is declared in standard stdlib.h
10310
10311 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10312
10313         * device/lib/hc08/Makefile: need to clean .rel not .o files
10314         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
10315
10316 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10317
10318         * src/port.h,
10319         * src/hc08/main.c,
10320         * src/mcs51/main.c,
10321         * src/ds390/main.c,
10322         * src/z80/main.c,
10323         * src/avr/main.c,
10324         * src/pic/main.c,
10325         * src/pic16/main.c,
10326         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
10327         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
10328         tests (which uses the port's oclsExpense function)
10329         * src/SDCC.y,
10330         * src/SDCCast.c,
10331         * src/SDCCicode.c,
10332         * src/hc08/gen.c,
10333         * src/ds390/gen.c,
10334         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
10335
10336 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10337
10338         * src/SDCCcse.c (ifxOptimize),
10339         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
10340         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
10341         deleting the IFX iCode.
10342         * src/hc08/ralloc.c: reduced unneeded slocs
10343         * src/hc08/gen.c: fixed bug in asmopToBoolean
10344
10345 2003-11-04  Borut Razem <borut.razem AT siol.net>
10346
10347         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
10348           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
10349           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
10350           transferred to configure
10351
10352 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
10353
10354         Use headers defined in the C[++] standards:
10355         * sim/ucsim/gui.src/serio.src/fileio.cc
10356         * sim/ucsim/gui.src/serio.src/frontend.cc
10357         * sim/ucsim/gui.src/serio.src/main.cc
10358         * sim/ucsim/gui.src/serio.src/posix_signal.cc
10359         * support/Util/NewAlloc.c
10360         * as/hc08/lklibr.c
10361         * as/mcs51/lklibr.c
10362         * as/z80/aslist.c
10363         * as/z80/assym.c
10364
10365 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10366
10367         * Added MSVC projects for hc08 assembler and linker:
10368         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
10369         /as/hc08/link_hc08.dsp
10370
10371 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
10372
10373         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
10374
10375 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
10376
10377         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
10378
10379 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10380
10381         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
10382
10383 2003-10-31  Borut Razem <borut.razem AT siol.net>
10384
10385         * support/cpp2/cpplib.h,
10386           support/cpp2/cpplib.c,
10387           support/cpp2/cpplex.c,
10388           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
10389           to switch _asm block preprocessing on / off. Default is
10390           #pragma preproc_asm +
10391
10392 2003-10-31  Borut Razem <borut.razem AT siol.net>
10393
10394         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
10395           when outputting comment blocks (when executed with -C option) and
10396           _asm (SDCPP specific) blocks
10397
10398 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10399
10400         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
10401
10402 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
10403
10404         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
10405
10406 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
10407
10408         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
10409         * src/SDCCast.c (decorateType): fixed bug #832664
10410
10411 2003-10-31  Borut Razem <borut.razem AT siol.net>
10412
10413         * support/cpp2/cpplex.c: fixed for SDCPP:
10414           comments(when executed with -C option) and _asm blocks
10415           were included even if they where in skipped #if block.
10416           Applied solution from GCC cpp 3.3.2
10417
10418 2003-10-31  Borut Razem <borut.razem AT siol.net>
10419
10420         * src/SDCC.lex: sdcc now understands both formats:
10421           '# <line_number> <file_name>' and
10422           '#line <line_number> <file_name>'
10423         * support/cpp2/cppmain.c: sdcpp now generates the standard
10424           '# <line_number> <file_name>' instead of former
10425           '#line <line_number> <file_name>'
10426
10427 2003-10-30  Borut Razem <borut.razem AT siol.net>
10428
10429         * support/cpp2/cpphash.h,
10430         * support/cpp2/cpplib.h
10431         * support/cpp2/cpplex.c,
10432         * support/cpp2/cppmain.c,
10433         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
10434
10435 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10436
10437         Fixed a number of problems revealed by bug #827883.
10438         * src/SDCCloop.c (loopInvariants): Spill location of the
10439         result operand should be recomputed if extracted from
10440         a loop. Also, don't extract assignments of an iTemp
10441         from a literal.
10442         * src/SDCCast.c (isConformingBody): loop reversal should
10443         not occur if the control variable is involved with a
10444         relational operator.
10445
10446 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
10447
10448         * .version: bumped to 2.3.6 to reflect the big improvements
10449         made by Erik and Klaus. Thanks!
10450
10451 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
10452
10453         Replaced the livrange code.
10454         * src/SDCClrange.c: added new LR code
10455         * src/SDCCloop.c,
10456         * src/SDCCBBlock.h: removed remainig parts from old LR code
10457         * src/ds390/ralloc.c,
10458         * src/ds390/gen.c: minor fixes to make it work with new code
10459
10460 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10461
10462         * as/hc08/asm.h,
10463         * as/hc08/lkrloc.c,
10464         * src/hc08/gen.c,
10465         * src/hc08/ralloc.c: Fix various warnings related to the hc08
10466         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
10467         (tweaked fix for bug #818696)
10468
10469 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10470
10471         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
10472
10473 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10474
10475         * src/SDCCmain.c,
10476         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
10477         * src/mcs51/gen.c (gencjneshort),
10478         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
10479         more efficient (per Scott Bronson's suggestion)
10480
10481 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10482
10483         Extended the semantics of the critical keyword to include
10484         individual statements. See RFE #827755 and #799831
10485         * src/SDCC.y
10486         * src/SDCCicode.c
10487         * src/SDCCopt.c
10488         * src/SDCCast.c
10489         * support/Util/SDCCerr.c
10490         * support/Util/SDCCerr.h
10491         * src/mcs51/gen.c
10492         * src/ds390/gen.c
10493         * src/hc08/gen.c
10494
10495 2003-10-19  Borut Razem <borut.razem AT siol.net>
10496
10497         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
10498
10499 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10500
10501         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
10502         Fixed bug #818696
10503         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
10504         and predecrement operand is displayed
10505
10506 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
10507
10508         * src/SDCCval.c (valMinus): fixed bug #826041
10509
10510 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10511
10512         Some hc08 related updates that I missed earlier
10513         * sim/ucsim/stypes.h
10514         * support/regression/ports/hc08/spec.mk
10515
10516 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10517
10518         New target "hc08" for the Motorola 68hc08 family of micros
10519
10520         * configure
10521         * configure.in
10522         * Makefile
10523         * src/hc08/*
10524         * src/SDCCmain.c
10525         * src/port.h
10526         * sim/ucsim/hc08.src/*
10527         * sim/ucsim/configure.in
10528         * src/ucsim/configure
10529         * sim/ucsim/packages_in.mk
10530         * as/hc08/*
10531         * as/Makefile
10532         * device/include/mc68hc908qy.h
10533         * device/lib/hc08/*
10534         * device/lib/Makefile.in
10535         * support/regression/ports/hc08/*
10536         * support/regression/Makefile
10537
10538 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10539
10540         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
10541         regression test
10542         * src/ds390/gen.c (genCast): fixed bug #821957
10543
10544 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
10545
10546         * device/lib/logf.c: "fixed" overlay bug
10547         * support/regression/ports/host/spec.mk: added m library
10548         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
10549         * support/regression/tests/float_trans: added (for Eric)
10550
10551 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
10552
10553         * src/mcs51/gen.c (genCpl): fixed bug
10554         http://sf.net/mailarchive/message.php?msg_id=6263915
10555
10556 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
10557
10558         * src/SDCCast.c (decorateType): added extended constant folding
10559         * src/SDCCsymt.c (computeType): cleanup
10560         * src/SDCCval.c (valShift): minor optimization
10561         * support/regression/tests/ast_constant_folding.c: added
10562
10563 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10564
10565         * src/SDCCmain.c: removed some unintended changes
10566
10567 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10568
10569         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
10570         * src/z80/gen.c: fixed part of bug #817589
10571         * src/SDCCsymt.c (checkFunction): fixed bug #817895
10572
10573 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
10574
10575         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
10576         * src/SDCCcflow.c
10577         * src/SDCCcse.c
10578         * src/SDCCdflow.c
10579         * src/SDCClabel.c
10580         * src/SDCClrange.c
10581         * src/SDCCmem.c
10582         * src/SDCCopt.c
10583         * src/SDCCpeeph.c
10584         * src/SDCCset.c
10585         * src/avr/ralloc.c
10586         * src/ds390/ralloc.c
10587         * src/izt/ralloc.c
10588         * src/mcs51/ralloc.c
10589         * src/pic/ralloc.c
10590         * src/pic16/ralloc.c
10591         * src/xa51/ralloc.c
10592         * src/z80/ralloc.c
10593         * src/z80/gen.c: removed unused label "release:"
10594
10595 2003-10-06  Borut Razem <borut.razem AT siol.net>
10596
10597         * src/SDCC.lex: removed definition of unused variables
10598           save_optimize and save_options
10599
10600 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
10601
10602         * clean.mk: removed '=' in "-maxdepth=1"
10603         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
10604         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
10605
10606 2003-10-06  Borut Razem <borut.razem AT siol.net>
10607
10608         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
10609           my_unput() replaced by unput()
10610
10611 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
10612
10613         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
10614         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
10615         type-punned pointer will break strict-aliasing rules"
10616         Old LR behaviour is again default; Klaus' LR can be choosen by
10617         defining the environment variable LRKLAUS
10618         * src/SDCCBBlock.h
10619         * src/SDCCloop.c
10620         * src/SDCClrange.c
10621         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
10622         * clean.mk: fixed removal of files in bin/CVS/
10623         * device/lib/clean.mk: fixed removal of directories small and large
10624         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
10625         * src/SDCCicode.c,
10626         * src/SDCCval.c: removed superflous test for pedantic
10627
10628 2003-10-05  Borut Razem <borut.razem AT siol.net>
10629
10630         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
10631           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
10632           message "unmatched #pragma SAVE and #pragma RESTORE"
10633
10634 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10635
10636         * doc/sdccman.lyx: various additions and updates (interrupts, inline
10637           assembly, critical functions, atomic, nojtbound)
10638
10639 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
10640
10641         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
10642         * src/SDCCBBlock.h
10643         * src/SDCCloop.c
10644         * src/SDCCloop.h
10645         * src/SDCClrange.c
10646
10647 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10648
10649         * src/z80/gen.h,
10650         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10651         * src/mcs51/gen.h
10652         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10653         * src/ds390/gen.h
10654         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10655         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
10656         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
10657
10658 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10659
10660         * src/z80/gen.c (genRet): fixed bug #524753
10661         * src/z80/gen.c (genCast): fixed internal error on cast from
10662         pointer to long
10663         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
10664         fix for bug #477835 to the z80
10665         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
10666         for tracking iCodes in the peephole optimizer for z80
10667
10668 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10669
10670         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
10671         the other part of bug #814548
10672         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
10673
10674 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
10675
10676         * src/SDCCcse.c: fixed part of bug #814548
10677
10678 2003-09-28  Borut Razem <borut.razem AT siol.net>
10679
10680         * src/asm.c: rewrite of printILine() to use temporary file instead
10681           a pipe
10682         * src/xa51/main.c: commented out declaration of int rewinds
10683
10684 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10685
10686         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
10687
10688 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10689
10690         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
10691         * src/asm.c (printILine): Fixed bug #811015
10692
10693 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10694
10695         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
10696         freeing.
10697
10698 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10699
10700         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
10701         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
10702         to correctly handle general case of AOP_PAIRPTR
10703         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
10704
10705 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10706
10707         * src/mcs51/ralloc.c (fillGaps),
10708         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
10709         register positioning bug)
10710
10711 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
10712
10713         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
10714
10715 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10716
10717         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
10718         genCodePointerGet, genGenPointerGet, genFarPointerSet,
10719         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
10720         (ralloc doesn't intentionally do this now, but perhaps later)
10721         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
10722         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
10723         register positioning bugs (Fixed bug #762602 and #795325)
10724         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
10725         (Fixed bug #808779)
10726         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
10727         lines that --i-code-in-asm generates
10728
10729 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10730
10731         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
10732         trying to fclose a FILE* that was already closed.
10733
10734 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10735
10736         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
10737         of const struct should be treated as if const themselves)
10738
10739 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
10740
10741         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
10742
10743 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10744
10745         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
10746         Unix (/n) and DOS (/r/n) line terminations.
10747
10748 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10749
10750         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
10751         bug #613775
10752
10753 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10754
10755         * src/mcs51/gen.c (genFunction, genEndFunction),
10756         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
10757         and restore of EA so that stack offsets to parameters are
10758         correct when using both critical and reentrant/stack-auto.
10759         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
10760         size (can be triggered in error if sloc is shared between
10761         different sized objects)
10762         * device/include/float.h: fixed macros to explicitly use
10763         unsigned long where needed
10764
10765 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
10766
10767         Feature req. 799831: added code to allow nesting of critical functions
10768         * src/mcs51/gen.c (genFunction, genEndFunction)
10769         * src/ds390/gen.c (genFunction, genEndFunction)
10770
10771 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10772
10773         * src/SDCCsymt.c (sclsFromPtr),
10774         * src/SDCCsymt.h,
10775         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
10776         support for standard C idiom of memory mapped variables; for
10777         example, *((xdata int*)0x1234) = 1 is now internally equivalent
10778         to xdata int at 0x1234 tempvar = 1.
10779         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
10780         provided by Akiya ISHIDA
10781
10782 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
10783
10784         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
10785         * src/SDCCval.c (constVal): added reduction from int to char
10786         * src/SDCCval.c (valMult, valDiv): fixed sign handling
10787         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
10788         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
10789         to ignore the sign
10790         * support/regression/tests/shifts.c: fixed
10791
10792 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10793
10794         * src/z80/gen.c (genXor): Fixed bug #805445
10795
10796 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10797
10798         Fixed bug #621531 (const & volatile confusion in the type chain).
10799         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
10800         refer to the const or volatile state of the pointer itself.
10801
10802         * src/SDCCast.c
10803         * src/SDCCglue.c
10804         * src/SDCCicode.c
10805         * src/SDCCsymt.c
10806         * src/SDCCval.c
10807         * src/SDCC.y
10808         * src/SDCCsymt.h
10809         * src/pic/gen.c
10810         * src/pic/ralloc.c
10811         * src/pic16/gen.c
10812         * src/pic16/ralloc.c
10813         * support/regression/tests/const.c
10814
10815 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10816
10817         When checking for duplicated modules, use absolute paths
10818         instead of relative paths.  Files changed:
10819
10820         * as/mcs51/lklib.c
10821         * link/z80/lklib.c
10822
10823 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10824
10825         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
10826
10827 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10828
10829         * device/include/string.h: added size_t typedef, changed
10830         prototypes to use size_t, eliminated separate reentrant and
10831         non-reentrant declarations, added _memmove declaration
10832         * device/lib/_memcpy.c: changed to use size_t instead of int,
10833         changed /4 to >>2 to avoid division library call
10834         * device/lib/_memcmp.c,
10835         * device/lib/_memset.c,
10836         * device/lib/_strncat.c,
10837         * device/lib/_strncpy.c,
10838         * device/lib/_strncmp.c: changed to use size_t instead of int
10839         * device/lib/_memmove.c: new file (fixed bug #772294)
10840         * device/lib/Makefile.in: added _memmove.c
10841         * device/lib/z80/asm_strings.s: fixed bug #772290
10842         * support/regression/tests/bitfields.c: attempt to fix host assertion
10843         failure on amd64-unknown-linux2.2
10844
10845 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10846
10847         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
10848         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
10849         * as/z80/asmain.c (main): fixed bug #801766
10850
10851 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
10852
10853         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
10854         compilers
10855
10856 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10857
10858         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
10859         reported in bug #800609
10860
10861 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
10862
10863         * Top header beautifications in src/pic16 directory:
10864           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
10865           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
10866           pcoderegs.h, ralloc.c, ralloc.h
10867         * main.c: added top header and GPL license notice
10868         * pcode.c: fixed the if-conditional warning
10869
10870 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
10871
10872         * device/lib/_mullong.c: replaced int by short for gcc
10873
10874 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10875
10876         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
10877         and JUMPTABLE iCodes properly now (worked by accident before)
10878         * src/mcs51/gen.c (leftRightUseAcc),
10879         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
10880         iCode properly now. Use getSize instead of nRegs since a & b
10881         aren't part of the nRegs tally.
10882
10883 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
10884
10885         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
10886         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
10887           before instructions that use the _STATUS register
10888
10889 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
10890
10891         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
10892         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
10893         fetching of the pointer
10894         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
10895         copied from genNearPointerSet()
10896         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
10897         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
10898         If they pop r0/r1 they must be called in the opposite order than aopOp().
10899         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
10900         (resp. --stack-auto), prepared for --xstack
10901
10902 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10903
10904         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
10905
10906 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10907
10908         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
10909         these ports have their own __sdcc_external_start()
10910
10911 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
10912
10913         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
10914         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
10915         type for bits was changed. It resulted in bit variables becoming
10916         global, which is not permitted in PIC 14 assembly output.
10917
10918 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10919
10920         * doc/sdccman.lyx: various additions and updates. Rearranged sections
10921
10922 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10923
10924         Z80 and MCS51 linkers complaint if a public symbol is defined
10925         in more than one library module:
10926
10927         * as/mcs51/lklib.c
10928         * link/z80/lklib.c
10929         * as/mcs51/Makefile.in
10930
10931 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10932
10933         A few small changes that speed up the peephole optimizer.
10934
10935         * src/SDCCpeeph.c
10936
10937 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10938
10939         Try to make the peephole optimizer smarter by maintaining
10940         an association between the assembly source code and the
10941         iCodes that originated them. Put this information to use
10942         with a new peephole rule condition "notVolatile" so that
10943         the rules can be aggressive yet still safe.
10944
10945         * src/SDCCpeeph.c
10946         * src/SDCCpeeph.h
10947         * src/mcs51/gen.c
10948         * src/mcs51/peeph.def
10949
10950 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10951
10952         Fixed bug #741761
10953
10954         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
10955         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
10956         if the left or right operand symbols have the accuse flag set.
10957
10958 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10959
10960         Changed the type of the result of the ! (NOT) operator to char;
10961         previously it returned the same type as the source. This allows
10962         us to eliminate all the genFloatNot functions (all of its target
10963         implementations were very buggy) since !float can use the same
10964         code as !long now.
10965
10966         * src/SDCCicode.c (ast2iCode): ! returns char
10967         * src/mcs51/gen.c (genNot, genNotFloat),
10968         * src/ds390/gen.c (genNot, genNotFloat),
10969         * src/z80/gen.c (genNot, genNotFloat),
10970         * src/pic/gen.c (genNot, genNotFloat),
10971         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
10972
10973 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
10974
10975         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
10976         1. Interrupt would not compile properly. Ensure PCLATH register is saved
10977            during interrupts. Ensure WSAVE is located at a shared bank address.
10978         2. Fixed page selection in some places
10979         3. Fixed BTFSS/C to where necessary use registers directly and not simply
10980            the registers name strings.
10981         4. Fixed "signed / unsigned compare" compiler warnings.
10982         5. The PIC port manages its own allocation of the general purpose
10983            registers, but makes no attempt to reuse them. As a result when
10984            compiling it soon runs out of general purpose registers. Some
10985            additional code was added to the files pcode.c and device.c to walk
10986            through the function call tree and rename the registers so that they
10987            get reused.
10988
10989         * src/pic/device.c
10990         * src/pic/gen.c
10991         * src/pic/glue.c
10992         * src/pic/pcode.c
10993         * src/pic/pcode.h
10994         * src/pic/ralloc.c
10995         * src/pic/ralloc.h
10996         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
10997         genPlus() & genMinus() when the result is the same as left or right
10998
10999 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11000
11001         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
11002
11003 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11004
11005         Made bitfield a distinct type from bit so that bitfields
11006         convert as per ANSI C and bits retain their traditional
11007         boolean style behaviour. Implemented bitfield support in
11008         the z80 port.
11009
11010         * src/SDCCsymt.h,
11011         * src/SDCCsymt.c,
11012         * src/SDCCast.c,
11013         * src/cdbFile.c,
11014         * src/mcs51/gen.c,
11015         * src/ds390/gen.c: bit v bitfield split
11016         * src/z80/gen.c: New support for bitfields
11017         * support/regression/tests/bitfields.c: reenabled z80,
11018         added more tests
11019
11020 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11021
11022         Rules 246.x, 247.x relate to bitfields, the others speed up
11023         access to xdata mapped I/O devices.
11024
11025         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
11026
11027 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11028
11029         Cleaned up genPackBits and genUnpackBits and added two helper
11030         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
11031         for literal assignments in genPackBits (thanks to Frieder for
11032         reminding me).
11033
11034         * src/mcs51/gen.c
11035         * src/ds390/gen.c
11036
11037 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11038
11039         Fixed bug #748310 (pointer to function type mishandled when the
11040         function name is omitted). Also fixed a SIGSEGV when a function
11041         attribute (reentrant, etc) is used on a non-function or on a
11042         function but misplaced before the parameter list.
11043
11044         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
11045         bug #748310
11046         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
11047         * support/Util/SDCCerr.h,
11048         * support/Util/SDCCerr.c: Added func attr misuse error msg
11049
11050 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
11051
11052         Fixed bug #787649 by anonymous
11053         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
11054         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
11055
11056 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11057
11058         Fixed numerous bitfield problems.
11059
11060         * src/SDCC.y: More bitfield related error checking
11061         * src/SDCCsymt.h,
11062         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
11063         * support/Util/SDCCerr.h,
11064         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
11065         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
11066         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
11067         * support/regression/tests/bitfields.c: tests added
11068
11069 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11070
11071         Made the constant following the "interrupt" keyword optional. If
11072         omitted, the function will not automatically be given an entry
11073         in the interrupt vector table (similar to #pragma NOIV, but
11074         less syntacticly kludgy). The interrupt number is also now
11075         range checked. Also fixed a bug in the high order bit example
11076         in the manual.
11077
11078         * src/SDCC.y
11079         * src/SDCCmem.c
11080         * src/SDCCglue.c
11081         * src/SDCCsymt.h
11082         * support/Util/SDCCerr.c
11083         * support/Util/SDCCerr.h
11084         * doc/sdccman.lyx
11085
11086 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
11087
11088         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
11089         * src/SDCCicode.c (operandOperation): rewritten some ops
11090         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
11091         * src/SDCCsymt.c (computeType): literals are handled the same way as any
11092         other type
11093         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
11094         be re-activated by defining REDUCE_LITERALS)
11095         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
11096         unsigned, but are signed by default
11097         * src/SDCCval.c (constVal): rearranged
11098         * src/SDCCval.c (valMod): preliminary fix
11099         * src/SDCCval.c (valCastLiteral): use TYPE_* types
11100         * support/regression/literalop.c: added, work in progress
11101
11102 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11103
11104         Generate warnings for useless declarations like "char data;"
11105         that don't do what new users expect.
11106
11107         * src/SDCC.y
11108         * support/Util/SDCCerr.h
11109         * support/Util/SDCCerr.c
11110
11111 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
11112
11113         * src/SDCCval.c (valMult): fix overflow detection of negative int
11114
11115 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11116
11117         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
11118
11119         Changes to support big endian targets:
11120
11121         * src/ports.h
11122         * src/SDCCglue.c
11123         * src/avr/main.c
11124         * src/ds390/main.c
11125         * src/izt/i186.c
11126         * src/mcs51/main.c
11127         * src/pic/main.c
11128         * src/pic16/main.c
11129         * src/xa51/main.c
11130         * src/z80/main.c
11131
11132 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
11133
11134         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
11135         * device/lib/time.c: fixed warning "integer overflow in expression"
11136
11137 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
11138
11139         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
11140         * src/SDCCval.c (constVal): changed default to signed; hex and octal
11141         constants are unsigned; added recognition of "u" flag for unsigned
11142         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
11143         * src/SDCCval.c (valDiv, valMod): fixed signdness
11144         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
11145         signedness of modulo, left and right shift
11146         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
11147         * support/Util/SDCCerr.h: added warning W_INT_OVL
11148         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
11149         * src/SDCCast.c (ast_print): improved output of constants
11150
11151 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11152
11153         Fixed some warnings when building with MSVC:
11154
11155         * as/mcs51/asdata.c
11156         * as/z80/asdata.c
11157         * as/mcs51/asm.h
11158         * as/z80/asm.h
11159         * link/z80/aslink.h
11160         * link/z80/lkdata.c
11161         * link/z80/lkeval.c
11162         * link/z80/lkgb.c
11163         * link/z80/lkihx.c
11164         * link/z80/lks19.c
11165         * link/z80/lksym.c
11166         * support/cpp2/cpplib.c
11167         * src/ds390/gen.c
11168         * src/mcs51/gen.c
11169
11170 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
11171
11172         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
11173
11174 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11175
11176         * support/librarian/clean.mk: Do not remove Makefile.
11177         * support/librarian/Makefile: added.
11178
11179 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11180
11181         Added librarian to MSVC build:
11182         * all.dsp
11183         * sdcc.dsw
11184         * support/librarian/librarian.dsp
11185
11186         'configure' not needed for librarian, removed:
11187         * support/librarian/configure
11188         * support/librarian/configure.in
11189         * support/librarian/config_in.h
11190         * support/librarian/Makefile.in
11191
11192         Hopefully these ones built the librarian and the rest of sdcc properly:
11193         * Makefile
11194         * Makefile.common.in
11195
11196         Messed up 'configure', so revert to previous version:
11197         * configure
11198         * configure.in
11199
11200 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
11201
11202         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
11203         there, while the mantissa of a double is "only" 53 bits wide.
11204
11205 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11206
11207         Adding sdcclib to the build.  MSVC project coming soon.
11208         Files added/changed:
11209
11210         * support/librarian/clean.mk
11211         * support/librarian/configure
11212         * support/librarian/configure.in
11213         * support/librarian/config_in.h
11214         * support/librarian/Makefile.bcc
11215         * support/librarian/Makefile.in
11216         * support/librarian/sdcclib.c
11217         * Makefile.bcc
11218         * Makefile
11219         * Makefile.common.in
11220         * configure
11221         * configure.in
11222
11223 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11224
11225         Linker now complaints if linked modules have conflicting options, for
11226         example, one compiled using --model-large and another one compiled with
11227         --model-small.  The following files were modified:
11228
11229         * as/mcs51/asdata.c
11230         * as/mcs51/aslink.h
11231         * as/mcs51/asm.h
11232         * as/mcs51/asmain.c
11233         * as/mcs51/asout.c
11234         * as/mcs51/i51pst.c
11235         * as/mcs51/lkdata.c
11236         * as/mcs51/lklibr.c
11237         * as/mcs51/lkmain.c
11238         * as/z80/asdata.c
11239         * as/z80/asm.h
11240         * as/z80/asmain.c
11241         * as/z80/asout.c
11242         * as/z80/z80pst.c
11243         * link/z80/aslink.h
11244         * link/z80/lkdata.c
11245         * link/z80/lklibr.c
11246         * link/z80/lkmain.c
11247         * src/SDCCglue.c
11248
11249 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11250
11251         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
11252         as/mcs51/lklibr.c: Generate a warning when a library is not found.
11253
11254 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
11255
11256         * src/z80/mappings.i: fix _mul[us][int,long] entries
11257
11258 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11259
11260         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
11261
11262 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
11263
11264         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
11265         * support/regression/tests/bitopcse.c: added
11266         fixed warning:
11267         * src/avr/gen.c:
11268         * src/pic/gen.c:
11269         * src/pic16/gen.c:
11270         * src/z80/gen.c:
11271         * src/xa51/gen.c:
11272
11273 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11274
11275         added support for new library format to z80, gbz80 linkers:
11276         *link/z80/aslink.h
11277         *link/z80/lklex.c
11278         *link/z80/lklib.c
11279         *link/z80/lklist.c
11280
11281 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
11282
11283         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
11284         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
11285
11286 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
11287
11288         added DUMMY_READ_VOLATILE:
11289         * src/SDCC.y:
11290         * src/avr/gen.c:
11291         * src/xa51/gen.c:
11292         * src/z80/gen.c:
11293         * src/pic/gen.c:
11294         * src/pic16/gen.c:
11295         * src/mcs51/gen.c:
11296         * src/ds390/gen.c:
11297         * src/SDCCcse.c (algebraicOpts): many improvements
11298         * src/SDCCcse.h: removed algebraicOpts()
11299         * src/SDCCicode.c (picDummyRead): added
11300
11301 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11302
11303         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
11304         "Insufficient space in data memory".
11305
11306 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11307
11308         * src/mcs51/gen.c: fixed bug #771358
11309         * src/z80/gen.c: fixed bug #759087
11310
11311 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
11312
11313         * src/pic16/glue.c: minor cleanup by Vangelis
11314
11315 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11316
11317         * device/include/regc515c.h: fixed #758477
11318         * device/lib/_gptrget.c: saving some cycles in generic pointer get
11319         * device/lib/_gptrput.c: saved a few bytes
11320         * my tab spacing is 8, yours too?)
11321         * device/lib/_ser.c: process RX bytes earlier than TX bytes
11322         * device/lib/serial.c: process RX bytes earlier than TX bytes
11323         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
11324
11325 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11326
11327         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
11328
11329 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11330
11331     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
11332
11333 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
11334
11335         * device/lib/Makefile.in: bad fix, reverted to 1.43
11336
11337 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
11338
11339         * device/lib/Makefile.in: added missing z80 object files
11340
11341 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
11342
11343         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
11344         pic16 progress by Vangelis:
11345         * src/SDCCglobl.h:
11346         * src/SDCCmain.c:
11347         * src/pic/Makefile:
11348         * src/pic:
11349         * pic/Makefile:
11350         * pic16/device.c:
11351         * pic16/device.h:
11352         * pic16/gen.c:
11353         * pic16/gen.h:
11354         * pic16/genarith.c:
11355         * pic16/glue.c:
11356         * pic16/main.c:
11357         * pic16/pcode.c:
11358         * pic16/pcode.h:
11359         * pic16/pcodepeep.c:
11360         * pic16/peeph.def:
11361
11362 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11363
11364     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
11365
11366 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11367
11368     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
11369     added gbz80 build to MSVC project.
11370     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
11371     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
11372     from 8051 stuff and setup so it links using a .lnk file.
11373
11374 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11375
11376     * support/librarian/sdcclib.c: sdcc librarian.
11377     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
11378     with sdcclib.
11379
11380 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11381
11382     * as/mcs51/lkmain.c: properly handle extensions in function afile.
11383
11384 2003-07-02  Borut Razem <borut.razem AT siol.net>
11385
11386         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
11387         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
11388         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
11389         src/xa51/main.c, src/z80/main.c:
11390         virtualization of glue() function: each port has it's own glue function,
11391         which is accessed by do_glue function pointer in PORT.general structure
11392
11393 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
11394
11395         * DS800C400 fun, improved ROM interface and tinibios.
11396
11397 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
11398
11399         * More support for DS80C400. Now includes beginning of interface to ROM.
11400
11401 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
11402
11403         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
11404
11405 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11406
11407         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
11408
11409 2003-06-19  Borut Razem <borut.razem AT siol.net>
11410
11411         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
11412
11413 2003-06-19  Borut Razem <borut.razem AT siol.net>
11414
11415         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
11416         fixed Z80 port - crt0.o: cannot open.
11417
11418 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
11419
11420         * support/Util/MySystem.c (merge_command): revert bad fix
11421
11422 2003-06-18  Borut Razem <borut.razem AT siol.net>
11423
11424         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
11425
11426 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11427
11428         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
11429         option --use-stdout sends errors to stdout instead of stderr.
11430
11431 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
11432
11433         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
11434
11435 2003-06-15  Borut Razem <borut.razem AT siol.net>
11436
11437         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
11438         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
11439         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
11440         fixed width array of pointers replaced with sets;
11441         multiple include and lib paths ared transferred to preprocessor and linker
11442         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
11443         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
11444         fixed width array of pointers
11445         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
11446         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
11447         fixupPath(), getPathDifference()
11448         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
11449         fixed width array of pointers
11450
11451 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
11452
11453         * src/pic16/ralloc.c: fix warnings
11454         * src/pic16/pcode.c: fix warning
11455
11456 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
11457
11458          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
11459         know all the details, but essentially this set of changes enable
11460         the pic16 port to generate movff instructions and generate assembler
11461         directives,
11462         * src/SDCCmain.c:
11463         * src/pic16/gen.c:
11464         * src/pic16/glue.c:
11465         * src/pic16/pcode.c:
11466         * src/pic16/device.c:
11467         * src/pic16/main.c:
11468         * src/pic16/pcode.h:
11469         * src/pic16/pcoderegs.c:
11470         * src/pic16/ralloc.c:
11471         * src/pic16/ralloc.h:
11472
11473 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11474
11475         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
11476         added option --vc, so sdcc errors and warnings are compatible with
11477         Microsoft Visual Studio.
11478
11479 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11480
11481         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
11482           device/lib/libfloat.lib: added atof function.
11483
11484 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
11485
11486         * doc/sdccman.lyx: updated to Lyx 1.3
11487         * doc/cdbfileformat.lyx: updated to Lyx 1.3
11488         * doc/test_suite_spec.lyx: updated to Lyx 1.3
11489         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
11490
11491 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
11492
11493         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
11494
11495 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11496
11497         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
11498           additions to the "related tools/documentation" section
11499
11500 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
11501
11502         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
11503
11504 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
11505
11506         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
11507         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
11508
11509 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
11510
11511         * doc/sdccman.lyx: fix double dash and other minor things
11512         * doc/Makefile: fix double dash
11513
11514 2003-05-28  Karl Bongers(patches from Martin Helmling)
11515         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
11516           condition and ignore commands.
11517
11518 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11519
11520         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
11521           is in parts still quite out of date, I did changes as far as I felt makes sense
11522           for a non-native english speaker.
11523           Please feel free to add to the manual or to correct my changes.
11524         * doc/Makefile: undid touching the date of intermediate tex files.
11525
11526 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11527
11528         * doc/sdccman.lyx: Manual has an index now
11529
11530 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
11531
11532         Finalize muluint/mulsint and mululong/mulslong merging:
11533         * device/lib/_mulint.c
11534         * device/lib/_mullong.c
11535         * device/lib/gbz80/mul.s
11536         * device/lib/gbz80/stubs.s
11537         * device/lib/z80/mul.s
11538         * device/lib/z80/stubs.s
11539         * src/SDCCsymt.c (initCSupport)
11540
11541 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11542
11543         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
11544         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
11545           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
11546           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
11547           instead of /Zm500.
11548
11549 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11550
11551         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
11552           the regression tests I'm not brave enough to enable 245.b, 245.c
11553         * doc/sdccman.lyx: added latex preamble for hyperref package.
11554           Using pdflatex this will give you a hyperlinked pdf file with
11555           bookmarks. (prepend '%' before /usepackage if this breaks something)
11556
11557 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11558
11559          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
11560
11561 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
11562
11563         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
11564
11565 2003-05-21    <johan AT balder>
11566
11567         * src/SDCCglue.c (printIval): fixed bug #739934
11568
11569 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
11570
11571         Applied patch from bug 737905 (renamed yylineo to mylineno):
11572         * src/altlex.c
11573         * src/SDCCast.c
11574         * src/SDCglobl.h
11575         * src/SDCC.lex
11576         * src/SDCCsymt.c
11577         * src/SDCCval.c
11578         * src/pic16/pcode.c: Cleaned warnings
11579         * src/pic16/pcodeflow.c: Cleaned warnings
11580         * src/pic16/pcoderegs.c: Cleaned warnings
11581
11582 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
11583
11584         * src/pic16/pcode.c: Cleaned warnings
11585         * src/pic16/pcodepeep.c: Cleaned warnings
11586         * src/pic16/ralloc.c: Cleaned warnings
11587
11588 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
11589
11590         * doc/sdccman.lyx: fixed bug 739745
11591         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
11592
11593 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
11594
11595         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
11596         it can be defined with CFLAGS when running configure
11597         * src/SDCCmain.c: fixed compiling + linking with object files
11598
11599 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
11600
11601         * configure.in: configure for pic16 port,
11602             added --disable-pic16-port
11603         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
11604         * src/SDCCmain.c: linkOptions is changed to set *,
11605             added if/endif conditional macros to remove options help
11606             messages from optionsTable when a port is not configured, added
11607             support for the PIc16 port in the ports table, when executing
11608             the compiler with no port specified on command line, a default
11609             port is selected with the new macro DEFAULT_PORT which is
11610             defined in port.h, in setDefaultOptions() linkOptions is removed
11611             from initialization assignment, since now it is a set,
11612             parseCmdLine uses setParseWithComma for linkOptions, in
11613             linkEdit() linkOptions are accessed with new function indexSet()
11614             which returns the i'th item of a set variable. See SDCCset.c, in
11615             linkEdit() when calling buildCmdLine(), added linkOptions as
11616             last argument. Now users can pass arguments to gplink via the
11617             -Wl option, main() uses pic16glue() to glue up pic16 programs
11618         * src/SDCCpeeph.c: various changes to support pic16
11619         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
11620             return the i'th item of the set
11621         * src/SDCCset.h: added function prototype for indexSet()
11622         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
11623         * src/clean.mk: added pic16 in CLEANALLPORTS variable
11624         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
11625             added macro DEFAULT_PORT
11626         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
11627         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
11628             generated
11629         * src/pic16/glue.c: commented out some error producing lines
11630         * src/pic16/main.c: __config directives are commented out to stop
11631             gpasm complaining and test the linkage with gplink, _linkCmd and
11632             _asmCmd changed to be more gplink and gpasm friendly
11633         * src/pic16/peeph.def: peep rule 3 is commented out, since it
11634             produced an error when parsed, peep rule 12 is added to utilize
11635             movff, but it is commented out since the pCode does not support
11636             yet a command with 2 address arguments
11637
11638 2003-05-18    <johan AT balder>
11639
11640         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
11641         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
11642 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
11643
11644         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
11645   Added feature to script commands from file.
11646
11647 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
11648
11649         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
11650         * src/SDCCutil.c: include ctype.h for win32
11651
11652 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
11653
11654         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
11655
11656 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
11657
11658         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
11659   Fixed so you can set breakpoints prior to run, run does not stop
11660   on entry now.  Add tbreak.  Other enhancements and fixes for use
11661   with ddd.
11662
11663 2003-05-12  Borut Razem <borut.razem AT siol.net>
11664
11665         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
11666
11667 2003-05-11  Borut Razem <borut.razem AT siol.net>
11668
11669         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
11670         the path of bin directory, so that PATH is the only env. variable, which has to be set
11671         in case of standard installation.
11672         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
11673         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
11674         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
11675
11676 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
11677
11678         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
11679         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
11680         temp files are in the port dir; clean the gen/test directory when
11681         generating new test.c
11682         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
11683         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
11684         * support/regression/tests/zeropad.c: added
11685
11686 2003-05-09    <johan AT balder>
11687
11688         * src/SDCCglue.c: fixed bug #597940
11689
11690 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
11691
11692         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
11693   cache sfr, optimize next,step, fix off by one sourceline,
11694   support ddd list function.
11695         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
11696
11697 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
11698
11699         * support/regression/HTMLgen.py: added compare_s2f()
11700         * support/regression/Makefile: redo 1.27
11701         * support/regression/generate-cases.py: redo 1.5
11702
11703 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
11704
11705         * support/regression/tests/float.c: workaround 33 bit hex constant
11706         * support/regression/tests/simplefloat.c: fix division for host
11707
11708 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
11709
11710         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
11711         that tame's the PIC's over-aggressive optimizer.
11712
11713 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11714
11715          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
11716          support for MSVC.
11717
11718 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
11719
11720         Initial support for DS80C400. "Hello world" runs on TINIm400
11721         (with polled I/O).
11722
11723 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
11724
11725          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
11726          * Some notes on ddd usage added in debugger/README
11727          Martin Helmling adding more features and fixes for ddd GUI debugger.
11728          Code added for nexti, stepi, up, down, and other adjustments.
11729
11730 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
11731
11732         * src/pic/pCodepeep.c non-wildcard asmops are now handled
11733         * src/pic/peeph.def Added two rules to optimize carry manipulation
11734         * src/pic/* removed debug printfs
11735
11736 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
11737
11738         * debugger/mcs51/cmd.c: added header newalloc.h
11739
11740 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
11741
11742         * as/Makefile: new EXEEXT
11743         * as/z80/Makefile: remove trailing slash of BUILDIR
11744         * as/z80/clean.mk: new EXEEXT
11745         * Makefile.common.in: add to CFLAGS (and others), don't replace it
11746         * support/cpp2/Makefile.in: new EXEEXT
11747         * src/pic/glue.c (pic14emitRegularMap): fixed warning
11748
11749 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
11750
11751         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
11752         EXEEXT was introduced to fix all related problems with targets
11753         "clean", "install" and "uninstall"; a couple of further flaws
11754         especially with "clean" have been fixed too
11755         * as/mcs51/Makefile.in
11756         * as/mcs51/clean.mk
11757         * as/z80/Makefile
11758         * Makefile
11759         * clean.mk
11760         * debugger/mcs51/Makefile.in
11761         * debugger/mcs51/clean.mk
11762         * link/z80/Makefile
11763         * link/z80/Makefile.in
11764         * link/z80/clean.mk
11765         * link/Makefile
11766         * packihx/Makefile.in
11767         * packihx/clean.mk
11768         * sim/ucsim/Makefile
11769         * sim/ucsim/clean.mk
11770         * sim/ucsim/avr.src/Makefile.in
11771         * sim/ucsim/avr.src/clean.mk
11772         * sim/ucsim/s51.src/Makefile.in
11773         * sim/ucsim/s51.src/clean.mk
11774         * sim/ucsim/xa.src/Makefile.in
11775         * sim/ucsim/xa.src/clean.mk
11776         * sim/ucsim/z80.src/Makefile.in
11777         * sim/ucsim/z80.src/clean.mk
11778         * sim/ucsim/main_in.mk
11779         * sim/ucsim/packages_in.mk
11780         * sim/ucsim/gui.src/Makefile.in
11781         * sim/ucsim/gui.src/serio.src/Makefile.in
11782         * sim/ucsim/gui.src/serio.src/clean.mk
11783         * src/Makefile.in
11784         * src/clean.mk
11785         * support/cpp2/Makefile.in
11786         * support/cpp2/clean.mk
11787         * support/makebin/Makefile
11788         * support/makebin/clean.mk
11789         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
11790         * doc/sdccman.lyx: --program-suffix no longer needed
11791
11792 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
11793
11794          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
11795          Martin Helmling added support for ddd GUI debugger.
11796          Code added to display assembly, set variables, and other commands
11797          to interface to ddd.
11798
11799 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
11800
11801         * as/Makefile: fix target clean
11802         * as/clean.mk: fix target clean
11803         * as/z80/clean.mk: fix target clean
11804
11805 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
11806
11807         * Makefile.common.in: added  AT EXEEXT AT
11808         * configure.in: removed all mingw32 stuff
11809         * configure: rebuilt from configure.in
11810         * doc/sdccman.lyx: updated section "installation"
11811         * support/scripts/sdcc_mingw32: adapted to configure
11812         * support/scripts/sdcc_cygwin_mingw32: added
11813
11814 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
11815
11816         * src/pic Added object file support for the PIC port
11817         * src/pic Applied patch from Craig Franklin (this started the object file support)
11818         * src/regression Updated the PIC regression tests for object files
11819
11820 2003-04-20  Borut Razem <borut.razem AT siol.net>
11821
11822         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
11823           lklex.c: In function `getfid':
11824           lklex.c:203: warning: array subscript has type `char'
11825         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
11826           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
11827         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
11828           stack handling macros
11829
11830 2003-04-19  Borut Razem <borut.razem AT siol.net>
11831
11832         * "handling space characters in file path" task:
11833         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
11834         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
11835         * support/Util/MySystem.h: make it self-sufficient
11836         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
11837           src/z80/main.c, sdcc/as/mcs51/lklex.c:
11838           handling space characters in file path
11839         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
11840           (it will be used by assemblers, which have their own includes, e.g. gpasm)
11841         * support/Util/MySystem.c: handling space characters in executable's path
11842
11843 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
11844
11845         * as/z80/Makefile: fix permanent rebuild of z80
11846         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
11847         * support/regression/tests/bitfields.c: added Johan's bitfields.c
11848
11849 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
11850
11851         * src/SDCCopt.c: add special case optimization to replace modulo by
11852           a power of two with a bitwise AND.
11853
11854 2003-04-18    <johan AT balder>
11855
11856         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
11857
11858 2003-04-17    <johan AT balder>
11859
11860         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
11861         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
11862
11863 2003-04-13  Borut Razem <borut.razem AT siol.net>
11864
11865         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
11866         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
11867           fixed mingw problem in adl_NORMALIZE_PATH
11868
11869 2003-04-12  Borut Razem <borut.razem AT siol.net>
11870
11871         * fixed "#pragma SAVE/RESTORE can not be nested":
11872         * src/SDCC.lex: reworked pragma handling functions
11873         * sdcc/src/SDCCglobl.h: reworked stack handling macros
11874         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
11875
11876 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
11877
11878         * src/SDCCutil.c (pathEquivalent): defined but not used
11879         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
11880         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
11881         * configure: rebuilt from configure.in
11882         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
11883         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
11884         * device/include/Makefile.in: replace sdcc_datadir
11885         * device/lib/Makefile.in: replace sdcc_datadir
11886         * Makefile.common.in: add LDFLAGS from configure
11887         * packihx/Makefile.in: use LDFLAGS
11888         * src/Makefile.in: use LDFLAGS
11889         * support/cpp2/Makefile.in: add LDFLAGS from configure
11890         * support/makebin/Makefile: use LDFLAGS
11891         * .version: bumped version number to 2.3.5
11892
11893 2003-04-12  Borut Razem <borut.razem AT siol.net>
11894
11895         * completed "different paths" task:
11896         * src/SDCCmacro.c: fixed bug in handling quotes
11897         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
11898         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
11899
11900 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
11901
11902         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
11903
11904 2003-04-11 kevin Vigor <kevin AT vigor.nu>
11905
11906         * ds390/gen.c ds390/peeph.def: fix bug 706781
11907
11908 2003-04-11  Borut Razem <borut.razem AT siol.net>
11909
11910         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
11911
11912 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
11913
11914         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
11915         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
11916          set - this bit used to not be set...).
11917         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
11918           bad code in PIC Port
11919         * src/regression/and2.c added to test bug 609268
11920         * src/regression/Makefile added and2.c to regression test
11921
11922
11923 2003-04-08    <johan AT CP255758-A>
11924
11925         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
11926         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
11927         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
11928
11929 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
11930
11931         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
11932         fix bug #487815
11933         * support/cpp2/Makefile.in: fix bug #487815
11934         * configure: rebuilt from configure.in
11935         * Makefile.common.in: docdir changed, new path suffixes
11936         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
11937         * sdcc_vc_in.h: reflect changes from sdccconf.h
11938         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
11939         * src/SDCCutil.h: remove BINDIR hack
11940         * doc/sdccman.lyx: update new path hierarchy
11941
11942 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11943
11944         * src/SDCCpeeph.c: added okToRemoveSLOC test
11945
11946 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11947
11948         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
11949
11950 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11951
11952         * src/SDCCpeeph.c: added labelIsReturnOnly test
11953         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
11954
11955 2003-04-05    <johan AT balder>
11956
11957         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
11958         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
11959         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
11960         * src/SDCCast.c: fixed a warning
11961         * src/SDCCast.h: fixed a warning
11962         * src/SDCCicode.c (operandFromAst): fixed a warning
11963
11964 2003-04-04    <johan AT balder>
11965
11966         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
11967         * src/SDCCast.c (decorateType): fixed bug #715076
11968         * src/SDCC.y: fixed bug #702907
11969
11970 2003-04-03    <johan AT balder>
11971
11972         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
11973         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
11974         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
11975         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
11976         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
11977
11978 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
11979
11980         * _decdptr.c: fix return values
11981         * _gptrget.c: fix return values
11982         * _gptrgetc.c: fix return values
11983         * _gptrput.c: fix return values
11984         * _mulint.c: fix return values
11985         * as/z80/Makefile: fix 'make -j' problem
11986
11987 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
11988
11989         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
11990         * configure.in: big cleanup, updated to autoconf 2.5x
11991         * configure: rebuilt from configure.in
11992         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
11993         * sdcc_vc_in.h: reflect changes from sdccconf.h
11994         * doc/Makefile: fixed a flaw in "make install"
11995
11996 2003-04-02    <johan AT balder>
11997
11998         * src/ds390/gen.c (genCmp): no comments
11999         * src/mcs51/gen.c (genCmp): no comments
12000         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
12001         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
12002
12003 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
12004
12005         * support/regression/generate-cases.py: place generated file in given sub directory
12006         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
12007         * support/regression/Makefile: improvements for 'make -j';
12008         side effect: it's simpler and faster now
12009
12010 2003-03-31  Borut Razem <borut.razem AT siol.net>
12011
12012         * src/z80/main.c: link-{port} and as-{port} defined without path
12013         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
12014
12015 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
12016
12017         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
12018
12019 2003-03-30  Borut Razem <borut.razem AT siol.net>
12020
12021         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
12022           changed type of list parameter to set
12023         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
12024         * src/port.h: changed type of do_assemble() parameter to set
12025         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
12026           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
12027           definition of "cppoutfilename" macro with NULL value in preProcess()
12028         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
12029         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
12030         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
12031           replaced with set *binPathSet
12032         * shash_add() deallocates the item, if allready exsists, before adding the new one
12033         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
12034
12035 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
12036
12037         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
12038           a nested for loop bug in the PIC port
12039         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
12040           for loops
12041
12042 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
12043
12044         * support/Util/dbuf.h: remove C++ stuff to make it portable
12045
12046 2003-03-28  Borut Razem <borut.razem AT siol.net>
12047
12048         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
12049           literal strings in stringLiteral()
12050         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
12051         * src/Makefile.bcc, src/Makefile.in, src/src.dsp: added support/Util/dbuf.c
12052           to the project
12053
12054 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
12055
12056         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
12057
12058 2003-03-26    <johan AT balder>
12059
12060         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
12061         * src/ds390/gen.c (saveRegisters): catched symbol abuse
12062         * src/SDCCast.c (decorateType): fixed " -v < 3"
12063
12064 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
12065
12066         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
12067         Added Lenny Story's debug infrastructure changes:
12068         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
12069         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
12070         * src/cdbFile.c: added
12071         * src/SDCCdebug.c: added
12072         * src/SDCCdebug.h: added
12073         * src/SDCCast.c (createFunction)
12074         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
12075         * src/SDCCmain.c (parseCmdLine, main)
12076         * src/SDCCmem.c (redoStackOffsets)
12077         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
12078         * src/SDCCsymt.h
12079         * src/common.h
12080         * src/avr/gen.c (genAVRCode)
12081         * src/ds390/gen.c (gen390Code)
12082         * src/mcs51/gen.c (gen51Code)
12083         * src/pic/gen.c (genpic14Code)
12084         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
12085         * src/xa51/gen.c (genXA51Code)
12086         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
12087
12088 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12089
12090         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
12091         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
12092
12093 2003-03-22    <johan AT balder>
12094
12095         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
12096
12097 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
12098
12099         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
12100         * doc/cdbfileformat.lyx: added, written by Lenny Story
12101         * doc/Makefile: added cdbfileformat.lyx
12102         * doc/clean.mk: added cdbfileformat.lyx
12103
12104 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
12105
12106         * src/mcs51/peeph.def: fix bug #705773
12107
12108 2003-03-20    <johan AT balder>
12109
12110         An sfr/sbit can have an "at #" AND an initializer
12111         * src/SDCCsymt.c (checkSClass):
12112         * src/SDCCmem.c (allocGlobal):
12113         * src/SDCCmem.c (allocLocal):
12114         * src/SDCCast.c (createBlock):
12115
12116 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
12117
12118         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
12119
12120 2003-03-16    <johan AT balder>
12121
12122         Undid the hackup of const and volatile, the problem is much bigger
12123         * src/SDCC.y:1.65
12124         * src/SDCCast.c:1.171
12125         * src/SDCCglue.c:1.138
12126         * src/SDCCicode.c:1.146
12127         * src/SDCCsymt.c:1.150
12128         * src/SDCCval.c:1.65
12129
12130 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
12131
12132         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
12133         * src/ds390/gen.c (genAddrOf): fixed bug #704087
12134
12135 2003-03-13    <johan AT balder>
12136
12137         Hackup const and volatile modifiers in type chains a bit:
12138         * src/SDCC.y:1.63
12139         * src/SDCCast.c:1.169
12140         * src/SDCCglue.c:1.136
12141         * src/SDCCicode.c:1.143
12142         * src/SDCCsymt.c1.146
12143         * src/SDCCsymt.h1.59
12144         * src/SDCCval.c:1.63
12145
12146 2003-03-12    <johan AT balder>
12147
12148         * src/SDCCBBlock.h: more LRH debugging junk
12149         * src/SDCCcflow.h: more LRH debugging junk
12150         * src/SDCCloop.c: more LRH debugging junk
12151         * src/SDCC.y (struct_declaration): fixed bug #697590
12152         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
12153         * src/ds390/gen.c (aopForRemat): fixed bug #700031
12154         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
12155
12156 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
12157         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
12158         test function names must now match exactly).
12159         * src/SDCCcse.c: added special case in findCheaperOp to allow
12160         extending a short integer. Makes less awful code for bug 700121 test case.
12161
12162 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12163
12164         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
12165         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
12166
12167 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
12168
12169         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
12170         actually called (operandsNotEqual() was called for all
12171         operandsNotEqualX tests).
12172
12173 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
12174
12175         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
12176         with shorter literals. Fixes bug 700121.
12177
12178 2003-03-11    <johan AT balder>
12179
12180         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
12181
12182 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
12183
12184         * src/SDCCloop.c (mergeRegions): an evil beast is dead
12185         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
12186
12187 2003-03-10  Borut Razem <borut.razem AT siol.net>
12188
12189         * src/SDCCmain.c: pipe preprocessor's output
12190         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
12191         * sdcc_vc_in.h: define pclose as _pclose for WIN32
12192         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
12193         which closes all pipes in pipeSet set
12194         * src/SDCCset.c: free deleted item in function deleteSetItem()
12195         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
12196         moved from z80 to src subproject
12197         * .version: increased version number to 2.3.4
12198
12199 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
12200
12201         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
12202         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
12203         * support/regression/ports/xa51/spec.mk: fix typo
12204
12205 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
12206
12207         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
12208
12209 2003-03-09  Borut Razem <borut.razem AT siol.net>
12210
12211         * src/SDCCmain.c: pipe preprocessor's output
12212         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
12213         * sdcc_vc_in.h: define pclose as _pclose for WIN32
12214         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
12215         which closes all pipes in pipeSet set
12216         * src/SDCCset.c: free deleted item in function deleteSetItem()
12217         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
12218         moved from z80 to src subproject
12219
12220 2003-03-09  Borut Razem <borut.razem AT siol.net>
12221
12222         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
12223         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
12224         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
12225         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
12226         * src/SDCCglobl.h: unification of WIN32 native definitions
12227
12228 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12229
12230         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
12231
12232 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
12233
12234         * src/configure.in:   check for endianess (even while cross-compiling)
12235         * src/configure:      check for endianess (even while cross-compiling)
12236         * src/configure_in.h: check for endianess (even while cross-compiling)
12237         * src/avr/gen.c:        remove old endianess stuff
12238         * src/mcs51/gen.c:      remove old endianess stuff
12239         * src/ds390/gen.c:      remove old endianess stuff
12240         * src/pic/gen.c:        remove old endianess stuff
12241         * src/pic/genarith.c:   remove old endianess stuff
12242         * src/pic/glue.c:       fix endianess check
12243         * src/pic16/gen.c:      remove old endianess stuff
12244         * src/pic16/genarith.c: remove old endianess stuff
12245         * src/pic16/glue.c:     fix endianess check
12246         * src/xa51/gen.c:       remove old endianess stuff
12247         * src/z80/gen.c:        fix endianess check
12248         * src/SDCCglue.c:       fix endianess check
12249         * src/ds390/peeph.def: fix bug 700036
12250
12251 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
12252
12253         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
12254         * src/configure: find appropriate data-types on host for SDCC's int and long
12255         * src/configure.in: find appropriate data-types on host for SDCC's int and long
12256         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
12257         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
12258
12259 2003-03-07    <johan AT balder>
12260
12261         Just a big NOOP:
12262                 some minor cleanups before the big shot
12263                 OP_DEFS and OP_USES now use Kevin's protection
12264                 new option --nolabelopt
12265
12266         * src/SDCCBBlock.c:
12267         * src/SDCCast.c,:
12268         * src/SDCCcflow.c:
12269         * src/SDCCcse.c:
12270         * src/SDCCicode.c:
12271         * src/SDCCicode.h:
12272         * src/SDCClabel.c:
12273         * src/SDCCloop.c:
12274         * src/SDCCmain.c:
12275         * src/ds390/ralloc.c:
12276         * src/mcs51/ralloc.c:
12277         * src/pic/ralloc.c:
12278         * src/xa51/ralloc.c:
12279         * src/z80/ralloc.c:
12280
12281 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
12282
12283         * src/pic/pcode.c (get_op): fix 64 bit warnings
12284         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
12285         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
12286         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
12287         * support/regression/tests/malloc.c: fix 64 bit warnings
12288
12289 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
12290
12291         * src/mcs51/gen.c (genMinus): fixed bug 696436
12292
12293 2003-03-02  Borut Razem <borut.razem AT siol.net>
12294
12295         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
12296
12297 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
12298
12299         * configure.in: test for mkstemp
12300         * sdccconf_in.h: add HAVE_MKSTEMP
12301
12302 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
12303
12304         * device/include/ctype.h: removed warning while using --stack-auto
12305         * device/include/malloc.h: removed warning while using --stack-auto
12306         * device/include/string.h: removed warning while using --stack-auto
12307
12308 2003-02-23  Borut Razem <borut.razem AT siol.net>
12309
12310         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
12311         because NDEBUG is defined (see man assert)
12312         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
12313
12314 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12315
12316         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
12317         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
12318
12319 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12320
12321         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
12322         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
12323
12324 2003-02-18    <johan AT balder>
12325
12326         * as/mcs51/asmain.c (asmbl): module can start with a digit
12327         * as/z80/asmain.c (asmbl): module can start with a digit
12328
12329 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
12330
12331         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
12332         * src/asm.c: fix pipe() for Mingw32
12333
12334 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
12335
12336         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
12337         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
12338         make -V work again; --c1mode reads now from stdin
12339         * doc/sdccman.lyx: added --c1mode
12340         * support/Util/SDCCerr.c: new messages for c1 mode
12341         * support/Util/SDCCerr.h: new messages for c1 mode
12342         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
12343
12344 2003-02-15    <johan AT balder>
12345
12346         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
12347
12348 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
12349
12350         * doc/sdccman.lyx: Environment variables, -o and other minor things
12351
12352 2003-02-14    <johan AT balder>
12353
12354         * src/xa51/main.c: before anyone really tries to use it :)
12355
12356         * Install doc's in share/sdcc/doc
12357         * removed some obsolete files
12358         * Do a proper make distclean and uninstall
12359         M Makefile.common.in
12360         R sdccbuild.sh
12361         M as/Makefile
12362         M device/include/Makefile.in
12363         M device/lib/Makefile.in
12364         M doc/sdccman.lyx
12365         M link/Makefile
12366         M sim/ucsim/doc/Makefile.in
12367         M src/clean.mk
12368         R src/avr/peeph.rul
12369         R src/xa51/peeph.rul
12370         M support/cpp2/Makefile.in
12371         M support/makebin/Makefile
12372
12373
12374 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
12375
12376         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
12377
12378 2003-02-10  Borut Razem <borut.razem AT siol.net>
12379
12380         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
12381         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
12382         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
12383         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
12384         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
12385         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
12386         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
12387         src/z80/Makefile.bcc: Borland Makefile cleanup
12388         * as/z80/Makefile.bcc: Added Borland Makefile
12389         * support/cpp2/borland.h: Removed
12390
12391 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
12392
12393         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
12394         * src/SDCC.lex: new pragma NOIV
12395         * src/SDCCglobl.h: new pragma NOIV
12396         * src/SDCCmem.c: new pragma NOIV
12397
12398 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
12399
12400         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
12401
12402 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
12403
12404         * src/SDCCmain.c: signal handling is switched off by --debug
12405         * doc/Makefile: small fix for install; use clean.mk again
12406         * doc/clean.mk: clean *.pdf and *.html too
12407
12408 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
12409
12410         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
12411         * device/lib/printfl.c: fix a ds390 bug by making it portable
12412         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
12413         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
12414         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
12415         * debugger/mcs51/cmd.c: converted multi-line string literals
12416         * sim/ucsim/globals.cc: converted multi-line string literals
12417         * src/SDCCmain.c: introduced signal handler to remove temp files
12418         * doc/Makefile: small tweaks, implement clean
12419         * doc: removed generated files
12420
12421 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12422
12423         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
12424         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
12425         Address Record is not correctly generated for DS390."
12426
12427 2003-02-02  Borut Razem <borut.razem AT siol.net>
12428
12429         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
12430         * as/mcs51/asm.h: fixed compilation with Borland C
12431         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
12432         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
12433         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
12434         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
12435         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
12436         src/z80/Makefile.bcc: delete $(LIB) only if exist
12437         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
12438
12439 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
12440
12441         * device/include/malloc.h: introduced NULL
12442         * device/include/string.h: introduced NULL
12443         * device/include/stdlib.h: introduced NULL
12444         * device/lib/_memcpy.c: removed NULL
12445         * device/lib/_strcat.c: removed NULL
12446         * device/lib/_strchr.c: removed NULL
12447         * device/lib/_strcmp.c: removed NULL
12448         * device/lib/_strcpy.c: removed NULL
12449         * device/lib/_strcspn.c: removed NULL
12450         * device/lib/_strlen.c: removed NULL
12451         * device/lib/_strncat.c: removed NULL
12452         * device/lib/_strncmp.c: removed NULL
12453         * device/lib/_strncpy.c: removed NULL
12454         * device/lib/_strpbrk.c: removed NULL
12455         * device/lib/_strrchr.c: removed NULL
12456         * device/lib/_strspn.c: removed NULL
12457         * device/lib/_strstr.c: removed NULL
12458         * device/lib/_strtok.c: removed NULL
12459         * device/lib/malloc.c: removed NULL, include own header
12460
12461 2003-02-02    <johan AT balder>
12462
12463         * 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
12464         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
12465         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
12466         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
12467         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
12468         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
12469
12470 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12471
12472         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
12473         area 'DATA'"
12474
12475 2003-02-01    <johan AT balder>
12476
12477         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
12478
12479 2003-01-31    <johan AT CP255758-A>
12480
12481         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
12482
12483 2003-01-30    <johan AT balder>
12484
12485         * src/SDCCBBlock.c: automatic bug detection
12486         * src/SDCCicode.c: automatic bug detection
12487
12488 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12489
12490         * src/SDCCglobl.h:   now --xram-size 0 works
12491         * src/SDCCmain.c:    now --xram-size 0 works
12492
12493 2003-01-29    <johan AT balder>
12494
12495         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
12496
12497 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12498
12499         * as/mcs51/aslink.h: Added options --xram-size and --code-size
12500         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
12501         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
12502         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
12503         * src/SDCCglobl.h:   Added options --xram-size and --code-size
12504         * src/SDCCmain.c:    Added options --xram-size and --code-size
12505
12506 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
12507
12508         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
12509         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
12510
12511 2003-01-27    <johan AT balder>
12512
12513         * src/SDCC.y: fixed bug #613764
12514
12515 2003-01-26    <johan AT balder>
12516
12517         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
12518         * src/SDCCsymt.h: fixed bug #673374
12519         * src/SDCCglue.c: fixed bug #661910
12520         * src/SDCCast.c: fixed bug #458099 and 673374
12521
12522 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
12523
12524         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
12525         * as/mcs51/strcmpi.h: added
12526         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
12527         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
12528         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
12529         * as/mcs51/assym.c: strcmpi -> as_strcmpi
12530         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
12531         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
12532         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
12533         * as/mcs51/Makefile.aslink: new module strcmpi
12534         * as/mcs51/Makefile.asx8051: new module strcmpi
12535         * as/mcs51/Makefil.bcc: new module strcmpi
12536         * as/mcs51/Makefile.in: new module strcmpi
12537         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
12538
12539 2003-01-26    <johan AT balder>
12540
12541         * src/SDCCglue.c: reverted back to 1.124
12542         * src/SDCCast.c: reverted back to 1.156
12543         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
12544
12545 2003-01-25    <johan AT balder>
12546
12547         * src/SDCCglue.c: A better fix for bug #661910
12548         * src/SDCCast.c: A better fix for bug #661910
12549         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
12550
12551 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
12552
12553         * src/Makefile.in: remove spawn.o
12554         * src/SDCCmain.c: remove spawn.h
12555         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
12556         * src/spawn.c: removed
12557         * src/spawn.h: removed
12558         * support/regression/ports/ds390/spec.mk: link with -r
12559
12560 2003-01-24    <johan AT CP255758-A>
12561
12562         * src/ds390/gen.c (aopOp): fixed bug #667458
12563         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
12564         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
12565         (createIvalCharPtr): an ival doesn't always have a storage class anymore
12566
12567 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
12568
12569         * src/mcs51/peeph.def: better assembler identation by Frieder
12570         * src/mcs51/gen.c: better assembler identation by Frieder
12571
12572 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
12573
12574         * as/z80/string.h: removed for gcc 3.2
12575         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
12576         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
12577
12578 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
12579
12580         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
12581         * src/SDCCpeeph.c (replaceRule): fix bug #663503
12582         * support/regression/Makefile: separate temp files for ports
12583         * support/regression/generate-cases.py: separate temp files for ports
12584         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
12585         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
12586
12587 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
12588
12589         * moved tinitalk to device/examples/ds390
12590
12591 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
12592
12593         * as/mcs51/lkmem.c: rflag is for DS390
12594         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
12595         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
12596                          (linkEdit): move mem- and map-files the same way as ihx-files
12597         * src/z80/main.c (_setDefaultOptions): removed --generic
12598         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
12599         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
12600         * src/pic/glue.c (picglue): --c1mode works again
12601         * src/pic16/glue.c (pic16glue): --c1mode works again
12602         * src/asm.c (printCLine): fix #660034
12603
12604 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
12605
12606         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
12607         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
12608         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
12609         * as/mcs51/lkmem (summary): better fix for sp problem
12610         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
12611         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
12612         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
12613                                               remove --stack-after-data
12614
12615 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
12616
12617         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
12618         * src/SDCCutil.c (join): ugly bug: missing '\0'
12619         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
12620
12621 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
12622
12623         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
12624         * src/port.h: typo
12625         * src/pic/main.c (_asmCmd): gpasm supports -o
12626         * src/z80/main.c: more general macros
12627         * device/lib/Makefile.in: remove intermediate files
12628
12629 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
12630
12631         * .version: Bumped version number to 2.3.3
12632         * src/SDCCBBlock.c: new option -o
12633         * src/SDCCglobl.h: new option -o
12634         * src/SDCCglue.c: new option -o
12635         * src/SDCCmain.c: new option -o
12636         * src/asm.c: new option -o
12637         * src/ds390/main.c: new option -o
12638         * src/pic/glue.c: new option -o
12639         * src/pic/pcode.c: new option -o
12640         * src/pic/ralloc.c: new option -o
12641         * src/pic16/glue.c: new option -o
12642         * src/pic16/pcode.c: new option -o
12643         * src/pic16/ralloc.c: new option -o
12644         * src/z80/main.c: new option -o
12645         * device/lib/Makefile.in: use -o
12646         * support/regression/ports/ds390/spec.mk: use -o
12647         * support/regression/ports/gbz80/spec.mk: use -o
12648         * support/regression/ports/mcs51/spec.mk: use -o
12649         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
12650         * support/regression/ports/z80/spec.mk: use -o
12651         * support/regression/ports/ucz80/spec.mk: use -o
12652         * support/regression/ports/xa51/spec.mk: use -o
12653         * support/regression/fwk/lib/timeout.c: fix usage string
12654
12655 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
12656         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
12657
12658 2003-01-07    <johan AT balder>
12659
12660         * src/SDCCast.c (decorateType): fixed bug #600035
12661
12662 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
12663         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
12664         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
12665         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
12666         * src/pic/pcode.c: outcommented unused variable to remove warnings
12667         * src/pic/ralloc.c: outcommented unused variable to remove warnings
12668
12669 2003-01-06    <karl AT turbobit.com>
12670         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
12671    regression tests.
12672
12673 2003-01-06    <johan AT balder>
12674
12675         * src/SDCCicode.c: fixed array add
12676
12677 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
12678         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
12679         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
12680
12681 2003-01-04    <johan AT balder>
12682
12683         * src/SDCCval.c (getNelements): fixed the initialized array of structures
12684
12685 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12686         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
12687
12688 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
12689         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
12690         * support/regression/tests/bug-524697.c: fit mem usage into 8032
12691
12692 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
12693         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
12694
12695 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
12696         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
12697
12698 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
12699         * src/mcs51/main.c: removed {bindir}{sep} from aslink
12700
12701 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12702
12703     * in /sdcc/as/mcs51/ changed these files in order to create an
12704     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
12705     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
12706     following files to include the previous two files: aslink.dsp,
12707     Makefile.aslink, Makefile.bcc, and Makefile.in.
12708
12709     * Changed /sdcc/src/SDCCmain.c so it creates files with extension
12710     .adb instead of .cdb
12711
12712 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12713
12714         * /sdcc/as/mcs51/lklist.c: Now reports memory usage using the
12715         value from option --iram-size.
12716
12717 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12718
12719         * /sdcc/as/mcs51/lklist.c: added boundary check before using
12720         dram[] array.
12721
12722 2002-09-18    <wiml AT hhhh.org>
12723
12724         * SDCClrange.h: exposed setFromRange() and setToRange()
12725         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
12726           packRegsForAccUse() (bug 542397)
12727         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
12728           multiple times and emitting the fetch operations more than once
12729           added aopGetUsesAcc() function to allow binary operators to
12730           fetch their operands in the correct order; made genMinus() emit
12731           compact code for X = LITERAL - Y
12732
12733 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12734         * /sdcc/as/mcs51/lklist.c: Fixed incorrect number of parameters to
12735         sprintf() in line 1267.
12736
12737 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12738         * /sdcc/src/SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
12739         like ports.
12740
12741 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12742         Changes to aslink (All the changes are marked with 'JCF'):
12743
12744         * /sdcc/as/mcs51/aslink.h: External definition of sflag and
12745         summary().
12746
12747         * /sdcc/as/mcs51/lkarea.c: Computes the size of area BSEG_BYTES from
12748         area BSEG.  Also moves, if possible, the DATA area down into the internal
12749         ram so more space is available.
12750
12751         * /sdcc/as/mcs51/lkdata.c: Definition of memory summary output flag
12752         sflag.
12753
12754         * /sdcc/as/mcs51/lklist.c: For the BSEG area report the size in bits,
12755         not bytes.  Function summary() which creates a memory usage summary
12756         file with extension .mem.  Reports of overlaping stack and small stack
12757         size.  If the space for the stack is less than 16 bytes aslink trows a
12758         warning.
12759
12760         * /sdcc/as/mcs51/lkmain.c: Creation of some of the default areas for
12761         the 8051.  Option 'y' for memory summary output file.
12762
12763         Changes to sdcc (All the changes are marked with 'JCF'):
12764
12765         * /sdcc/src/SDCCglobl.h: External definition of RegBankUsed[4].
12766
12767         * /sdcc/src/SDCCglue.c:  If a register bank is used, creates an
12768         overlaying area for it (uses RegBankUsed[4]).
12769
12770         * /sdcc/src/SDCCmain.c: Definition RegBankUsed[4]; marks register
12771         bank zero as used by default.  By default aslink locates the stack
12772         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
12773         the creation of the .mem file.  Delegates the allocation of data area
12774         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
12775         the begining of the stack area to aslink.
12776
12777         * /sdcc/src/SDCCmem.c:  If a register bank is used, marks it so
12778         glue() in SDCCglue.c creates an area for it.
12779
12780 2002-09-03  Borut Razem <borut.razem AT siol.net>
12781         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
12782         sdcc/src/pic/glue.c:
12783         introduced atexit() handler for teporay files removal in case of
12784         errors, assertions, ...
12785
12786 2002-08-29  Borut Razem <borut.razem AT siol.net>
12787         * sdcc/support/cpp2/auto-host_vc_in.h:
12788         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
12789         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
12790         Maybe there is a similar problem with BORLANDC? It should be checked!
12791
12792         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
12793         corrected improper use of assert: the assignment to clr variable was done inside the assert.
12794         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
12795         was not executed, and the compiler (cl) launched a warning:
12796         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
12797
12798 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
12799         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
12800
12801 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
12802         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
12803
12804         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
12805           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
12806           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
12807           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
12808           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
12809           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
12810           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
12811         - added Release configuration in VS projects
12812         - review of compiler an linker options
12813         - VC .exe files are generated in bin_vc directory, not to interfere
12814           with binaries generated from other projects (cygwin, mingw, bcc ...)
12815
12816         * sdcc/src/yacc.dsp: added
12817
12818         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
12819         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
12820         and insert the version number definitions from .version
12821
12822         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
12823
12824         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
12825         added - genarate auto-host.h using auto-host_vc_in.h as template
12826
12827         * sdcc/sdcc_vc.h,
12828         removed from CVS, generated automatically
12829
12830 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
12831         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
12832
12833 2002-08-11  Borut Razem <borut.razem AT siol.net>
12834         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
12835
12836 2002-08-10  Borut Razem <borut.razem AT siol.net>
12837         * src/SDCCmain.c (main):
12838         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
12839         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
12840         The consequence was that some temporary files were not removed.
12841
12842         * src/SDCCglue.c:
12843         unification of code in functions tempfilename() and tempfile():
12844         function tempnam() is defined in Visual Studio 6.0 and .NET
12845
12846         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
12847
12848         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
12849           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
12850         - removed compiler command line option /WX: Treats all warnings as errors
12851         - update a list of source files, included into the project
12852
12853         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
12854           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
12855         changed project type to Generic Project so that can be correcly converted to VS.NET project
12856
12857         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
12858
12859         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
12860
12861         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
12862
12863         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
12864         added return 0 statements after assert() to make compiler happy
12865
12866         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
12867         added newline in the def file to keep MSC compiler satisfied
12868
12869         * sdcc/src/z80/gen.c:
12870         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
12871           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
12872         - solved MSC error in function aopDump()
12873
12874         * sdcc_vc.h: define PREFIX as "\\sdcc"
12875
12876 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
12877         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
12878
12879 2002-06-22  Scott Dattalo <scott AT dattalo.com>
12880         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
12881         - Rewrote the register banking algorithm.
12882         - Added pCode live-range analysis to registers (for now, only non-used and
12883         singly-used registers optimized away)
12884
12885         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
12886
12887         * 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.
12888
12889 2002-05-10  Scott Dattalo <scott AT dattalo.com>
12890         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
12891
12892 2002-04-22  Michael Hope  <michaelh AT vroom>
12893
12894         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
12895
12896         * configure.in (DD_COPT): Added include support required for gbdk.
12897
12898         * .version: Bumped version number just to increase it.
12899
12900         * src/SDCCmain.c: Added -nostdinc to the default options.
12901
12902 2002-04-15  Michael Hope  <michaelh AT vroom>
12903
12904         * device/lib/z80/printf.c (sprintf): Added.
12905
12906         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
12907
12908         * src/z80/peeph.def: Added transpose redundent load rule.
12909
12910         * src/z80/main.c: Added force callee saves for jaune.
12911
12912         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
12913
12914         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
12915
12916 2002-03-28  Johan Knol  <johan AT balder>
12917
12918         * src/SDCCval.c: fixed bug #532436
12919
12920 2002-03-14  Scott Dattalo <scott AT dattalo.com>
12921         * /src/port.h:
12922         Added "char *Processor" field to the port structure.
12923
12924         * /src/SDCCmain.c:
12925         Added -p option. Allows port dependent processor to be specified.
12926
12927         * all ports:
12928         Initialized the new field char *Processor field to NULL in all ports
12929
12930         * /src/pic/*:
12931         Compiler generated registers for interrupt context saving
12932         were not getting allocated.
12933
12934 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
12935
12936         * /src/SDCCast.c:
12937         Fixed left shift. Will promote the left side of a left shift
12938         if a) left shifting more than size of operand or b) when assigned
12939         to something size > size of left side
12940
12941 2002-03-14  Scott Dattalo <scott AT dattalo.com>
12942         * src/pic/*
12943         tons of changes. Register allocation has been
12944         rewritten. Added customization for the various PICs. Flow
12945         analysis is restructured. ...
12946
12947         * src/pic/device.h:
12948         Added
12949
12950         * src/pic/device.c:
12951         Added. device.c is a PIC port hack to accomodate variations
12952         in PIC devices.
12953
12954 2002-03-13  Michael Hope  <michaelh AT vroom>
12955
12956         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
12957
12958 2002-03-04  johanknol  <johanknol AT manik>
12959
12960         * /src/SDCCval.c: fixed
12961
12962         const unsigned char arr[][2] = { { 0, 1 } };
12963         t18.c:1: error: Initializer element is not constant
12964
12965 2002-03-04  bela  <bela AT manik>
12966
12967         * /device/include/mcs51reg.h:
12968         ds89c420 register definition update
12969
12970 2002-03-03    <johan AT FRIJA>
12971
12972         * support/Util/SDCCerr.c: did something, but don't no why anymore
12973
12974         * support/regression/tests/bug-524691.c: made it a little less shy
12975
12976         * src/SDCCast.c (decorateType): fixed bug #524697
12977
12978         * src/SDCCast.c: made some lineno improvements
12979
12980         * src/SDCCval.c (getNelements): changed warning to error
12981
12982         * src/SDCCglue.c (printIvalArray): changed warning to error
12983
12984         * src/SDCCicode.c: fixed a warning for mingw
12985
12986         * src/SDCCast.c (decorateType): fixed the << promotion for ops
12987
12988         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
12989
12990 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
12991
12992         * src/ds390/peeph.def:
12993         Added some more peephole rules
12994
12995         * src/ds390/gen.c: Various fixes & enhancements
12996
12997         * src/SDCClrange.c, src/SDCClrange.h:
12998         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
12999
13000         * src/ds390/ralloc.c:
13001         various fixes & enhancements (ds390) specific
13002
13003         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
13004         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
13005         from rallocs.
13006
13007         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
13008
13009 2002-03-02    <johan AT FRIJA>
13010
13011         * src/SDCCast.c (decorateType): fixed bug #524708
13012
13013         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
13014
13015         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
13016
13017 2002-03-01  Michael Hope  <michaelh AT vroom>
13018
13019         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
13020
13021         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
13022
13023 2002-03-01    <johan AT FRIJA>
13024
13025         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
13026
13027         * src/SDCCast.c (decorateType): fixed bug #524209
13028
13029         * src/SDCCval.c (valNot): fixed bug #524195
13030
13031 2002-02-26    <johan AT balder>
13032
13033         * src/xa51/gen.c: fixed a warning
13034
13035         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
13036
13037         * src/SDCCast.c (decorateType): fixed bug #522534
13038
13039 2002-02-23    <johan AT balder>
13040
13041         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
13042
13043 2002-02-22    <johan AT balder>
13044
13045         * src/SDCCast.c: fixed bug #514865
13046
13047         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
13048
13049 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
13050
13051         * sdcc/src/SDCCloop.c:
13052         Previous fix was not good. basic blocks that have "break" or "return" are
13053         not really partof a loop , but live ranges used in these blocks should
13054         be live thru the entire loop, so set partOfLoop but don't add them to
13055         loop region
13056
13057 2002-02-21    <johan AT FRIJA>
13058
13059         * src/SDCCcse.c: fixed bug #514308
13060
13061 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
13062
13063         * src/SDCCloop.c:
13064         Fixed BUG #519583. If a conditional block ended in a return/break
13065         statement inside a loop, it was not being considered part of the loop.
13066
13067         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
13068
13069 2002-02-10  Karl Bongers <karl AT turbobit.com>
13070
13071         * debugger/*:
13072         Fixed up SDCDB debugger somewhat.  Updated debugger/README
13073         with lots of comments and notes.
13074
13075         * device/examples/test2.c:
13076         Fix bug, "red" variable not being initialized(compiler complained).
13077
13078         * device/examples/Makefile, examples/test3.c:
13079         Add Makefile in device/examples folder, compiles test3.c
13080         for use as a multiple module SDCDB test case.
13081
13082         * sim/ucsim/cmd.src/cmdset.cc:
13083         Took out debug printfs in ucsim "next" command.
13084
13085         * sim/ucsim/xa.src:
13086         Karl and Johan start ucsim XA support.  Most dissassembly working,
13087         about 75% emulation done(plenty of work remaining).
13088
13089         * sim/ucsim/z80.src:
13090         Add Z80 support to ucsim, add test-ucz80 regression test,
13091         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
13092         Notice z80 compiler fails on examples/test3.c/crc code.
13093
13094 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
13095
13096         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
13097         Added support for --parms-in-bank1
13098
13099         * src/ds390/peeph.def:
13100         added a few more peephole optimzations
13101
13102         * src/ds390/main.c:
13103         1) added __builtin_inp & __builtin_outp used to read in data of given length
13104            from a memory mapped port
13105         2) added __builtin_memcmp
13106         3) added __builtin_swapw swap bytes of a short
13107
13108         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
13109         1) handle multiple send & receives from register bank1
13110         2) ralloc can now allocate DPTR1 to some liveRanges
13111
13112         * src/SDCCsymt.c, src/SDCCsymt.h:
13113         changes to handle multiple sends & receives
13114
13115         * src/SDCCptropt.h:
13116         added some pointer arithmetic optimization
13117
13118         * src/SDCCptropt.c:
13119         added some pointer arithmetic optimizations but not stable yet so not
13120         called from anywhere (will get this working shortly)
13121
13122         * src/SDCCopt.c: fixed for multiple sends & receives
13123
13124         * src/SDCCmain.c:
13125         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
13126         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
13127            set preprocessor defines (depending on options)
13128
13129         * src/SDCCicode.c, src/SDCCicode.h:
13130         changes made to handle multiple sends & receives
13131
13132         * src/SDCCglobl.h:
13133         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
13134
13135         * src/SDCCcse.c, src/SDCCcse.h:
13136         added function findbackward def (to be used in upcoming optimization)
13137
13138         * src/SDCCcflow.c, src/SDCCcflow.h:
13139         added function returnAtEnd - to determine if a basic block terminates with
13140         a RETURN iCode
13141
13142         * src/SDCCast.c, src/SDCCast.h:
13143         added option parms-in-bank1
13144
13145         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
13146         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
13147         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
13148         adjusted for --parms-in-bank1 option
13149
13150         * device/include/string.h:
13151         donot redefine "reentrant" keyword
13152
13153         * device/include/ds80c390.h: Added some more SFRs
13154
13155 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
13156
13157         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
13158
13159 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
13160
13161         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
13162
13163 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
13164
13165         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
13166
13167 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
13168
13169         * Added --xram-movc option
13170
13171 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
13172
13173         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
13174
13175 2002-01-11  Johan Knol
13176
13177         * Added math lib of Jesus Calvino-Fraga
13178
13179 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
13180
13181         * src/SDCCmain.c (processFile): fix processing of ../../src.c
13182         * support/regression/Makefile: new target test-mcs51-stack-auto
13183         * support/regression/ports/mcs51-stack-auto/spec.mk: added
13184
13185 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
13186
13187         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
13188
13189 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
13190
13191         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
13192
13193 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
13194
13195         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
13196
13197         * src/SDCCglue.h: add definition for printIvalChar()
13198
13199 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
13200
13201         * src/SDCCast.c: fix #498138 by Johan
13202
13203         * src/SDCCglue.c: fix #498138 by Johan
13204
13205 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
13206
13207         * support/regression/Makefile: fix clean
13208
13209         * support/regression/ports/ds390/support.c: fix transmission of last character
13210
13211 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
13212
13213         * /sdcc/src/ds390/gen.c:
13214         a) improved computing address of stack variable
13215         b) took out some #if 0 code
13216         c) improved parmBytes adjustment
13217         d) improved genPlusIncr & genMinusIncr
13218         e) genCmp could generate bad code (when left assigned to DPTR)
13219         f) Fixed bug in hasInc
13220
13221         * /sdcc/src/ds390/ralloc.c:
13222         a) packRegsForSupport could mess up live information (Fixed)
13223         b) packRegsDPTRuse could be incorrect for left & right shift
13224
13225         * /sdcc/src/mcs51/ralloc.c:
13226         packRegsForSupport could mess up the live information (Fixed)
13227
13228         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
13229
13230         * /sdcc/src/SDCCast.c:
13231         can reverse a loop even if function call is present as long
13232         as the loop control variable is local & is not passed as parameter
13233
13234 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
13235
13236         * /sdcc/ChangeLog: *** empty log message ***
13237
13238         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
13239         More builtin function additions for TININative
13240
13241         * /sdcc/src/ds390/ralloc.c:
13242         Had broken the regression testsuite
13243
13244         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
13245
13246         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
13247         Added funcattr hasStackParms will be set for reentrant functions when there
13248         are paramteres on the stack, this helps in minimizing frame pointer generation
13249         typeFromStr can handle function pointers now
13250
13251         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
13252         *** empty log message ***
13253
13254 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
13255
13256         * /src/ds390/gen.c, /src/ds390/main.c:
13257         More builtin function additions for TININative
13258
13259         * /src/ds390/ralloc.c:
13260         Had broken the regression testsuite
13261
13262         * /src/SDCCast.c: Fixed a bug in dumptree
13263
13264         * /src/SDCCsymt.c, /src/SDCCsymt.h:
13265         Added funcattr hasStackParms will be set for reentrant functions when there
13266         are paramteres on the stack, this helps in minimizing frame pointer generation
13267         typeFromStr can handle function pointers now
13268
13269         * /doc/builtins.txt, /doc/TININative.txt:
13270         *** empty log message ***
13271
13272
13273 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
13274
13275         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
13276         ALPHA version for -mTININative
13277
13278         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
13279         updated to reflect changes in the port structure
13280
13281         * /src/port.h:
13282         added function do_assemble (similar to do_link) if non-null this function
13283         will be called to do assembly (-mTININative) requires a multi command
13284         assembly
13285         added function genAssemblerEnd will be called to generate assembler Epilogue
13286
13287         * /src/SDCCsymt.c:
13288         added _JavaNative to debug info printing
13289
13290         * /src/SDCCmain.c: added option --tini-libid
13291         added port->do_assemble function (-mTININative) has a multi command assemble
13292
13293         * /src/SDCCglue.c: Disabled "constExpr" check
13294         added port->genAssemblerEnd function
13295
13296         * /src/SDCCglobl.h: Added option --tini-libid value
13297
13298         * /src/SDCCast.h:
13299         tookout optimizeCompare from the header (has no external references)
13300
13301         * /src/SDCCast.c: made one more function "static"
13302
13303 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
13304
13305         * src/z80/mappings.i: Added z80asm support.
13306
13307         * src/z80/main.c: Added z80asm support on --asm=z80asm
13308
13309         * src/z80/gen.c: Fixed asm portability issues.
13310
13311         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
13312
13313         * src/SDCCglue.c (printExterns): Added global/extern split.
13314
13315 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
13316
13317         * support/regression/Makefile: added test for mcs51 model large
13318
13319         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
13320
13321         * support/regression/ports/gbz80/spec.mk: added -mgbz80
13322
13323 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
13324
13325         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
13326
13327 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
13328
13329         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
13330
13331         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
13332
13333 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
13334
13335         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
13336
13337         * support/regression/tests/simplefloat.c: Port to mcs51.
13338
13339 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
13340         * support/regression/tests/bug-485362.c: Added.
13341
13342         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
13343
13344         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
13345
13346         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
13347
13348         * src/z80/gen.c (aopDump): Added a dump function.
13349
13350 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
13351         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
13352
13353         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
13354
13355         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
13356
13357         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
13358
13359         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
13360
13361         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
13362
13363         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
13364
13365         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
13366
13367         * support/regression/ports/ds390/support.c: Use tinibios.
13368
13369         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
13370
13371 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
13372
13373         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
13374         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
13375
13376         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
13377
13378         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
13379
13380 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
13381
13382         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
13383
13384         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
13385         (packRegsForIYUse): Created and optimised.
13386
13387 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
13388
13389         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
13390 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
13391
13392         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
13393
13394         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
13395
13396         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
13397
13398 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
13399
13400         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
13401
13402         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
13403
13404 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
13405
13406         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
13407
13408         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
13409
13410         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
13411
13412 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
13413
13414         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
13415         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
13416         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
13417
13418         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
13419
13420         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
13421         (genNotFloat): Added.
13422         (genUminusFloat): Added.
13423
13424         * device/lib/z80/Makefile: Added floating pt stubs.
13425
13426         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
13427
13428         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
13429
13430         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
13431
13432 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
13433
13434         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
13435
13436         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
13437
13438         * sdcc/support/regression/Makefile: Add port ds390.
13439
13440         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
13441
13442         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
13443
13444         * sdcc/support/regression/ports/ds390/spec.mk: Added.
13445
13446         * sdcc/support/regression/ports/ds390/support.c: Added.
13447
13448         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
13449
13450         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
13451
13452         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
13453
13454 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
13455
13456         * device/include/malloc.h: Added z80 and gbz80 support.
13457
13458         * device/lib/gbz80/heap.s: Added.
13459
13460         * device/lib/z80/heap.s: Added.
13461
13462         * device/lib/malloc.c: Added z80 and gbz80 support.
13463
13464         * support/regression/tests/malloc.c (testMalloc): Added.
13465
13466         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
13467
13468         * support/regression/tests/bug-478094.c: Added.
13469
13470         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
13471
13472 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
13473
13474         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
13475
13476         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
13477
13478         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
13479
13480         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
13481
13482         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
13483
13484 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
13485
13486         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
13487
13488 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
13489
13490         * support/regression/tests/bug-477927.c: Added.
13491
13492         * src/z80/peeph.def: Added minor rules.
13493
13494         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
13495
13496         * src/z80/peeph.def: Added jump optimisation modification.
13497
13498 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
13499
13500         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
13501
13502 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
13503
13504         * support/regression/tests/funptrs.c: Added.
13505
13506 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
13507
13508         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
13509
13510 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
13511
13512         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
13513
13514         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
13515
13516         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
13517         (movLeft2ResultLong): Created.
13518
13519         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
13520         (joinPushes): Added.  Joins two char pushes into a word push.
13521
13522 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
13523
13524         * support/cpp2/Makefile.in (install): Added creation of dest dir.
13525
13526         * support/makebin/Makefile (install): Added creation of dest dir.
13527
13528 2001-10-24 Karl Bongers <karl AT turbobit.com>
13529
13530         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
13531
13532 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
13533
13534         * src/z80/ralloc.c: Turned off faulty pack for one use.
13535
13536         * src/z80/peeph-gbz80.def: Removed redundent restart options.
13537
13538         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
13539
13540 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
13541
13542         * support/regression/Makefile: Improved clean
13543
13544         * support/regression/ports/gbz80/spec.mk: Added clean
13545
13546         * support/regression/ports/host/spec.mk: Added clean
13547
13548         * support/regression/ports/z80/spec.mk: Added clean
13549
13550         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
13551
13552         * support/regression/ports/mcs51/timeout.c: little improvements
13553
13554 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
13555
13556         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
13557
13558         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
13559
13560         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
13561
13562 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
13563
13564         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
13565
13566         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
13567
13568 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
13569         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
13570
13571         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
13572
13573         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
13574
13575         * src/mcs51/main.c (_linkCmd): Added bin path to command.
13576
13577         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
13578
13579         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
13580
13581         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
13582
13583         * support/regression/tests/longor.c: Added.
13584
13585 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
13586
13587         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
13588
13589         * as/mcs51/aslink.h: define PATH_MAX
13590
13591         * as/mcs51/asm.h: define PATH_MAX
13592
13593         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
13594
13595         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
13596
13597         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
13598
13599         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
13600
13601         * src/SDCCglobl.h: define PATH_MAX
13602
13603         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
13604
13605         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
13606
13607 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
13608
13609         * src/z80/gen.c (gencjneshort): Fixed
13610
13611         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
13612
13613 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
13614
13615         * support/regression/tests/bug-469671.c: Added.
13616
13617         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
13618
13619 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
13620
13621         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
13622
13623         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
13624
13625 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
13626
13627         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
13628
13629         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
13630
13631         * src/device/lib/_mullong.c : removed hint: nooverlay bug
13632
13633         * src/device/lib/_divuint.c : removed hint: nooverlay bug
13634
13635         * src/device/lib/_divulong.c: removed hint: nooverlay bug
13636
13637         * src/device/lib/_moduint.c : removed hint: nooverlay bug
13638
13639         * src/device/lib/_modulong.c: removed hint: nooverlay bug
13640
13641 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
13642
13643         * 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.
13644
13645         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
13646
13647         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
13648
13649 2001-10-07    <johan AT FRIJA>
13650
13651         * device/lib/gets.c (gets): fixed the return value.
13652
13653 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
13654         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
13655
13656         * 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.
13657
13658         * 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.
13659
13660         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
13661
13662         * src/pic/gen.c: Removed Safe_strdup.
13663
13664         * configure.in: Added option to enable libgc support.
13665
13666         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
13667         (bitVectUnion): Optimised.
13668         (bitVectIntersect): Optimised.
13669         (bitVectBitsInCommon): Optimised.
13670         (bitVectCplAnd): Optimised.
13671
13672         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
13673
13674 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13675
13676         * src/SDCCmain.c: distinguish between assembler debug and plain options
13677
13678         * src/avr/main.c:   remove standard assembler options
13679
13680         * src/ds390/main.c: remove standard assembler options
13681
13682         * src/mcs51/main.c: remove standard assembler options
13683
13684         * src/port.h: removed "PENDING" comment
13685
13686 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13687
13688         * src/device/lib/_mulint.c  : new, with assember functions
13689
13690         * src/device/lib/_mullong.c : new, with assember functions
13691
13692         * src/device/lib/_divuint.c : with assember functions
13693
13694         * src/device/lib/_divsint.c : with assember functions
13695
13696         * src/device/lib/_divulong.c: with assember functions
13697
13698         * src/device/lib/_divslong.c: with assember functions
13699
13700         * src/device/lib/_moduint.c : with assember functions
13701
13702         * src/device/lib/_modsint.c : with assember functions
13703
13704         * src/device/lib/_modulong.c: with assember functions
13705
13706         * src/device/lib/_modslong.c: with assember functions
13707
13708         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
13709
13710         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
13711
13712         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
13713                                       replaced _mululong.c and _mulslong.c by _mullong.c
13714
13715 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13716
13717         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
13718
13719 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
13720
13721         * src/SDCCglue.c: test, if win32api is available for MINGW
13722
13723 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
13724
13725         * src/SDCCsymt.c: no more _modifier in printTypeChain()
13726         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
13727         * support/regression/ports/gbz80/spec.mk: removed GENERIC
13728         * support/regression/ports/host/spec.mk: removed GENERIC
13729         * support/regression/ports/mcs51/spec.mk: removed GENERIC
13730         * support/regression/ports/z80/spec.mk: removed GENERIC
13731
13732 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
13733
13734         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
13735
13736         * support/regression/tests/bug-467035.c: Created.
13737
13738 2001-10-01    <johan AT FRIJA>
13739
13740         * src/SDCC.y: fixed bug #466586 part 1
13741
13742 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
13743
13744         * SDCCicode.c: z80 has no generic pointers
13745         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
13746
13747 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
13748
13749         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
13750
13751 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
13752
13753         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
13754
13755         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
13756
13757 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
13758
13759         * configure.in: Fixed up so that ucsim is only configured once.
13760
13761         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
13762
13763         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
13764         (getPathDifference): As above.
13765
13766         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
13767
13768         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
13769
13770 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
13771         * .version: Updated to 2.3.1
13772
13773         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
13774         Added copyright header.
13775
13776         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
13777         (assemble): Added support for macro based assembler commands.
13778         (linkEdit): Added support for macro based linker commands.
13779         (preProcess): Changed the pre-processor to use macros.
13780         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
13781         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
13782
13783         * device/lib/z80/crt0.s: Added module name for debugging.
13784
13785 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
13786
13787         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
13788
13789         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
13790
13791         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
13792
13793         * src/Makefile.in: Added SDCCmacro and SDCCutil
13794
13795 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
13796
13797         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
13798
13799 2001-09-16    <johan AT FRIJA>
13800
13801         * 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.
13802
13803 2001-09-15    <johan AT FRIJA>
13804
13805         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
13806         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
13807
13808 2001-09-11    <johan AT FRIJA>
13809
13810         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
13811
13812 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
13813
13814         * support/regression/tests/bug-460444.c: Added test case.
13815
13816         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
13817         (genCast): Added justification for all of the asserts.
13818
13819 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
13820
13821         * support/regression/support.c: _xdata replaced by xdata
13822
13823         * support/regression/spec.mk: removed _generic
13824
13825 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
13826
13827         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
13828
13829         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
13830         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
13831
13832         * src/z80/peeph.def: Added a rule to optimise shift then compare.
13833
13834         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
13835
13836         * support/regression/tests/bug-460010.c: Added test case.
13837
13838         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
13839
13840 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
13841
13842         * support/regression/Makefile: inter-port-clean adjusted for mcs51
13843
13844         * support/regression/testfwk.c: removed workaround for bug #436344
13845
13846         * support/regression/tests/bp.c: use less memory with mcs51
13847
13848         * support/regression/tests/bug-441448.c: use less memory
13849
13850         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
13851
13852         * support/regression/collate-results.py: typo
13853
13854 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
13855
13856         * support/regression/tests/fetchoverlap.c: Added new test case.
13857
13858         * support/regression/tests/bp.c: Added new test case.
13859
13860         * support/regression/tests/bug-448984.c: Added new test case.
13861
13862         * support/regression/tests/pow2shifts.c: Added new test case.
13863
13864         * src/z80/gen.c: Turned off the noise it normally generates for the release.
13865         (genlshTwo): Fixed right shift for count > 8.
13866
13867         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
13868
13869 2001-09-08    <johan AT FRIJA>
13870
13871         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
13872
13873 2001-09-07    <johan AT FRIJA>
13874
13875         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
13876
13877         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
13878
13879 2001-09-06    <johan AT FRIJA>
13880
13881         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
13882         * bernhard noted me at this: "() equals to (void)" (1.38)
13883
13884 2001-09-05    <johan AT FRIJA>
13885
13886         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
13887
13888 2001-09-04    <johan AT FRIJA>
13889
13890         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
13891
13892
13893 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
13894
13895         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
13896
13897 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
13898
13899         * link/z80/aslink.h: Fixed path for PATH_MAX
13900
13901 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
13902
13903         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
13904
13905         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
13906
13907         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
13908
13909         * 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.
13910
13911 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
13912
13913         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
13914         (genCmp): Fixed up genCmp for the GB with longs.
13915
13916         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
13917
13918         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
13919
13920         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
13921
13922         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
13923
13924 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
13925
13926         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
13927
13928 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
13929
13930         * 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.
13931
13932         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
13933
13934 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
13935
13936         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
13937
13938         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
13939
13940 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
13941
13942   * sim/ucsim/configure:    little improvement of Cygwin-detection
13943   * sim/ucsim/configure.in: little improvement of Cygwin-detection
13944   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
13945   * support/regression/tests/bug-221100.c: small changes for mcs51
13946   * support/regression/tests/bug-221168.c: small changes for mcs51
13947   * support/regression/tests/bug-227710.c: small changes for mcs51
13948   * support/regression/tests/staticinit.c: small changes for mcs51
13949   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
13950   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
13951   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
13952
13953 $Revision$