* SDCPP synchronized with GCC CPP release version 4.1.1,
[fw/sdcc] / ChangeLog
1 2006-12-31 Borut Razem <borut.razem AT siol.net>
2
3         * SDCPP synchronized with GCC CPP release version 4.1.1,
4           currently the latest release:
5         * support/cpp2/libcpp, support/cpp2/libcpp/include,
6           support/cpp2/libcpp/include/cpp-id-data.h
7           support/cpp2/libiberty/fopen_unlocked.c
8           support/cpp2/libiberty/md5.c
9           support/cpp2/md5.h
10           support/cpp2/opt-functions.awk
11           support/cpp2/opt-gather.awk
12           support/cpp2/optc-gen.awk
13           support/cpp2/opth-gen.awk:
14           added
15         * support/cpp2/Makefile.in, support/cpp2/auto-host_vc_in.h,
16           support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
17           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
18           support/cpp2/c-pretty-print.h, support/cpp2/cppdefault.c,
19           support/cpp2/cppdefault.h, support/cpp2/diagnostic.c,
20           support/cpp2/diagnostic.h, support/cpp2/except.h,
21           support/cpp2/hwint.h, support/cpp2/input.h,
22           support/cpp2/intl.h, support/cpp2/move-if-change,
23           support/cpp2/opts.c, support/cpp2/opts.h,
24           support/cpp2/output.h, support/cpp2/prefix.c,
25           support/cpp2/prefix.h, support/cpp2/pretty-print.c,
26           support/cpp2/pretty-print.h, support/cpp2/sdcpp-opts.c,
27           support/cpp2/sdcpp.c, support/cpp2/sdcpp.dsp,
28           support/cpp2/sdcpp.h, support/cpp2/sdcpp.opt,
29           support/cpp2/sdcppa.dsp, support/cpp2/symcat.h,
30           support/cpp2/version.c:
31           modified
32         * support/cpp2/libcpp/charset.c, support/cpp2/libcpp/directives.c,
33           support/cpp2/libcpp/errors.c, support/cpp2/libcpp/expr.c,
34           support/cpp2/libcpp/files.c, support/cpp2/libcpp/identifiers.c,
35           support/cpp2/libcpp/include/cpplib.h, support/cpp2/libcpp/include/line-map.h,
36           support/cpp2/libcpp/include/mkdeps.h, support/cpp2/libcpp/include/symtab.h,
37           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
38           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/line-map.c,
39           support/cpp2/libcpp/macro.c, support/cpp2/libcpp/mkdeps.c,
40           support/cpp2/libcpp/symtab.c, support/cpp2/libcpp/system.h,
41           support/cpp2/libcpp/traditional.c, support/cpp2/libcpp/ucnid.h,
42           support/cpp2/libiberty/hashtab.c, support/cpp2/libiberty/hashtab.h:
43           moved
44         * support/cpp2/cppcharset.c, support/cpp2/cpperror.c,
45           support/cpp2/cppexp.c, support/cpp2/cppfiles.c,
46           support/cpp2/cpphash.c, support/cpp2/cpphash.h,
47           support/cpp2/cppinit.c, support/cpp2/cpplex.c,
48           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
49           support/cpp2/cppmacro.c, support/cpp2/cpptrad.c,
50           support/cpp2/cppucnid.h, support/cpp2/hashtab.c,
51           support/cpp2/hashtab.h, support/cpp2/hashtable.c,
52           support/cpp2/hashtable.h, support/cpp2/line-map.c,
53           support/cpp2/line-map.h, support/cpp2/mkdeps.c,
54           support/cpp2/mkdeps.h, support/cpp2/options_vc_in.c,
55           support/cpp2/options_vc_in.h, support/cpp2/opts.sh,
56           support/cpp2/system.h:
57           deleted / moved
58
59 2006-12-31 Borut Razem <borut.razem AT siol.net>
60
61         * configure.in, configure: fixed bug #1538756: configure dies if bison
62           and flex are not installed, 2nd try
63
64 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
65         * src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to
66         400.x for better code in RFE 899102
67
68 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
69
70         * src/SDCCpeeph.c (deadMove),
71         * src/port.h,
72         * src/mcs51/peep.h: renamed 'op' by 'reg'
73         * src/mcs51/peep.c (isFunc, isCallerSaveFunc): added,
74         (scan4op): small change for removeDeadMove(), added support for
75         'callee saves' and/or PACLL function calls,
76         (removeDeadMove): added, removes superflous 'mov r%1,%2',
77         (removeDeadPopPush): renamed from mcs51DeadMove(), common parts
78         left in new dispatcher mcs51DeadMove()
79         (mcs51DeadMove): dispatcher for removeDeadPopPush() and new
80         removeDeadMove()
81         * src/mcs51/peeph.def: added rule 301 removing superflous 'mov r%1,%2'
82
83 2006-12-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
84
85         * support/cpp2/options_vc_in.h, support/cpp2/options_vc_in.c,
86           support/cpp2/sdcppa.dsp: create 'options.h' and 'options.c' under MSVC.
87         * configure.in, configure: fixed buf #1538756: configure dies if bison
88           and flex are not installed
89
90 2006-12-30 Borut Razem <borut.razem AT siol.net>
91
92         * support/cpp2/spacs.h: deleted from svn
93         * configure.in, configure: fixed bug #1538756: configure dies if bison
94           and flex are not installed
95
96 2006-12-21 Maarten Brock <sourceforge.brock AT dse.nl>
97
98         * src/z80/gen.c (assignResultValue): fixed bug when registers overlap,
99           with this z80 passes printf float test when enabled
100         * support/regression/tests/bug1057979.c: typo disabled ds390 float test
101
102 2006-12-28 Borut Razem <borut.razem AT siol.net>
103
104         * support/cpp2/config.in, support/cpp2/configure.in,
105           support/cpp2/configure, support/cpp2/Makefile.in:
106           fix for the solaris build
107
108 2006-12-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
109
110         * src/SDCC.y (type_specifier2, pointer),
111         * src/SDCCsymt.h,
112         * src/SDCCsymt.c (mergeSpec, checkSClass),
113         * support/Util/SDCCerr.c,
114         * support/Util/SDCCerr.h: Parse and validate the restrict keyword
115         * support/valdiag/valdiag.py: Allow test cases to specify
116           required language standard
117         * support/valdiag/tests/restrict.c: New file to test restrict keyword
118         * support/valdiag/tests/tentdecl.c: Supress empty source file error
119
120 2006-12-27 Borut Razem <borut.razem AT siol.net>
121
122         * support/cpp2/cppmain.c, support/cpp2/mbchar.[ch]: removed
123         * support/cpp2/libiberty/Makefile.in, support/cpp2/libiberty/sdcpp.dsp:
124           mbchar removed
125         * support/cpp2/libiberty/getpwd.c, support/cpp2/sdcpp.h:
126           fixed for borland C
127         * support/cpp2/libiberty/Makefile.bcc: updated
128         * src/pic16/main.c: fixed #pragma udata handling
129         * src/mcs51/mcs51.dsp: added peep.[ch] to the project
130
131 2006-12-26 Bernhard Held <bernhard AT bernhardheld.de>
132
133         * src/SDCCpeeph.c: made labelHashEntry global,
134         made pcDistance, FBYNAME static,
135         (pcDistance): made static, use isComment and isLabel,
136         (deadMove): added,
137         (getLabelRef): added, extracted from labelRefCount(),
138         (labelRefCount): use new getLabelRef(),
139         (callFuncByName): made static, added deadMove,
140         use isComment and isLabel,
141         (newPeepRule): made static, set isLabel,
142         (isLabelDefinition): added parameter isPeepRule to allow '%' in
143         labels from peephole rules,
144         (buildLabelRefCountHash): speed up by running isLabelDefinition() only
145         when isComment or isLabel is set
146         * src/SDCCpeeph.h: added "isLabel" and "visited" to struct lineNode,
147         added labelHashEntry, isLabelDefinition, labelHash and getLabelRef
148         to make them global
149         * src/mcs51/peep.h: added
150         * src/mcs51/peep.c: added, implements mcs51DeadMove()
151         * src/port.h: added peep->deadMove to port structure
152         * src/mcs51/main.c: initialize peep->deadMove with mcs51DeadMove
153         * src/mcs51/peeph.def: renumbered rule 300 to 400, added new rule 300
154         deadMove, finally removed no. 1 and 2
155         * src/mcs51/gen.c,
156         * src/pic/gen.c,
157         * src/z80/gen.c,
158         * src/z80/ralloc.c,
159         * src/pic16/gen.c,
160         * src/ds390/gen.c,
161         * src/hc08/gen.c: mark lines with isComment or isLabel
162         * sim/ucsim/s51.src/uc390hw.cc: don't waist 65535 ticks before CKRDY
163         * .version,
164         * sdcc.spec: bumped version to 2.6.3
165
166 2006-12-26 Borut Razem <borut.razem AT siol.net>
167
168         * support/cpp2/Makefile.in: added dependency on options.h
169         * configure: regenerated
170         * support/cpp2/sdcpp.opt, support/cpp2/move-if-change: svn:eol-style native
171         * support/cpp2/Makefile.in: added vasprintf.c
172
173 2006-12-25 Borut Razem <borut.razem AT siol.net>
174
175         * SDCPP synchronized with GCC CPP release version 3.4.6,
176           the latest release before 4.x:
177         * support/cpp2/Makefile.in, support/cpp2/config.h,
178           support/cpp2/configure, support/cpp2/configure.in,
179           support/cpp2/cppdefault.c, support/cpp2/cppdefault.h,
180           support/cpp2/cpperror.c, support/cpp2/cppexp.c,
181           support/cpp2/cppfiles.c, support/cpp2/cpphash.c,
182           support/cpp2/cpphash.h, support/cpp2/cppinit.c,
183           support/cpp2/cpplex.c, support/cpp2/cpplib.c,
184           support/cpp2/cpplib.h, support/cpp2/cppmacro.c,
185           support/cpp2/cpptrad.c, support/cpp2/except.h,
186           support/cpp2/hashtable.c, support/cpp2/hashtable.h,
187           support/cpp2/hwint.h, support/cpp2/intl.h,
188           support/cpp2/line-map.c, support/cpp2/line-map.h,
189           support/cpp2/mkdeps.c, support/cpp2/mkdeps.h,
190           support/cpp2/output.h, support/cpp2/prefix.c,
191           support/cpp2/prefix.h, support/cpp2/sdcpp.dsp,
192           support/cpp2/system.h, support/cpp2/version.c:
193           modified
194         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
195           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
196           support/cpp2/c-pretty-print.h, support/cpp2/cppcharset.c,
197           support/cpp2/cppucnid.h, support/cpp2/diagnostic.c,
198           support/cpp2/diagnostic.def, support/cpp2/diagnostic.h,
199           support/cpp2/hashtab.c, support/cpp2/hashtab.h,
200           support/cpp2/input.h, support/cpp2/libiberty/getpwd.c,
201           support/cpp2/libiberty/vasprintf.c, support/cpp2/libiberty/xmemdup.c,
202           support/cpp2/move-if-change, support/cpp2/opts.c,
203           support/cpp2/opts.h, support/cpp2/opts.sh,
204           support/cpp2/pretty-print.c, support/cpp2/pretty-print.h,
205           support/cpp2/sdcpp.opt, support/cpp2/sdcpp-opts.c,
206           support/cpp2/win32, support/cpp2/win32/dirent.c,
207           support/cpp2/win32/dirent.h:
208           added
209         * support/cpp2/sdcpp.c: renamed from sdcppmain.c
210         * support/cpp2/sdcpp.h: renamed from sdcc.h
211         * sdcppinit.c: deleted
212
213 2006-12-23 Borut Razem <borut.razem AT siol.net>
214
215         * support/cpp2/cpphash.h, support/cpp2/cpplex.c,
216           support/cpp2/cpplib.[ch], support/cpp2/sdcppinit.c, doc/sdccman.lyx,
217           preproc.c: an other try to fix bug #982435: introduced
218           -pedantic-parse-number command line option and pedantic_parse_number
219           pragma
220
221 2006-12-21 Maarten Brock <sourceforge.brock AT dse.nl>
222
223         * as/link/mcs51/lkarea.c (lnkarea2): handle absolute areas, restructured
224            BSEG handling,
225           (lnksect2): use --data-loc and --idata-loc as lower bound for ramstart,
226            corrected overlayed areax addresses, warn about memory overlaps
227         * as/mcs51/asmain.c (asmbl): create a new area for every .org directive
228         * src/avr/main.c,
229         * src/ds390/main.c,
230         * src/hc08/main.c,
231         * src/mcs51/main.c,
232         * src/pic16/main.c,
233         * src/pic/main.c,
234         * src/xa51/main.c,
235         * src/z80/main.c,
236         * src/port.h: added xabs_name and iabs_name
237         * src/SDCCglue.c (emitRegularMap): allocate for absolutes with initializer
238           (glue, emitMaps): create and emit maps d_abs and i_abs
239         * src/SDCCglue.h: cosmetic changes
240         * src/SDCCmain.c (setDefaultOptions): idata can start below 0x80
241         * src/SDCCmem.h,
242         * src/SDCCmem.c (initMem): added x_abs, i_abs and d_abs
243           (allocDefault): put absolute, initialized globals in them
244         * support/regression/tests/absolute.c: added absolute bdata test
245         * device/lib/printf_large.c (output_float): moved fpBuffer to stack/xdata
246
247 2006-12-20 Borut Razem <borut.razem AT siol.net>
248
249         * support/cpp2/cpphash.h, support/cpp2/cpplex.c: fixed bug #982435
250         * support/regression/tests/preproc.c: renamed from bug-1351710.c,
251           added regression test for bug #982435
252
253 2006-12-18 Borut Razem <borut.razem AT siol.net>
254
255         * src/SDCCutil.c: fixed a bug in (get_pragma_token)
256         * src/pic16/main.c, src/SDCC.lex, src/z80/main.c:
257           small cosmetic changes
258         * src/SDCC.lex: (stringLiteral) fixed bug #1351710
259         * support/regression/tests/bug-1351710.c: added regression test
260
261 2006-12-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
262
263         * doc/sdccman.lyx: added the long missed iCode table
264           "<where is figure II?>", added links to wiki
265
266 2006-12-17 Borut Razem <borut.razem AT siol.net>
267
268         * doc/sdccman.lyx, src/pic16/main.c, src/pic/main.c, src/port.h,
269           src/SDCC.lex, src/SDCCutil.[ch], src/z80/main.c,
270           support/Util/SDCCerr.[ch]: removed deprecated pragmas,
271           unified table driven pragma handling, pragma argument type checking
272         * support/Util/dbuf.c: (dbuf_set_size) allow to set size equal to the
273           current one - version 1.1.3
274         * src/SDCCmain.c: (setParseWithComma) substituted brain damaged strtok
275
276 2006-12-13 Raphael Neider <rneider AT web.de>
277
278         * src/pic/device.h: removed AssignedMemory structure and macros
279         * src/pic/device.c: removed global finalMapping (linker assigns
280             memory locations),
281           (register_map): add SFRs to remembered memRanges
282           (addMemRange,isSFR,dump_map,dump_sfr,mapRegister,assignRegister,
283           assignFixedRegisters,assignRelocatableRegisters): removed,
284           (setMaxRAM,validAddress): adapted accordingly,
285           (pic14_hasSharebank,pic14_getSharedStack): only report and use
286             reasonably sized sharebanks,
287         * src/pic/ralloc.c (writeUsedRegs): stripped down (remove?),
288           (allDefsOutOfRange): removed unused code,
289         * src/pic/main.c (_process_pragma): removed memmap/maxram pragma
290             handling
291         * src/pic/pcode.c (register_reassign): removed recursion warning,
292             fired far too often,
293         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap): modified
294             to use existing pic14_stringInSet() to avoid duplicate symbols,
295             tidied up the code a bit,
296           (pic14printLocals): added in symmetry to printExterns, replaces
297             writeUsedRegs more or less,
298           (picglue): call new pic14_printLocals(),
299         * device/include/pic/pic*.h: removed #pragma memmap directives,
300             information gathered from include/pic/pic14devices.txt
301         * support/scripts/inc2h.pl: do not emit #pragma memmap lines
302
303 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
304
305         * device/include/mcs51/C8051F520.h: fixed buggy CPT0MX
306
307 2006-12-11 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
308
309         * device/include/mcs51/cc2430.h: fixed missing ';'
310
311 2006-12-10 Raphael Neider <rneider AT web.de>
312
313         * device/lib/pic16/libc/stdio/vfprintf.c,
314         * device/lib/pic16/libc/stdio/printf_small.c,
315         * device/lib/pic16/libc/stdio/printf_timy.c: pop int from stack for
316           char arguments, as char varargs are cast to int by the caller,
317           hopefully fixes #1604915 (other device libraries are still affected)
318
319 2006-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
320
321         * src/mcs51/ralloc.c (packRegsForAssign),
322         * src/hc08/ralloc.c (packRegsForAssign): fixed bug #1605880
323
324 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
325
326         * device/include/malloc.h: removed init_dynamic_memory
327         * device/lib/malloc.c: made init_dynamic_memory static and automatically
328           call it once from malloc. Also use _sdcc_heap[] from _heap.c
329         * device/lib/_heap.c: new, added, contains _sdcc_heap[]
330         * device/lib/libsdcc.lib,
331         * device/lib/Makefile.in,
332         * support/regression/ports/mcs51-xstack-auto/spec.mk: added _heap.c
333         * doc/sdccman.lyx: documented use of new _heap.c
334         * support/regression/tests/malloc.c: removed init_dynamic_memory
335         * src/cdbFile.c(spacesToUnderscores): new function,
336           (cdbWriteEndFunction, cdbWriteCLine): use spacesToUnderscores, fixes bug
337           1068030
338         * device/include/tinibios.h: removed defines for putchar and getchar
339         * device/lib/ds390/Makefile.in: added putchar.c
340         * device/lib/ds390/putchar.c: new, added, fixes bug 1465671
341
342 2006-12-09 Borut Razem <borut.razem AT siol.net>
343
344         * support/cpp2/sdcc.h: prevent multiple inclusion
345         * support/cpp2/options.h: deleted
346
347 2006-12-08 Borut Razem <borut.razem AT siol.net>
348
349         * support/cpp2/sdcc.h: removed x*alloc() macros
350         * support/cpp2/libiberty.h: uncommented out x*alloc() declarations
351         * support/cpp2/Makefile.bcc, support/cpp2/Makefile.in,
352           support/cpp2/sdcpp.sdc: x*alloc files added to the project
353         * support/cpp2/system.h: moved #include "sdcc.h"
354         * support/cpp2/libiberty/xexit.c, support/cpp2/libiberty/xmalloc.c,
355           support/cpp2/libiberty/xstrdup.c, support/cpp2/libiberty/xstrerror.c:
356           added
357         * support/cpp2/sdcppinit.c: added -isysroot, -fsigned-char,
358           -funsigned-char options
359         * support/cpp2/sdcppmain.c: fixed bug 1611411
360
361 2006-12-07 Borut Razem <borut.razem AT siol.net>
362
363         * support/cpp2/cpplib.c: reverted sdcpp special handling of _Pragma()
364           directive
365
366 2006-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
367
368         * src/SDCCsymt.c (addDecl): fixed bug 1609244
369         * src/SDCCmain.c (linkEdit): fixed bug 1609279
370         * doc/sdccman.lyx,
371         * .version: bumped to 2.6.2 because a) it's been a while
372           b) the linker sources have moved c) the preprocessor is upgraded
373
374 2006-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
375
376         * support/regression/tests/snprintf.c: some checks
377         * lib/src/printf_large.c: %bc: read char instead of int from stack
378
379 2006-12-03 Maarten Brock <sourceforge.brock AT dse.nl>
380
381         * device/include/mcs51/cc2430.h: inserted _XPAGE
382
383 2006-12-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
384
385         * device/include/mcs51/cc2430.h: added
386
387 2006-12-02 Maarten Brock <sourceforge.brock AT dse.nl>
388
389         * device/include/asm/default/features.h,
390         * device/include/asm/ds390/features.h,
391         * device/include/mcs51/at89s53.h,
392         * device/include/ser.h,
393         * device/include/ser_ir.h,
394         * device/include/serial.h: changed keywords to double underscore variants,
395           fixes bug 1590261 some more, thanks Steven Borley
396
397 2006-12-01 Raphael Neider <rneider AT web.de>
398
399         * src/pic/pcode.c (register_reassign): do not crash on recursive code
400           but emit warning (recursion is not supported for pic14)
401
402 2006-11-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
403
404         * src/mcs51/peeph.def: added 101.a,b (moves to int/long xdata)
405         * doc/sdccman.lyx: various small changes, acknowledged Sourceforge
406
407 2006-11-30 Raphael Neider <rneider AT web.de>
408
409         * src/pic/device.c (dump_sfr): always emit symbols
410         * src/pic/glue.c (pic14printPublics): fixed typo
411
412 2006-11-30 Raphael Neider <rneider AT web.de>
413
414         * src/pic/device.c (create_pic,ram_map): add memRange entries to PIC
415           (pic14_getSharebankSize, pic14_getSharebankAddress): replaced with
416           (pic14_hasSharebank,pic14_isShared,pic14_allRAMShared,
417            pic14_getSharedStack): NEW, evaluate the memRange entries to locate
418            a sharebank, use a non-shared bank for the stack if none available
419         * src/pic/device.h (struct memRange): added linked list next field,
420           added prototypes for above functions
421         * src/pic/ralloc.c (initStack): handle shared and banked stacks,
422           (typeRegWithIdx): accept fixed and unfixed stack registers
423         * src/pic/pcode.c (pCodeInitRegisters): use new functions to create
424           the stack, handle shared and banked stack (except for WSAVE),
425           (insertBankSel): removed useless optimization (will never fire),
426           (FixRegisterBanking): added optimization for devices with only one
427           possibly aliased bank of memory, like 16f84
428         * src/pic/glue.c (pic14_constructAbsMap): back to udata_ovr, as some
429           devices have no SHAREBANK in the linker script
430         * device/include/pic/pic14devices.txt: documented memmap
431         * device/lib/pic/libdev/Makefile.in: removed --stack-loc again
432
433 2006-11-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
434
435         * src/hc08/gen.c (transferRegReg, loadRegFromAop, forceStackedAop,
436           storeRegToAop, freeAsmop, genPlusIncr, genPlus, genPointerGetSetOfs,
437           genAnd, genOr, genXor, genLeftShiftLiteral, genRightShiftLiteral,
438           genhc08Code): switched most of the D (debug) macros to DD (detailed
439           debug) macros to better control clutter in the generated .asm file.
440         * src/hc08/gen.c: (forceStackedAop, genUminus, genLeftShift,
441           genRightShift): fixed bug with non-constant bit shift stored to
442           a volatile result (SF Open Discussion forum thread #1616749).
443           Single byte case is not yet optimized.
444
445 2006-11-28 Maarten Brock <sourceforge.brock AT dse.nl>
446
447         * device/include/asm/mcs51/features.h,
448         * device/include/malloc.h,
449         * device/include/stdio.h: changed keywords to double underscore variants,
450           fixes bug 1590261
451
452 2006-11-27 Borut Razem <borut.razem AT siol.net>
453
454         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
455           support/cpp2/Makefile.in, support/cpp2/cppfiles.c,
456           support/cpp2/output.h, support/cpp2/cppinit.c,
457           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
458           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
459           support/cpp2/cppdefault.c, support/cpp2/system.h,
460           support/cpp2/cpphash.h, support/cpp2/cpplex.c,
461           support/cpp2/cppdefault.h, support/cpp2/mbchar.c,
462           support/cpp2/prefix.c, support/cpp2/except.h,
463           support/cpp2/hwint.h, support/cpp2/cppmacro.c,
464           support/cpp2/line-map.h, support/cpp2/sdcpp.dsp,
465           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
466           support/cpp2/version.c, support/cpp2/cppmain.c,
467           support/cpp2/version.h, support/cpp2/hashtable.c,
468           support/cpp2/cpperror.c:
469           synchronized with GCC CPP release version 3.3.6,
470           the latest where cppmain.c still exists.
471         * support/cpp2/cpptrad.c, support/cpp2/sdcppmain.c,
472           support/cpp2/sdcppinit.c: added
473
474 2006-11-27 Borut Razem <borut.razem AT siol.net>
475
476         * support/cpp2/cpplex.c:
477           fixed _asm ... _endasm handling bug, introduce with GCC CPP
478           synchronization
479         * support/cpp2/cpplib.c: removed definitions of unused variables
480
481 2006-11-26 Borut Razem <borut.razem AT siol.net>
482
483         * support/cpp2/libiberty.h: commented out x*alloc() declarations
484           since they are redefined by macros in support/cpp2/sdcc.h
485         * support/cpp2/sdcc.h: x*alloc macro redefinition
486
487 2006-11-25 Borut Razem <borut.razem AT siol.net>
488
489         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
490           support/cpp2/configure, support/cpp2/Makefile.in,
491           support/cpp2/cppfiles.c, support/cpp2/output.h,
492           support/cpp2/cppinit.c, support/cpp2/cpplib.c,
493           support/cpp2/config.h, support/cpp2/cpplib.h,
494           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
495           support/cpp2/cppdefault.c, support/cpp2/config.in,
496           support/cpp2/system.h, support/cpp2/cpplex.c,
497           support/cpp2/cpphash.h, support/cpp2/mbchar.c,
498           support/cpp2/cppdefault.h, support/cpp2/prefix.c
499           support/cpp2/hwint.h, support/cpp2/mbchar.h,
500           support/cpp2/prefix.h, support/cpp2/cppmacro.c,
501           support/cpp2/configure.in, support/cpp2/intl.h,
502           support/cpp2/sdcpp.dsp, support/cpp2/acconfig.h,
503           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
504           support/cpp2/version.c, support/cpp2/cppmain.c,
505           support/cpp2/ansidecl.h, support/cpp2/libiberty.h,
506           support/cpp2/hashtable.c, support/cpp2/aclocal.m4,
507           support/cpp2/cpperror.c,
508           support/cpp2/libiberty/safe-ctype.c,
509           support/cpp2/libiberty/safe-ctype.h,
510           support/cpp2/libiberty/splay-tree.c,
511           support/cpp2/libiberty/obstack.c,
512           support/cpp2/libiberty/lbasename.c,
513           support/cpp2/libiberty/splay-tree.h,
514           support/cpp2/libiberty/obstack.h:
515           synchronized with GCC CPP release version 3.2.3,
516           the latest before integration of cpp into gcc
517         * support/cpp2/except.h, support/cpp2/line-map.c,
518           support/cpp2/line-map.h,
519           support/cpp2/libiberty/hex.c,
520           support/cpp2/libiberty/concat.c,
521           support/cpp2/libiberty/filenames.h: added
522         * support/cpp2/intl.c: deleted
523
524 2006-11-24 Borut Razem <borut.razem AT siol.net>
525
526         * src/SDCC.y: enabled compilation of empty source file
527         * support/Util/SDCCerr.[ch]: added sdcc warning 190 -
528           "ISO C forbids an empty source file"
529         * device/lib/_startup.c, device/lib/printf_tiny.c: disable warning 190
530           if all the code is ifdefed out.
531
532 2006-11-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
533
534         * src/hc08/gen.c (genPcall): fix for bug #1601032
535
536 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
537
538         * device/include/mcs51/c8051f000.h, device/include/mcs51/C8051F000.h,
539         * device/include/mcs51/c8051f018.h, device/include/mcs51/C8051F018.h,
540         * device/include/mcs51/c8051f020.h, device/include/mcs51/C8051F020.h,
541         * device/include/mcs51/c8051f040.h, device/include/mcs51/C8051F040.h,
542         * device/include/mcs51/c8051f060.h, device/include/mcs51/C8051F060.h,
543         * device/include/mcs51/c8051f120.h, device/include/mcs51/C8051F120.h,
544         * device/include/mcs51/c8051f200.h, device/include/mcs51/C8051F200.h,
545         * device/include/mcs51/c8051f300.h, device/include/mcs51/C8051F300.h,
546         * device/include/mcs51/c8051f310.h, device/include/mcs51/C8051F310.h,
547         * device/include/mcs51/c8051f320.h, device/include/mcs51/C8051F320.h,
548         * device/include/mcs51/c8051f326.h, device/include/mcs51/C8051F326.h,
549         * device/include/mcs51/c8051f330.h, device/include/mcs51/C8051F330.h,
550         * device/include/mcs51/c8051f340.h, device/include/mcs51/C8051F340.h,
551         * device/include/mcs51/c8051f350.h, device/include/mcs51/C8051F350.h,
552         * device/include/mcs51/c8051f410.h, device/include/mcs51/C8051F410.h:
553           Renamed to all upper case as per the standard set by SiLabs
554
555 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
556
557         * device/include/mcs51/C8051F520.h: new, added
558         * device/include/mcs51/compiler.h: added link about predefined macros
559
560 2006-11-23 Raphael Neider <rneider AT web.de>
561
562         * src/regression/Makefile: add -L path to fresh library
563         * src/regression/simulate: emphasize FAILED output
564         * src/regression/create_stc: output _failures from gpsim
565         * src/regression/compare4.c,
566         * src/regression/rotate6.c: fixed char literals,
567           all compile, all run =8-D
568
569         * src/pic/pcode.h: added isPCASMDIR macro
570         * src/pic/gen.c (genAnd): fixed bit offset
571         * src/pic/ralloc.c (allocNewDirReg,allocDirReg,allocRegByName,
572           packBits): unified register numbering schemes,
573           (newReg): do not insert stack registers into hash table,
574           (initStack): unpinned pseudo stack, simplified,
575           (typeRegWithIdx): fixed retrieval of stack registers,
576         * src/pic/pcode.c (addpCodeComment,sameBank): added,
577           (pCodeReplace): removed invalid assertion,
578           (insertPCodeInstruction): fixed newly added labels,
579           (insertBankSwitch,BankSelect,IsBankChange,DoBankSelect,
580           FixRegisterBankingInFlow,compareBankFlow,FixBankFlow,
581           DumpFlow): removed unsed (broken?) code,
582           (insertBankSel): prevent STATUS from being BANKSELed,
583           (FixRegisterBanking): rewritten from scratch, implemented generic
584             optimizations (suppress BANKSELs to same register and to registers
585             present in all banks),
586           (AnalyzeBanking): update flow after BANKSELection
587
588         * src/pic/glue.c (pic14_constructAbsMap): emit pseudo stack in
589             sharebank, let linker place it, mark STKxx symbols as emitted
590
591 2006-11-21 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
592
593         * src/regression/arrays.c,
594         * src/regression/bank1.c,
595         * src/regression/bool2.c,
596         * src/regression/compare7.c,
597         * src/regression/compare8.c,
598         * src/regression/compare9.c,
599         * src/regression/compare10.c,
600         * src/regression/configword.c,
601         * src/regression/for.c,
602         * src/regression/mult1.c,
603         * src/regression/pointer1.c,
604         * src/regression/rotate6.c,
605         * src/regression/string1.c,
606         * src/regression/struct1.c,
607         * src/regression/Makefile: make PIC14 regression tests run again
608           (3 fail, 6 won't compile)
609
610 2006-11-21 Raphael Neider <rneider AT web.de>
611
612         * device/include/pic16/pic18f4550.h,
613         * device/include/pic16/pic18f4455.h,
614         * device/lib/pic16/libdev/pic18f4550.c,
615         * device/lib/pic16/libdev/pic18f4455.c: fixed #1578591 and #1595144
616         * configure.in: removed superfluous closing bracket
617
618 2006-11-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
619
620         * device/lib/expf.c: Fixed bug 1599523: result of expf(x) is
621           always positive.
622
623 2006-11-21 Raphael Neider <rneider AT web.de>
624
625         * src/pic/device.{c,h}: added pic14_getPIC()
626         * src/pic/gen.c (continueIfTrue,jumpIfTrue): added PIC code,
627           (genAnd): added PIC code for one case, fixes #1597044
628         * src/pic/pcode.c (BankSelect): Ohoh, added generic optimization for
629           SFRs that are present in all banks (e.g., STATUS)
630
631 2006-11-20 Raphael Neider <rneider AT web.de>
632
633         * src/pic/pcode.c: changed inverted ops for DECFSZ/DECFSZW and
634           INCFSZ/INCFSZW and declared them as changing Z bit,
635           (insertPCodeInstruction): correctly invert the above instructions,
636           fixes #1599333,
637           (DoBankSelect): don't panic on po_immediates
638
639 2006-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
640
641         * as/link/aslink.h,
642         * as/link/mcs51/lkihx.c (newArea),
643         * as/link/mcs51/lkrloc.c: renamed newArea() to ihxNewArea()
644         * as/link/mcs51/lkihx.c (ihx): output reset vector as start address
645
646 2006-11-11 Raphael Neider <rneider AT web.de>
647
648         * src/pic/pcode.c (newpCodeOpBit): search SymbolTab for referenced
649           bitfield symbols, fixes #1579535 (once more...).
650
651 2006-11-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
652
653         * support/regression/generate-cases.py,
654         * support/regression/fwk/include/testfwk.h,
655         * support/regression/fwk/lib/testfwk.c: used code pointers,
656           (about 50kByte less code generated for mcs51)
657
658 2006-11-06 Borut Razem <borut.razem AT siol.net>
659
660         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
661           debugger/mcs51/configure: fixed failed check because the function
662           rl_function_of_keyseq isn't in Readline 5.2. Thanks to Ilya Goldberg
663           who submitted the patch for gpsim.
664         * debugger/mcs51/configure.in: removed the result message
665         * debugger/mcs51/Makefile.in: fixed the config.status warning
666           "... seems to ignore the --datarootdir setting"
667
668 2006-11-03 Maarten Brock <sourceforge.brock AT dse.nl>
669
670         * device/include/mcs51/c8051f020.h,
671         * device/include/mcs51/c8051f040.h,
672         * device/include/mcs51/c8051f060.h,
673         * device/include/mcs51/c8051f120.h: added PS0, fixed bug 1589279
674         * src/z80/gen.c (gencjneshort),
675         * src/z80/peeph.def: applied patch 1571373, thanks Philipp Krause
676
677 2006-10-31 Borut Razem <borut.razem AT siol.net>
678
679         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
680           debugger/mcs51/configure: get readline version
681
682 2006-10-30 Borut Razem <borut.razem AT siol.net>
683
684         * debugger/mcs51/sdcdb.c: replaced hardcoded "/" with DIR_SEPARATOR_STRING
685         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
686           debugger/mcs51/configure: locate readline even when cross compiling
687         * support/scripts/sdcc.nsi: include readline5.dll into the setup package
688
689 2006-10-29 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
690
691         * device/include/mcs51/serial_IO.h: putchar() and getchar() using
692           serial port.
693
694 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
695
696         * device/include/malloc.h,
697         * device/lib/calloc.c,
698         * device/lib/free.c,
699         * device/lib/malloc.c,
700         * device/lib/realloc.c: moved definition of struct into sources
701         * support/regression/tests/malloc.c: use void* for init_dynamic_memory()
702
703 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
704
705         * as/asx8051.dsp: corrected output directories
706         * as/link/hc08: new directory for hc08 linker
707         * as/hc08/aslink.h,             as/link/aslink.h,
708         * as/hc08/aslink.mak,           as/link/hc08/aslink.mak,
709         * as/hc08/clean.mk,             as/link/hc08/clean.mk,
710         * as/hc08/link_hc08.dsp,        as/link/hc08/link_hc08.dsp,
711         * as/hc08/lkaomf51.c,           as/link/hc08/lkaomf51.c,
712         * as/hc08/lkarea.c,             as/link/hc08/lkarea.c,
713         * as/hc08/lkdata.c,             as/link/hc08/lkdata.c,
714         * as/hc08/lkelf.c,              as/link/hc08/lkelf.c,
715         * as/hc08/lkihx.c,              as/link/hc08/lkihx.c,
716         * as/hc08/lklibr.c,             as/link/hc08/lklibr.c,
717         * as/hc08/lkmain.c,             as/link/hc08/lkmain.c,
718         * as/hc08/lkmem.c,              as/link/hc08/lkmem.c,
719         * as/hc08/lkrloc.c,             as/link/hc08/lkrloc.c,
720         * as/hc08/lks19.c,              as/link/hc08/lks19.c,
721         * as/hc08/Makefile.aslink,      as/link/hc08/Makefile.aslink,
722         * as/hc08/Makefile.bcc,         as/link/hc08/Makefile.bcc,
723         * as/hc08/Makefile.in,          as/link/hc08/Makefile.in,
724         * as/link/hc08/conf.mk,
725         * configure,
726         * configure.in,
727         * Makefile.in,
728         * sdcc.dsw: moved hc08 linker to as/link/hc08
729         * as/hc08/lkeval.c,     as/link/mcs51/lkeval.c,     as/link/lkeval.c,
730         * as/hc08/lkhead.c,     as/link/mcs51/lkhead.c,     as/link/lkhead.c,
731         * as/hc08/lklex.c,      as/link/mcs51/lklex.c,      as/link/lklex.c,
732         * as/hc08/lklist.c,     as/link/mcs51/lklist.c,     as/link/lklist.c,
733         * as/hc08/lknoice.c,    as/link/mcs51/lknoice.c,    as/link/lknoice.c,
734         * as/hc08/lksym.c,      as/link/mcs51/lksym.c,      as/link/lksym.c,
735         * as/link/mcs51/aslink.dsp,
736         * as/link/mcs51/Makefile.in: factored out the common files
737         * as/hc08/lkstore.c: deleted, use the one already in as/link/
738         * as/clean.mk: extra cleaning common files
739         * as/link/mcs51/strcmpi.c,      as/strcmpi.c: moved
740         * as/link/mcs51/strcmpi.h: deleted, moved protoype to aslink.h
741         * as/mcs51/asm.h: include sdccconf.h or sdcc_vc.h
742
743 2006-10-29 Raphael Neider <rneider AT web.de>
744
745         * src/pic/ralloc.c (newReg): create aliases for registers with
746           multiple names to fix #1579535 and #1584001,
747           (regWithIdx,dirregWithName): resolve aliases on lookup
748         * src/pic/pcode.c (DoBankSelect): die with error message on failing
749           bankselect
750         * device/lib/pic/libdev/Makefile.in: move pseudo stack down to 0x4f
751           to prevent build errors on small devices
752
753 2006-10-28 Raphael Neider <rneider AT web.de>
754
755         * src/pic/gen.c (genFunction,genCall): drop "same code page"
756           assumption within interrupt handlers, fixes #1584940
757         * src/pic/glue.c (pic14_constructAbsMap): mark absolute symbols as
758           "emitted" to avoid emitting them again in udata
759
760 2006-10-27 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
761
762         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
763         Removed.
764
765 2006-10-26 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
766
767         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
768         Initialize uart only if SM0 and SM1 are zero.  Also, use flag to turn
769         on/off CR to CRLF conversion.
770
771 2006-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
772
773         * doc/sdccman.lyx: updated IRQ section
774
775 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
776
777         * device/lib/serial_io.c: removed
778         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c
779         replacements for serial_io.c
780
781 2006-10-24 Maarten Brock <sourceforge.brock AT dse.nl>
782
783         * src/z80/main.c (_process_pragma, _parseOptions): fixed bug 1583318
784
785 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
786
787         * device/lib/serial_io.c: Default putchar() and getchar() for
788           mcs51 uses serial port.
789
790 2006-10-23 Maarten Brock <sourceforge.brock AT dse.nl>
791
792         * src/mcs51/gen.c (movc): improved check for 0 and 1, see RFE 1582704
793
794 2006-10-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
795
796         * support/regression/ports/mcs51/support.c: smaller
797         _sdcc_external_startup()
798         * device/lib/mcs51/crtxclear.asm: don't check high byte of l_PSEG
799
800 2006-10-20 Maarten Brock <sourceforge.brock AT dse.nl>
801
802         * device/lib/gbz80/crt0.s,
803         * device/lib/gbz80/crt0_rle.s,
804         * device/lib/gbz80/div.s,
805         * device/lib/gbz80/fstubs.s,
806         * device/lib/gbz80/heap.s,
807         * device/lib/gbz80/mul.s,
808         * device/lib/gbz80/putchar.s,
809         * device/lib/gbz80/stubs.s,
810         * device/lib/z80/crt0.s,
811         * device/lib/z80/crt0_rle.s,
812         * device/lib/z80/div.s,
813         * device/lib/z80/fstubs.s,
814         * device/lib/z80/heap.s,
815         * device/lib/z80/mul.s,
816         * device/lib/z80/putchar.s,
817         * device/lib/z80/stubs.s: reverted, I was mistaken
818
819 2006-10-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
820
821         * src/mcs51/peeph.def: peephole 238.x added check for notvolatile
822         * support/regression/ports/mcs51/support.c: removed race
823         condition on TI in _putchar allowing to use serial port mode 0
824
825 2006-10-20 Borut Razem <borut.razem AT siol.net>
826
827         * debugger/mcs51/sdcdb.c: replaced isblank() with isspace()
828
829 2006-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
830
831         * device/lib/gbz80/crt0.s,
832         * device/lib/gbz80/crt0_rle.s,
833         * device/lib/gbz80/div.s,
834         * device/lib/gbz80/fstubs.s,
835         * device/lib/gbz80/heap.s,
836         * device/lib/gbz80/mul.s,
837         * device/lib/gbz80/putchar.s,
838         * device/lib/gbz80/stubs.s,
839         * device/lib/z80/crt0.s,
840         * device/lib/z80/crt0_rle.s,
841         * device/lib/z80/div.s,
842         * device/lib/z80/fstubs.s,
843         * device/lib/z80/heap.s,
844         * device/lib/z80/mul.s,
845         * device/lib/z80/putchar.s,
846         * device/lib/z80/stubs.s: removed all leading underscores from area names
847
848 2006-10-17 Maarten Brock <sourceforge.brock AT dse.nl>
849
850         * support/regression/ports/mcs51/support.c: use highest baudrate so the
851           regression tests are not waiting in the simulator for simulated
852           transmission of debug output
853
854 2006-10-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
855
856         * device/lib/printf_large.c: slightly smaller
857         * doc/sdccman.lyx: do not use spaces within html links
858
859 2006-10-16 Borut Razem <borut.razem AT siol.net>
860
861         * configure.in, configure, sdccconf_in.h, src/SDCCglobal,
862           debugger/mcs51/Makefile.in, debugger/mcs51/sdcdb.[ch],
863           debugger/mcs51/aclocal.m4, debugger/mcs51/acinclide.m4,
864           debugger/mcs51/config.h.in, debugger/mcs51/configure.in,
865           debugger/mcs51/configure:
866           [ 1185668 ] add gnu readline support to sdcdb - enabled
867
868 2006-10-16 Raphael Neider <rneider AT web.de>
869
870         * src/pic/pcode.c (BankSelect): another fix on (partial) BANKSELs,
871           fixes #1577882, removes close to all banking optimizations
872
873 2006-10-15 Maarten Brock <sourceforge.brock AT dse.nl>
874
875         * src/SDCCsymt.c (checkSClass): no error for uninitialised absolute
876           variables in code memory
877         * support/regression/tests/absolute.c: added test for this
878
879 2006-10-15 Raphael Neider <rneider AT web.de>
880
881         * src/pic/pcode.c (InsertBankSel): suppress BANKSELs for one bank
882           devices,
883           (BankSelect): emit BANKSEL before touching linker-placed regs,
884           fixes #1570934
885
886 2006-10-10 Raphael Neider <rneider AT web.de>
887
888         * src/SDCCmain.c (optionsTable): accept --stack-size for PICs,
889         * src/pic/device.c (pic14_getSharebankSize,pic14_getSharebankAddress),
890         * src/pic/main.c (_pic14_parseOptions),
891         * src/pic/main.h: mostly reverted to previous state, now use results
892             from SDCCmain.c's argument parsing
893
894 2006-10-10 Borut Razem <borut.razem AT siol.net>
895
896         * debugger/mcs51/break.[ch], debugger/mcs51/cmd.c,
897           debugger/mcs51/sdcdb.[ch], debugger/mcs51/simi.c:
898           [ 1185668 ] add gnu readline support to sdcdb -
899           prepared for READLINE, not enabled yet,
900           thanks to <tal.bav AT gmail.com>
901
902 2006-10-10 Raphael Neider <rneider AT web.de>
903
904         * src/pic16/pcode.c (pic16_pCode2str): use isACCESS_BANK macro
905         * src/pic16/devices.inc,
906         * device/include/pic16 (pic18f[24]620.h),
907         * device/include/pic18fregs.h,
908         * device/lib/pic16/pics.all,
909         * device/lib/pic16/libdev/pic18f[24]{620,525}.c): added support for
910             18f2620, 18f4620, 18f2525, and 18f4525 devices, thanks to
911             Gary Plumbridge and Anton Strobl
912
913 2006-10-10 Raphael Neider <rneider AT web.de>
914
915         * src/pic/main.c (_pic14_parseOptions): added --stack-loc=NUM and
916           --stack-siz=NUM options to configure the argument passing stack
917         * src/pic/main.h: added stackLocation and stackSize to pic14_options_t
918         * src/pic/device.c (mapRegister): catch out-of-memory SIGSEGVs,
919           (pic14_getSharebankSize): obey --stack-siz=NUM,
920           (pic14_getSharebankAddress): obey --stack-loc=NUM
921
922 2006-10-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
923
924         * doc/sdccman.lyx: added to the manual
925         * doc/figures/ddd_example.png: added (neither pdflatex nor
926         most browsers seem to like the .eps file)
927
928 2006-10-06 Bernhard Held <bernhard AT bernhardheld.de>
929
930         * src/SDCCglue.c (tempfileandname): changed un*x tmp search paths
931         to /tmp and /var/tmp acc. LSB
932         * src/SDCCast.c (addCast): Fixed bug 1571231: promote in case of
933         RESULT_TYPE_IFX
934         * support/regression/tests/onebyte.c: added test
935
936 2006-10-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
937
938         * src/mcs51/gen.c: emitcode for "add a,0x%02x" requires only 8 bits.
939
940 2006-10-05 Borut Razem <borut.razem AT siol.net>
941
942         * partially fixed [ 1570701 ] peephole - not replacing code from multiline macros,
943           thanks to dfulab:
944           - sdcc.dsw: changed property eol-style to CRLF
945           - support/scripts/resource.rc: replaced references to "afxres.h" with "winres.h"
946
947 2006-10-04 Raphael Neider <rneider AT web.de>
948
949         * device/include/pic/{pic16f84.h,pic16f84a.h},
950         * device/lib/pic/libdev/{pic16f84.c,pic16f84a.c}: added PORT[AB]_bits
951           from patch #1522504, thanks to Robas Teodor
952
953 2006-10-02 Maarten Brock <sourceforge.brock AT dse.nl>
954
955         * as/link/z80/lkarea.c: essentially reverted lnksect() to #4380 which
956           fixes bug 1566015
957
958 2006-10-01 Maarten Brock <sourceforge.brock AT dse.nl>
959
960         * src/pic16/glue.c (pic16emitMaps),
961         * src/pic/glue.c (pic14emitMaps): hopefully fixed bug 1568779
962         * device/lib/gets.c: fixed bug 1568829,thanks Philipp Krause
963         * device/lib/pic16/libc/string/memcpypgm2ram.c,
964         * device/lib/pic16/libc/string/memcpyram2ram.c: fixed bug 1568836, thanks
965           Philipp Krause
966         * as/mcs51/asmain.c (asmbl, newdot): fixed problems with absolute areas
967         * as/link/mcs51/lkmem.c (summary2): reverted, do do count abs segments
968
969 2006-09-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
970
971         * support/librarian/sdcclib.c: Added option -l.
972         * as/link/mcs51/lkmem.c: don't use absolute segments to compute memory
973           usage totals.
974         * device/lib/make51lib.bat: added.  Allows building mcs51 libraries easily
975           using Windows command prompt.
976
977 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
978
979         * device/lib/libsdcc.lib: added module rand
980         * src/ds390/ralloc.c (rematStr),
981         * src/hc08/ralloc.c (rematStr),
982         * src/mcs51/ralloc.c (rematStr),
983         * src/z80/ralloc.c (rematStr): made output more consistent
984         * src/mcs51/gen.c: cosmetic changes
985
986 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
987
988         * src/port.h: added mem.cabs_name to PORT
989         * src/ds390/main.c,
990         * src/hc08/main.c,
991         * src/mcs51/main.c,
992         * src/pic16/main.c,
993         * src/pic/main.c,
994         * src/xa51/main.c,
995         * src/z80/main.c: added cabs_name initializers
996         * src/SDCCglue.c (emitStaticSeg): allocate and initialize absolute
997           constants
998           (emitMaps): emit absolutes in code memory into cabs_name
999         * src/SDCCmem.c,
1000         * src/SDCCmem.h: added memory map c_abs and defined CABS_NAME
1001         * src/ds390/gen.c (genCodePointerGet): fixed bug if left is a literal
1002         * support/regression/fwk/include/testfwk.h: added define for at
1003         * support/regression/tests/absolute.c: added, new
1004
1005 2006-09-29 Maarten Brock <sourceforge.brock AT dse.nl>
1006
1007         * src/mcs51/gen.c (genPlusIncr, genMinusDec, genAddrOf): small
1008           optimizations, see also patch 887161 by Stas Sergeev
1009         * src/mcs51/peeph.def(104, 207, 209, 212): disabled as they do not seem
1010           to be necessary anymore,
1011           (102, 103, 104, 127): renamed all occurances of bp to _bp
1012
1013 2006-09-27 Maarten Brock <sourceforge.brock AT dse.nl>
1014
1015         * device/include/mcs51/at89c51snd1c.h: fixed MSK_SREQ definition
1016           thanks Weston T. Schmidt for patch 1555221
1017         * src/mcs51/peeph.def: renamed rule 257 to 257.a, added 257.b
1018         * src/SDCCicode.c(geniCodeMultiply): small optimization
1019
1020 2006-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
1021
1022         * device/include/stdlib.h: added rand prototypes
1023         * device/lib/rand.c: new, added
1024         * device/lib/Makefile.in: added rand.c
1025         * src/z80/peeph.def,
1026         * src/z80/peeph-gbz80.def,
1027         * src/z80/peeph-z80.def: updated conditonals, fixed bug 1565908
1028
1029 2006-09-20 Raphael Neider <rneider AT web.de>
1030
1031         * device/lib/pic16/libio/i2c/i2cnack.c (i2c_nack): fixed ACKDT bit
1032
1033 2006-09-19 Maarten Brock <sourceforge.brock AT dse.nl>
1034
1035         * as/link/aslink.h: cosmetic changes
1036         * as/link/mcs51/Makefile.in,
1037         * as/link/z80/Makefile.in: fixed build on CF where VPATH is used
1038
1039 2006-09-17 Maarten Brock <sourceforge.brock AT dse.nl>
1040
1041         * as/link/aslink.h,
1042         * as/link/mcs51/aslink.h,
1043         * as/link/z80/aslink.h: merged and moved to as/link/
1044         * as/link/lkstore.c,
1045         * as/link/mcs51/lkstore.c: moved to as/link/
1046         * as/link/clean.mk: remove *.o
1047         * as/link/mcs51/alloc.h: deleted
1048         * as/link/mcs51/lkarea.c: added lnksect prototype
1049         * as/link/mcs51/lkdata.c,
1050         * as/link/mcs51/lklex.c,
1051         * as/link/mcs51/lkmain.c: renamed as_getline to lk_getline
1052         * as/link/mcs51/lkmem.c,
1053         * as/link/mcs51/lknoice.c: removed include strcmpi.h
1054         * as/link/mcs51/lksym.c: include stdlib.h instead of malloc.h or alloc.h
1055         * as/link/mcs51/aslink.dsp,
1056         * as/link/mcs51/Makefile.aslink,
1057         * as/link/mcs51/Makefile.bcc,
1058         * as/link/mcs51/Makefile.in: updated for moved files
1059         * as/link/z80/lkarea.c,
1060         * as/link/z80/lkhead.c,
1061         * as/link/z80/lklex.c,
1062         * as/link/z80/lklibr.c,
1063         * as/link/z80/lklist.c,
1064         * as/link/z80/lkmain.c,
1065         * as/link/z80/lkrloc.c,
1066         * as/link/z80/lksym.c: synced with mcs51
1067         * as/link/z80/lkdata.c,
1068         * as/link/z80/lkeval.c,
1069         * as/link/z80/lkihx.c,
1070         * as/link/z80/lks19.c: cosmetic changes
1071         * as/link/z80/Makefile.in,
1072         * as/link/z80/linkgbz80.dsp,
1073         * as/link/z80/linkz80.dsp: updated for moved files
1074
1075 2006-09-16 Borut Razem <borut.razem AT siol.net>
1076
1077         * debugger/mcs51/sdcdb.c: partially fixed
1078           [ 1203664 ] sdcdb fails to open files w. two "." periods
1079         * debugger/mcs51/simi.c, debugger/mcs51/symtab.c,
1080           debugger/mcs51/symtab.h: fixed indenting
1081         * configure.in, configure: up to date with latest Maarten's changes
1082
1083 2006-09-15 Maarten Brock <sourceforge.brock AT dse.nl>
1084
1085         as/link/mcs51
1086         as/aslink.dsp,                  as/link/mcs51/aslink.dsp,
1087         as/link/mcs51/aslink.h,         as/mcs51/aslink.h,
1088         as/link/mcs51/aslink.mak,       as/mcs51/aslink.mak,
1089         as/link/mcs51/lkaomf51.c,       as/mcs51/lkaomf51.c,
1090         as/link/mcs51/lkarea.c,         as/mcs51/lkarea.c,
1091         as/link/mcs51/lkdata.c,         as/mcs51/lkdata.c,
1092         as/link/mcs51/lkeval.c,         as/mcs51/lkeval.c,
1093         as/link/mcs51/lkhead.c,         as/mcs51/lkhead.c,
1094         as/link/mcs51/lkihx.c,          as/mcs51/lkihx.c,
1095         as/link/mcs51/lklex.c,          as/mcs51/lklex.c,
1096         as/link/mcs51/lklibr.c,         as/mcs51/lklibr.c,
1097         as/link/mcs51/lklist.c,         as/mcs51/lklist.c,
1098         as/link/mcs51/lkmain.c,         as/mcs51/lkmain.c,
1099         as/link/mcs51/lkmem.c,          as/mcs51/lkmem.c,
1100         as/link/mcs51/lknoice.c,        as/mcs51/lknoice.c,
1101         as/link/mcs51/lkrloc.c,         as/mcs51/lkrloc.c,
1102         as/link/mcs51/lks19.c,          as/mcs51/lks19.c,
1103         as/link/mcs51/lkstore.c,        as/mcs51/lkstore.c,
1104         as/link/mcs51/lksym.c,          as/mcs51/lksym.c,
1105         as/link/mcs51/Makefile.aslink,  as/mcs51/Makefile.aslink,
1106         as/link/mcs51/alloc.h,
1107         as/link/mcs51/clean.mk,
1108         as/link/mcs51/conf.mk,
1109         as/link/mcs51/Makefile.bcc,
1110         as/link/mcs51/Makefile.in,
1111         as/link/mcs51/readme.390,
1112         as/link/mcs51/strcmpi.c,
1113         as/link/mcs51/strcmpi.h,
1114         as/mcs51/clean.mk,
1115         as/mcs51/Makefile.bcc,
1116         as/mcs51/Makefile.in,
1117         configure,
1118         Makefile.in,
1119         sdcc.dsw: moved mcs51 linker to as/link/mcs51
1120
1121 2006-09-14 Maarten Brock <sourceforge.brock AT dse.nl>
1122
1123         * as/link,
1124         * as/link/Makefile.in,
1125         * as/link/z80/linkgbz80.dsp,
1126         * as/link/z80/linkz80.dsp,
1127         * configure,
1128         * link,
1129         * link/clean.mk,
1130         * link/Makefile.in,
1131         * link/README,
1132         * link/z80,
1133         * link/z80/aslink.h,
1134         * link/z80/clean.mk,
1135         * link/z80/conf.mk,
1136         * link/z80/linkgbz80.dsp,
1137         * link/z80/linkz80.dsp,
1138         * link/z80/lkarea.c,
1139         * link/z80/lkdata.c,
1140         * link/z80/lkeval.c,
1141         * link/z80/lkgb.c,
1142         * link/z80/lkgg.c,
1143         * link/z80/lkhead.c,
1144         * link/z80/lkihx.c,
1145         * link/z80/lklex.c,
1146         * link/z80/lklibr.c,
1147         * link/z80/lklist.c,
1148         * link/z80/lkmain.c,
1149         * link/z80/lkrloc.c,
1150         * link/z80/lks19.c,
1151         * link/z80/lksym.c,
1152         * link/z80/Makefile.in,
1153         * Makefile.in,
1154         * sdcc.dsw: moved link/ to as/link/
1155
1156 2006-09-11 Maarten Brock <sourceforge.brock AT dse.nl>
1157
1158         * as/mcs51/i51mch.c (machine): fixed warning
1159
1160 2006-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
1161
1162         * as/mcs51/i51mch.c (machine): S_DJNZ fixed bug 1554318
1163
1164 2006-09-09 Borut Razem <borut.razem AT siol.net>
1165
1166         * debugger/mcs51/sdcdb.c, debugger/mcs51/simi.c:
1167           sdcdb WIN32 native port
1168         * src/clean.mk: fixed
1169
1170 2006-09-08 Borut Razem <borut.razem AT siol.net>
1171
1172         * doc/sdccman.lyx: SDCDB and ucSim are available on Win32 platforms.
1173
1174 2006-09-08 Raphael Neider <rneider AT web.de>
1175
1176         * src/pic16/main.c (_pic16_linkEdit,pic16_linkCmd),
1177         * src/pic/main.c(_pic14_do_link, linkCmd): pass "-w" and "-r"
1178             to gplink to disable processor mismatch warning and to allow
1179             the use of devices with only aliased (shared) memory banks,
1180           (_pic16_genAssemblerPreamble): include pXXX.inc on --mplab-comp
1181
1182 2006-09-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1183
1184         * doc/sdccman.lyx: Some re-formating plus example on using
1185           #pragma preproc_asm +/-
1186
1187 2006-09-07 Borut Razem <borut.razem AT siol.net>
1188
1189         * support/scripts/sdcc.nsi: added SDCDB executables in a separate
1190           section
1191
1192 2006-09-06 Borut Razem <borut.razem AT siol.net>
1193
1194         * support/scripts/sdcc.nsi: fixed Error: unterminated string parsing
1195           line at sdcc.nsi:153
1196         * sdcc/debugger/mcs51/simi.c: argsToCmdLine() fixes
1197
1198 2006-09-05 Borut Razem <borut.razem AT siol.net>
1199
1200         * configure.in, configure: support for winsock2
1201         * debugger/mcs51/break.h, debugger/mcs51/cmd.c,
1202           debugger/mcs51/cmd.h, debugger/mcs51/sdcdb.c,
1203           debugger/mcs51/sdcdb.h, debugger/mcs51/simi.c,
1204           debugger/mcs51/simi.h, debugger/mcs51/symtab.c,
1205           debugger/mcs51/symtab.h: sdcdb WIN32 native port
1206
1207 2006-09-05 Maarten Brock <sourceforge.brock AT dse.nl>
1208
1209         * src/SDCCopt.c (cnvToFcall): fixed bug 1551947 by updating OP_USES
1210           and OP_DEFS
1211         * support/regression/tests/bug1551947.c: new, added
1212         * src/SDCCsymt.h: strings are char* not byte*
1213
1214 2006-09-05 Raphael Neider <rneider AT web.de>
1215
1216         * device/lib/pic16/libdev/pic18f4550.c,
1217           device/include/pic16/pic18f4550.h: added PORTD/TRISD
1218             declarations/definitions from patch #1520949
1219
1220 2006-09-05 Raphael Neider <rneider AT web.de>
1221
1222         * src/pic16/gen.c (genPackBits): fix assignment to 8-bit,
1223           byte-aligned bitfields, fixes #1539278
1224
1225 2006-09-05 Raphael Neider <rneider AT web.de>
1226
1227         * src/pic/gen.c (genReceive): skip unreferenced arguments,
1228           fixes #1544120
1229
1230 2006-09-04 Borut Razem <borut.razem AT siol.net>
1231
1232         * support/scripts/sdcc.nsi: move ucSim executables to a separate section
1233         * support/scripts/sdcc_cygwin_mingw32: don't disable ucsim,
1234           -mno-cygwin is a part of the compiler name
1235         * support/scripts/sdcc_mingw32: don't disable ucsim
1236
1237 2006-09-03 Borut Razem <borut.razem AT siol.net>
1238
1239         * sdcc.spec: corrected for 2.6.0. Thanks to Christer Weinigel.
1240         * device/lib/Makefile.in device/lib/clean.mk: small but essential corrections
1241
1242 2006-09-03 Raphael Neider <rneider AT web.de>
1243
1244         * src/pic/ralloc.c,
1245         * src/pic/pcode.c (InitReuseRegs): allocate registers with pseudo
1246           indices >= 0x1000 to disambiguate them from fixed regs __at(addr),
1247           fixes #1550049
1248
1249 2006-09-01 Borut Razem <borut.razem AT siol.net>
1250
1251         * sim/ucsim/cmd.src/cmdutil.cc: #include <sys/time.h> and <unistd.h>
1252           to make ppc-osx happy
1253
1254 2006-08-31 Borut Razem <borut.razem AT siol.net>
1255
1256         * sim/ucsim/cmd.src/newcmdposix.cc: #include <assert.h>
1257         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
1258         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
1259         * support/regression/ports/ds390/spec.mk,
1260           support/regression/ports/mcs51/spec.mk,
1261           support/regression/ports/xa51/spec.mk: introduced DEV_NULL variable.
1262           To run regression tests in mingw environment:
1263           make DEV_NULL=NUL CC=gcc
1264
1265 2006-08-30 Borut Razem <borut.razem AT siol.net>
1266
1267         * sim/ucsim/cmd.src/newcmdposix.cc, sim/ucsim/cmd.src/newcmdposixcl.h,
1268           sim/ucsim/cmd.src/newcmdwin32.cc, sim/ucsim/cmd.src/newcmdwin32cl.h,
1269           sim/ucsim/app.cc, sim/ucsim/appcl.h, sim/ucsim/configure,
1270           sim/ucsim/configure.in, sim/ucsim/ddconfig_in.h, sim/ucsim/error.cc,
1271           sim/ucsim/errorcl.h, sim/ucsim/option.cc, sim/ucsim/optioncl.h,
1272           sim/ucsim/utils.cc, sim/ucsim/utils.h, sim/ucsim/cmd.src/Makefile.in,
1273           sim/ucsim/avr.src/avr.cc, sim/ucsim/avr.src/avrcl.h,
1274           sim/ucsim/cmd.src/bp.cc, sim/ucsim/cmd.src/bpcl.h,
1275           sim/ucsim/cmd.src/cmdconf.cc, sim/ucsim/cmd.src/cmdgui.cc,
1276           sim/ucsim/cmd.src/cmdmem.cc, sim/ucsim/cmd.src/cmdset.cc,
1277           sim/ucsim/cmd.src/cmdsetcl.h, sim/ucsim/cmd.src/cmdstat.cc,
1278           sim/ucsim/cmd.src/cmduc.cc, sim/ucsim/cmd.src/cmduccl.h,
1279           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
1280           sim/ucsim/cmd.src/command.cc, sim/ucsim/cmd.src/commandcl.h,
1281           sim/ucsim/cmd.src/get.cc, sim/ucsim/cmd.src/getcl.h,
1282           sim/ucsim/cmd.src/info.cc, sim/ucsim/cmd.src/newcmd.cc,
1283           sim/ucsim/cmd.src/newcmdcl.h, sim/ucsim/cmd.src/set.cc,
1284           sim/ucsim/cmd.src/show.cc, sim/ucsim/cmd.src/timer.cc,
1285           sim/ucsim/hc08.src/hc08.cc, sim/ucsim/hc08.src/hc08cl.h,
1286           sim/ucsim/s51.src/Makefile.in, sim/ucsim/s51.src/interrupt.cc,
1287           sim/ucsim/s51.src/interruptcl.h, sim/ucsim/s51.src/pca.cc,
1288           sim/ucsim/s51.src/pcacl.h, sim/ucsim/s51.src/port.cc,
1289           sim/ucsim/s51.src/portcl.h, sim/ucsim/s51.src/serial.cc,
1290           sim/ucsim/s51.src/serialcl.h, sim/ucsim/s51.src/timer0.cc,
1291           sim/ucsim/s51.src/timer0cl.h, sim/ucsim/s51.src/timer1.cc,
1292           sim/ucsim/s51.src/timer1cl.h, sim/ucsim/s51.src/timer2.cc,
1293           sim/ucsim/s51.src/timer2cl.h, sim/ucsim/s51.src/uc390.cc,
1294           sim/ucsim/s51.src/uc390cl.h, sim/ucsim/s51.src/uc390hw.cc,
1295           sim/ucsim/s51.src/uc390hwcl.h, sim/ucsim/s51.src/uc51.cc,
1296           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/wdt.cc,
1297           sim/ucsim/s51.src/wdtcl.h, sim/ucsim/sim.src/hw.cc,
1298           sim/ucsim/sim.src/hwcl.h, sim/ucsim/sim.src/mem.cc,
1299           sim/ucsim/sim.src/memcl.h, sim/ucsim/sim.src/obsolete.cc,
1300           sim/ucsim/sim.src/obsolete.h, sim/ucsim/sim.src/sim.cc,
1301           sim/ucsim/sim.src/simcl.h, sim/ucsim/sim.src/stack.cc,
1302           sim/ucsim/sim.src/stackcl.h, sim/ucsim/sim.src/test_mem_speed.cc,
1303           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1304           sim/ucsim/xa.src/xa.cc, sim/ucsim/xa.src/xacl.h,
1305           sim/ucsim/z80.src/z80.cc, sim/ucsim/z80.src/z80cl.h:
1306           ucsim WIN32 native port
1307
1308 2006-08-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1309
1310         * doc/sdccman.lyx: added note on dynamic memory heap initialization
1311
1312 2006-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
1313
1314         * src/mcs51/gen.c (genAnd, genOr, genXor): fixed bug 1546986
1315         * src/ds390/gen.c (aopGetUsesAcc): handle AOP_DPTR2 and AOP_DPTRn too
1316
1317 2006-08-26 Maarten Brock <sourceforge.brock AT dse.nl>
1318
1319         * src/ds390/gen.c (genAnd, genOr, genXor): fixed bug 1546986
1320         * support/regression/tests/bug1546986.c: new, added
1321         * as/mcs51/.cvsignore,
1322         * debugger/mcs51/.cvsignore,
1323         * src/.cvsignore: deleted
1324
1325 2006-08-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1326
1327         * device/include/mcs51/P89c51RD2.h: fixed bug 1546936 (error in sbit
1328           definitions)
1329
1330 2006-08-20 Borut Razem <borut.razem AT siol.net>
1331
1332         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h:
1333           removed cl_listen_console::match(), cl_console::match(),
1334           restructured cl_commander::proc_input()
1335
1336 2006-08-16 Borut Razem <borut.razem AT siol.net>
1337
1338         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h,
1339           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
1340           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/uc.cc: code cleaning
1341
1342 2006-08-14 Borut Razem <borut.razem AT siol.net>
1343
1344         * support/regression/Makefile.in,
1345           support/regression/ports/pic14/gpsim.cmd,
1346           support/regression/ports/pic14/spec.mk,
1347           support/regression/ports/pic14/support.c:
1348           added pic14 regression test
1349
1350 2006-08-14 Maarten Brock <sourceforge.brock AT dse.nl>
1351
1352         * as/doc/asxhtm.html: documented changed ABS behaviour
1353         * as/doc/README: fixed some typos
1354
1355 2006-08-13 Maarten Brock <sourceforge.brock AT dse.nl>
1356
1357         * support/regression/tests/float_trans.c: disabled test if __STDC_IEC_559__
1358           not defined on host
1359
1360 2006-08-12 Borut Razem <borut.razem AT siol.net>
1361
1362         * support/regression/fwk/include/testfwk.h,
1363           support/regression/fwk/lib/testfwk.c,
1364           support/regression/generate-cases.py,
1365           support/regression/Makefile.in:
1366           regression test framework does not depend on function pointers and
1367           variable arguments
1368
1369 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
1370
1371         * device/include/stddef.h: c temporary hack to fix bug 1518273
1372
1373 2006-08-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1374
1375         * device/include/mcs51/cc2510fx.h: added
1376         * src/z80/z80.dsp, src/gbz80/gbz80.dsp: added support/Util/strcmpi.ch
1377           to projects.
1378
1379 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
1380
1381         * as/z80/assym.c (mlookup): ignore case when looking up mnemonics
1382         * as/z80/Makefile.in: added strcmpi.c
1383         * as/z80/z80adr.c: added upper case registers and lower case conditionals
1384         * support/Util/strcmpi.ch: added with intention to remove from mcs51/hc08
1385
1386 2006-08-08 Maarten Brock <sourceforge.brock AT dse.nl>
1387
1388         * device/lib/gbz80/asm_strings.s,
1389         * device/lib/gbz80/crt0_rle.s,
1390         * device/lib/gbz80/div.s,
1391         * device/lib/gbz80/mul.s,
1392         * device/lib/gbz80/shift.s,
1393         * device/lib/z80/asm_strings.s,
1394         * device/lib/z80/crt0_rle.s,
1395         * device/lib/z80/div.s,
1396         * device/lib/z80/mul.s,
1397         * device/lib/z80/shift.s: changed to all lower case menmonics except the
1398           flags which are all upper case
1399
1400 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
1401
1402         * as/z80/asm.h: made CASE_SENSITIVE 1
1403         * link/z80/aslink.h: made CASE_SENSITIVE 1
1404         * src/z80/gen.c (throughout): made all conditionals upper case
1405         * support/regression/tests/bug1503067.c: new
1406
1407 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
1408
1409         * src/z80/gen.c (aopPut): fixed bug !*ixy should be !*iyx,
1410           (shiftIntoPair): added case 2 for PAIR_IY,
1411           (setupToPreserveCarry): replaced parameters with iCode and check if
1412            PAIR_DE is in use to fix bug 1399290,
1413           (genPlus, genMinus): updated call to setupToPreserveCarry
1414         * support/regression/tests/bug1399290.c: new
1415
1416 2006-08-06 Maarten Brock <sourceforge.brock AT dse.nl>
1417
1418         * device/lib/Makefile.in (Z80SOURCES): enabled float support
1419         * sim/ucsim/z80.src/inst.cc (inst_rst): generate breakpoint on RST8,ACC==0
1420         * src/ds390/gen.c (shiftRLong),
1421         * src/hc08/gen.c (shiftLLong, shiftRLong): fixed bug 1533966
1422         * src/mcs51/gen.c (sameReg): changed to sameByte,
1423           (xch_a_aopGet): new,
1424           (shiftL2Left2Result, shiftR2Left2Result, shiftRLeftOrResult, shiftLLong,
1425            shiftRLong): fixed bug 1533966
1426         * src/z80/gen.c (shiftR2Left2Result, shiftL2Left2Result, genlshTwo,
1427           genLeftShiftLiteral, genrshTwo, genRightShiftLiteral): fixed bug 1533966
1428         * support/regression/Makefile.in: disabled z80, enabled ucz80
1429         * support/regression/tests/float_trans.c: enabled test for z80 and host
1430         * support/regression/tests/shifts2.c: new, for testing bug 1533966
1431
1432 2006-08-01 Borut Razem <borut.razem AT siol.net>
1433
1434         * src/mcs51/gen.c, src/dc390/gen.c: fixed warning:
1435           comparison is always false due to limited range of data type
1436           on PPC64 machine (openpower-linux1) where "char = unsigned char"
1437
1438 2006-08-01 Maarten Brock <sourceforge.brock AT dse.nl>
1439
1440         * sim/ucsim/hc08.src/hc08mac.h: removed faulty and unused add_u16_disp
1441         * sim/ucsim/hc08.src/hc08.cc: removed faulty and unused int8
1442         * sim/ucsim/z80.src/z80mac.h (add_u16_disp): use explicit signed char cast
1443         * sim/ucsim/z80.src/z80.cc: removed faulty and unused int8
1444
1445 2006-07-31 Borut Razem <borut.razem AT siol.net>
1446
1447         * sim/ucsim/configure, sim/ucsim/cmd.src/newcmdcl.h,
1448           sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/cmdutil.cc,
1449           sim/ucsim/z80.src/Makefile.in, sim/ucsim/configure.in,
1450           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/hc08.src/hc08.cc,
1451           sim/ucsim/ddconfig_in.h, sim/ucsim/s51.src/Makefile.in,
1452           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/serialcl.h,
1453           sim/ucsim/s51.src/uc51.cc, sim/ucsim/s51.src/serial.cc,
1454           sim/ucsim/app.cc, sim/ucsim/avr.src/Makefile.in:
1455           enable ucsim mingw compilation. Serial port is disabled,
1456           since it uses termios.h API, which is not available on native
1457           WIN32
1458
1459 2006-07-31 Borut Razem <borut.razem AT siol.net>
1460
1461         * Small Device C Compiler 2.6.0 released
1462         * support/scripts/sdcc.nsi: added FULL_DOC option
1463         * .version, doc/sdccman.lyx: changed sdcc version to 2.6.1
1464
1465 2006-07-28 Borut Razem <borut.razem AT siol.net>
1466
1467         * support/scripts/sdcc.nsi: remove $INSTDIR/include/asm/pic16/*.h
1468         * doc/INSTALL.txt: updated
1469
1470 2006-07-27 Borut Razem <borut.razem AT siol.net>
1471
1472         * device/lib/pic/Makefile.in, device/lib/pic/Makefile.subdir,
1473           device/lib/pic/libdev/Makefile.in: fixed bug
1474           [ 1438354 ] pic libsdcc: distclean doesn't work
1475         * device/lib/pic16/Makefile.in, device/lib/pic16/Makefile.subdir,
1476           device/lib/pic16/libio/Makefile.in: fixed bug
1477           [ 1438344 ] pic16 lib: clean doesn't work properly
1478         * doc/knownbugs.html removed [ 1438354 ] and [ 1438344 ] from the list
1479
1480 2006-07-26 Maarten Brock <sourceforge.brock AT dse.nl>
1481
1482         * device/lib/pic/libsdcc/fsdiv.c,
1483         * device/lib/pic/libsdcc/fsmul.c,
1484         * device/lib/pic16/libsdcc/float/fsdiv.c,
1485         * device/lib/pic16/libsdcc/float/fsmul.c,
1486         * device/lib/_fsdiv.c,
1487         * device/lib/_fsmul.c: bugfix, handle too large and too small numbers
1488         * support/regression/tests/bug1520966.c: added
1489         * doc/knownbugs.html: removed [ 1520966 ] from the list
1490
1491 2006-07-25 Borut Razem <borut.razem AT siol.net>
1492
1493         * configure.in, configure, sdccconf_in.h: fixed bug
1494           [ 1519095 ] regression test onebyte.c fails on ppc64 host
1495         * doc/knownbugs.html: removed [ 1519095 ] from the list
1496
1497 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
1498
1499         * doc/knownbugs.html: added, contains list of known bugs at release
1500         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
1501
1502 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
1503
1504         * device/include/mcs51/compiler.h: added SFRX for xdata based special
1505           function registers and corrected defaults with additional warning
1506         * device/lib/malloc.c: cosmetic changes
1507         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
1508         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
1509           (fillGaps): and used it
1510
1511 2006-07-20 Raphael Neider <rneider AT web.de>
1512
1513         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
1514           output unless SDCCPICDEBUG is set
1515         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
1516           output if SILENT is set
1517
1518 2006-07-11 Borut Razem <borut.razem AT siol.net>
1519
1520         * doc/README.txt: updated
1521
1522 2006-07-10 Borut Razem <borut.razem AT siol.net>
1523
1524         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
1525           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
1526           in WIN32 installation
1527         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
1528           release candidate 1
1529
1530 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
1531
1532         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
1533         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
1534
1535 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
1536
1537         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
1538
1539 2006-07-06 Borut Razem <borut.razem AT siol.net>
1540
1541         * support/regression/tests/bitfields.c:
1542           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
1543         * support/regression/tests/constantRange.c:
1544           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
1545
1546 2006-07-04 Borut Razem <borut.razem AT siol.net>
1547
1548         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
1549           src/port.mk,
1550           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
1551           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
1552           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
1553           reverted changes from 2006-07-03
1554         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
1555         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
1556           added CPPFLAGS, used by the host port
1557
1558 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
1559
1560         * support/regression/valdiag/tests/switch.c,
1561         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
1562         * support/regression/tests/libmullong.c: fixed for host
1563         * support/regression/ports/host/spec.mk: disable all warnings for host,
1564         SDCC runs with --less-pedantic too
1565
1566 2006-07-03 Borut Razem <borut.razem AT siol.net>
1567
1568         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
1569           defined CPPFLAGS
1570         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
1571         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
1572           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
1573           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
1574           include ../port.mk
1575         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
1576           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
1577           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
1578           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
1579
1580 2006-07-02 Raphael Neider <rneider AT web.de>
1581
1582         * src/pic16/devices.inc,
1583         * device/include/pic16/pic18fregs.h,
1584         * device/include/pic16/pic18f4550.h,
1585         * device/lib/pic16/pics.all,
1586         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
1587
1588 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
1589
1590         * as/hc08/lkaomf51.c (OutputName),
1591         * as/mcs51/lkaomf51.c (OutputName),
1592         * as/z80/asmain.c (asmbl),
1593         * src/ds390/main.c (asmLineNodeFromLineNode),
1594         * src/hc08/ralloc.c (hc08_assignRegisters),
1595         * src/mcs51/main.c (asmLineNodeFromLineNode),
1596         * src/xa51/ralloc.c (checkRegMask),
1597         * src/xa51/gen.c (emitcode),
1598         * src/z80/gen.c (_emit2),
1599         * src/SDCCast.c (searchLitOp),
1600         * src/SDCCglobl.h,
1601         * support/packihx/packihx.c,
1602         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
1603         * src/ds390/gen.c (aopPutUsesAcc),
1604         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
1605         * support/regression/tests/libmullong.c (mullong_wrapper),
1606         * src/SDCCsymt.c (powof2),
1607         * src/SDCCast.c,
1608         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
1609         * src/SDCCsymt.h: added TYPE_TARGET_*
1610         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
1611         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
1612         SDCCast because 1) header problems 2) this is the right place
1613         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
1614         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
1615         prototype
1616
1617 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
1618
1619         * src/SDCCicode.h: removed buggy semicolon in unused macro
1620         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
1621         search for previous definiton of auto symbols too,
1622         (findPrevUse): fixed logic of emitWarnings
1623
1624 2006-06-26 Raphael Neider <rneider AT web.de>
1625
1626         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
1627           PCLATH and PCLATU on interrupts, potentially fixes #1505141
1628
1629 2006-06-25 Raphael Neider <rneider AT web.de>
1630
1631         * device/lib/pic/libm: NEW, added math library functions
1632         * device/lib/pic/libsdcc: NEW; added float support functions
1633         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
1634         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
1635           NEW, added math related headers
1636         * device/include/asm/pic/features.h: NEW
1637         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
1638           (popGet): allow larger offsets for AOP_PCODE,
1639           (genDataPointerSet): handle literals explicitly, more debug output,
1640           (genAssign): fixed for float using aopLiteral ;-)
1641         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
1642           GOTO initialisation routine
1643         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
1644           flag on registers, fixes #1469043 (local variables do not work)
1645         * src/pic/main.c (_pic14_do_link),
1646         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
1647           available
1648
1649 2006-06-25 Borut Razem <borut.razem AT siol.net>
1650
1651         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
1652           characters printed (not including the trailing '\0' used to end
1653           output to strings). Problem detected in regression test bug-927659.c.
1654           NOTE: printf() family functions should return int instead
1655           unsigned int!
1656         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
1657           specifier are printed as themselves
1658         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
1659           support flags, width and precision specifiers
1660
1661 2006-06-24 Borut Razem <borut.razem AT siol.net>
1662
1663         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
1664           to the list of sdcc tagrets not supporting bit type
1665         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
1666           testfor pic16 due to bug:
1667           [ 1511794 ] pic16: regression test bug-895992.c fails
1668
1669 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
1670
1671         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
1672         * src/SDCCglue.c (initPointer), fixed bug 1496419
1673         * support/regression/tests/bug1496419.c: new, added
1674
1675 2006-06-22 Borut Razem <borut.razem AT siol.net>
1676
1677         * support/regression/ports/pic16/support.c: use gpsim usart module from
1678           libgpsim_modules library
1679
1680 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1681
1682         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
1683         IP0H to IPH0.
1684
1685 2006-06-19 Raphael Neider <rneider AT web.de>
1686
1687         * src/pic/glue.h,src/pic16/glue.h: added prototypes
1688         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
1689           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
1690           (pic14printExterns,pic14printPublics,pic16printPublics,
1691           pic16_printExterns): use new functions to emit symbols
1692           (picglue,pic16glue): emit publics before emitting externs
1693         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
1694           locally defined functions to avoid bug #1443651
1695         * support/regression/tests/bug-716242.c: removed pic16 workaround
1696         * support/regression/ports/pic16/spec.mk: ignore errors during build
1697
1698 2006-06-19 Raphael Neider <rneider AT web.de>
1699
1700         * src/pic/glue.h: added pic14aopLiteral prototype
1701         * src/pic/glue.c (pic14aopLiteral): return unsigned int
1702         * src/pic/gen.c: removed stdint.h dependency
1703           (aopGet): use Safe_strdup()
1704           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
1705           (genDataPointerSet): use pic14aopLiteral()
1706         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
1707           for pic16; thanks to Bernhard and Maarten
1708
1709 2006-06-18 Borut Razem <borut.razem AT siol.net>
1710
1711         * support/regression/tests/structflexarray.c: flexible array members
1712           not supported by gcc < 3
1713         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
1714           GUI tool by default
1715         * src/pic/gen.c: don't include [p]strdin.h on solaris
1716         * support/Util/pstdint.h: addad svn attributes
1717         * support/regression/tests/constantRange.c,
1718           support/regression/tests/rotate.c: include inttypes.h instead
1719           stdint.h on solaris, addad svn attributes
1720
1721 2006-06-18 Raphael Neider <rneider AT web.de>
1722
1723         * src/SDCCsymt.c (initCSupport): change return type of divschar to
1724           int for PIC16
1725         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
1726           (pic16_genMinusBits): simplified sign-extension
1727           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
1728             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
1729             adjusted to correctly handle mixed-signed operands, disabled
1730             now unused multiplciation routines
1731         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
1732           (assignResultValue): added argument denoting the size of the result
1733             as returned by the function (fixes upcasts in assigning from
1734             function calls: char foo(); int i = foo();)
1735           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
1736             function result to assignResultValue
1737           (genMult): disabled inlined multiplication code
1738           (genDiv): augmented to also handle the modulus operator, fixed to
1739             handle mixed-signed operands correctly
1740           (genMod): simply call genDiv, disabled unused code
1741           (genAssign): fixed missing (sign-)extension on result
1742         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
1743             valid char operands, allow signed operands for native code, added
1744             division and modulo operator handling
1745         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
1746
1747         As a consequence, onebyte.c (if split into two files) and muldiv.c
1748         pass regression tests.
1749
1750 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1751
1752         * doc/Makefile.in: two runs of makeindex seem needed to get
1753         correct page references in the index of sdccman.pdf
1754         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
1755
1756 2006-06-17 Borut Razem <borut.razem AT siol.net>
1757
1758         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
1759
1760 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1761
1762         * doc/sdccman.lyx: updated, added (porting source code, debugging),
1763         mentioned ec2drv and paulmon
1764
1765 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
1766
1767         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
1768           consecutive abs areas
1769           (find_empty_space, allocate_space): added map to handle codemap or
1770            xdatamap,
1771           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
1772            absolute idata and xdata
1773         * as/mcs51/lkmem.c (summary2): updated legend
1774
1775 2006-06-16 Raphael Neider <rneider AT web.de>
1776
1777         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
1778
1779 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
1780
1781         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
1782           1208515
1783         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
1784
1785 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
1786
1787         * src/port.h (struct PORT): added field gp_tags, to hold the tag
1788         value of generic pointers,
1789         * src/avr/main.c,
1790           src/ds390/main.c,
1791           src/hc08/main.c,
1792           src/izt/i186.c,
1793           src/izt/tlcs900h.c,
1794           src/mcs51/main.c,
1795           src/pic/main.c,
1796           src/pic16/main.c,
1797           src/xa51/main.c,
1798           src/z80/main.c: PORT structure, added elements for gp_tags field,
1799         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
1800         fields in the PORT structure of each port,
1801         * src/SDCCast.c (decorateType): allow processing of generic pointers
1802         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
1803         S_FIXED symbols
1804
1805 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
1806
1807         * link/z80/lkgb.c,
1808         * link/z80/lkgg.c,
1809         * src/pic16/gen.c,
1810         * src/pic16/main.c,
1811         * src/pic16/pcode.c,
1812         * src/pic/main.c,
1813         * src/pic/pcoderegs.c,
1814         * src/SDCCicode.c,
1815         * src/SDCCmain.c,
1816         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
1817           bug 1504689 on minGW
1818
1819 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1820
1821         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
1822
1823 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
1824
1825         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
1826
1827 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
1828
1829         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
1830           for optimization
1831
1832 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
1833
1834         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
1835         to a char variable. Fixed bug #1504211
1836         * device/include/pic16/adc.h,
1837         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
1838         and fixed bug #1364390
1839
1840 2006-06-10 Borut Razem <borut.razem AT siol.net>
1841
1842         * CVSROOT: removed the CVS left-over
1843
1844 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
1845
1846         * as/hc08/asmain.c (asexit),
1847         * as/hc08/lkmain.c (lkexit),
1848         * as/mcs51/asmain.c (asexit),
1849         * as/mcs51/lkmain.c (lkexit),
1850         * src/SDCCglue.c (DEFSETFUNC),
1851         * src/SDCCmain.c (linkEdit, assemble),
1852         * support/librarian/sdcclib.c (AddRel),
1853           replaced unlink() by standard C remove()
1854         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
1855         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
1856           gatherImplicitVariables): new, added to fix bug 608752,
1857           (createFunction): added gatherImplicitVariables()
1858         * src/SDCCast.h: added createRMW prototype
1859         * src/SDCCsymt.h (struct symbol): added infertype
1860         * support/regression/tests/bug608752.c: new, added
1861
1862 2006-06-10 Raphael Neider <rneider AT web.de>
1863
1864         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
1865           multibyte dummy reads (fixes #1503234)
1866
1867 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
1868
1869         * device/include/mcs51/compiler.h: new, added header file to enable
1870           creating common sfr definition header files for different compilers
1871
1872 2006-06-05 Raphael Neider <rneider AT web.de>
1873
1874         * src/pic16/{pcode.h,genarith.c}:
1875           introduced pCodeOp combining any two pCodeOps (previously only
1876           two register operands could be combined), removed pcop2 from
1877           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
1878         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
1879         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
1880           rewritten to use new PO_TWO_OPS
1881         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
1882         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
1883           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
1884           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
1885           (pic16_get_op): embraced return arg to allow #define return(x),
1886             added new case for combined opcodes
1887           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
1888           (pic16_pCode2str,pic16_getRegFrompCodeOp,
1889            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
1890
1891 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
1892
1893         * src/SDCCval.c (checkConstantRange): added
1894         * src/SDCCval.h: added checkConstantRange
1895         * support/Util/SDCCerr.c,
1896         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
1897         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
1898         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
1899         * src/SDCCast.c (decorateType): added checkConstantRange,
1900         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
1901         can be emitted with the correct always true/false warning,
1902         added optimization for double '!';
1903         result of decorateType() must be assigned back to the tree, because
1904         decorateType() can change the tree
1905         * src/SDCCicode.c (geniCodeLogic),
1906         (geniCodeAssign): replaced new checkConstantRange, added warnings,
1907         (checkConstantRange): removed, it was only a fragment which never
1908         emitted a warning
1909         * src/SDCCsymt.c (computeType): fixed promotion for
1910         "-1 < (unsigned bit) b"
1911         * src/pic/ralloc.c (packRegsForAssign),
1912         * src/pic16/ralloc.c (packRegsForAssign),
1913         * src/hc08/ralloc.c (packRegsForAssign),
1914         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
1915         from mcs51
1916         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
1917         * support/regression/tests/constantRange.c: added
1918         * support/valdiag/tests/constantRange.c: added
1919         * support/valdiag/valdiag.py: added -DPORT_HOST=1
1920
1921 2006-06-02 Borut Razem <borut.razem AT siol.net>
1922
1923         * support/regression/ports/pic16/support.c: increase stack size
1924           to 255 bytes
1925         * support/regression/Makefile.in: sort tests by name so that the
1926           resutlts can be compared on different machines / platforms
1927
1928 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
1929
1930         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
1931         * src/ds390/gen.c (emitLabel): new, added,
1932           (genDjnz): fixed stack overflow bug,
1933           (throughout): cosmetic changes to sync with mcs51/gen.c,
1934           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
1935         * src/mcs51/gen.c (genEndFunction): small optimization,
1936           (throughout): cosmetic changes to sync with ds390/gen.c
1937
1938 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
1939
1940         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
1941           (_print_format): fixed printing pointers
1942         * src/mcs51/gen.c (emitLabel, movb): new, added,
1943           (genAssign): small optimization,
1944           (genDjnz): fixed stack overflow bug,
1945           (throughout): replaced sprintf with SNPRINTF,
1946           replaced mcs51_regWithIdx with REG_WITH_INDEX,
1947           replaced emitcode("mov", "b,...") with MOVB(...),
1948           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
1949           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
1950         * src/mcs51/peeph.def: added rules 140 and 264
1951         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
1952           so they may get optimized into registers
1953
1954 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
1955
1956         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
1957           immediately when encountered,
1958           (printUsage): always use stderr even on windows
1959
1960 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
1961
1962         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
1963         (processParms): fixed bug #1247551
1964         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
1965         parseCmdLine, main): print '--version' to stdout,
1966         print 'help' to stdout if --help is given,
1967         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
1968         arguments are given; fixed --help
1969
1970 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
1971
1972         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
1973         * support/regression/tests/bug-1493710.c: added
1974
1975 2006-05-27 Borut Razem <borut.razem AT siol.net>
1976
1977         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
1978           static instead auto
1979         * support/regression/ports/pic16/support.c: increase stack size
1980           from default 64 bytes to 128 bytes
1981         * support/regression/tests/staticinit.c,
1982           support/regression/tests/float.c: regression tests fully enabled
1983           for pic16 port by putting the initialized data arrays into the code
1984           section
1985         * support/regression/ports/pic16/spec.mk: don't link default libraries.
1986           This was changed by mistake in the previous version.
1987
1988 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
1989
1990         * src/pic16/gen.c (genFunction, genEndFunction): some
1991         beautifications, fixed bug with falsely restoring FSR2 in large
1992         stack model, thanks to Beau E. Cox for reporting the bug
1993
1994 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
1995
1996         * debugger/mcs51/break.c,
1997         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
1998           use %p to print pointers, made address variables unsigned
1999         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
2000         * debugger/mcs51/symtab.c (parseSymbol): must return something
2001         * src/mcs51/gen.c (aopForSym): small optimization,
2002            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
2003           (freeAsmop): added missing break,
2004           (aopPut): removed parameter bvolatile, determine it inside the function,
2005           (saveRegisters, unsaveRegisters): small optimization,
2006           (genIpush): removed pointless check,
2007           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
2008           replaced sprintf with SNPRINTF,
2009           replaced strcpy with strncpyz,
2010           updated aopPut calls,
2011           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
2012         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
2013
2014 2006-05-24 Borut Razem <borut.razem AT siol.net>
2015
2016         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
2017           modification of test for the pic16 port, put the array to the code
2018           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
2019
2020 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2021
2022         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
2023         * support/Util/pstdint.h: added
2024
2025 2006-05-22 Borut Razem <borut.razem AT siol.net>
2026
2027         * src/regression/Makefile: removed bool2.c test, added -q linker option
2028         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
2029           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
2030           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
2031           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
2032           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
2033           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
2034           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
2035           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
2036           define SUPPORT_BIT_TYPES 0, removed unused bit variables
2037
2038 2006-05-22 Raphael Neider <rneider AT web.de>
2039
2040         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
2041           bug #1492360 (problematic due to generic pointers, see code)
2042
2043 2006-05-22 Borut Razem <borut.razem AT siol.net>
2044
2045         * support/regression/ports/pic16/specs.mk: removed stack size linker
2046           directive
2047         * support/regression/tests/array.c,
2048           support/regression/tests/bitopcse.c,
2049           support/regression/tests/bug-908454.c,
2050           support/regression/tests/malloc.c: modified for pic16 regression test
2051         * support/regression/tests/bitfields.c:
2052           pic16 - excluded bitfileds of size > 8
2053         * support/regression/tests/bp.c: pic16 - reduced data size
2054         * support/regression/tests/bug-221100.c: pic16 - reduced data size
2055         * support/regression/tests/bug-460010.c:
2056           pic16 - used the absolute address the fits in memory
2057         * support/regression/tests/bug-716242.c:
2058           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
2059         * support/regression/tests/float.c:
2060           pic16 - excluded - data size too big
2061         * support/regression/tests/onebyte.c:
2062           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
2063         * support/regression/tests/shifts.c:
2064           pic16 - function names probably have to differ in first X characters
2065           (gpasm limitation?)
2066         * support/regression/tests/staticinit.c:
2067           pic16 - excluded some tests due error: no target memory available for
2068           section ".idata"
2069
2070 2006-05-22 Borut Razem <borut.razem AT siol.net>
2071
2072         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
2073           second try. Thanks Stas Sergeev once more.
2074
2075 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
2076
2077         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
2078           (genLeftShift, genRightShift): fixed bug 1491627
2079         * src/hc08/peeph.def (rules 7, 8.x): added
2080         * support/regression/tests/shifts.c (ShiftLeftByParam,
2081           ShiftRightByParam, testShiftByParam): added to test variable shifting
2082
2083 2006-05-20 Raphael Neider <rneider AT web.de>
2084
2085         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
2086         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
2087           (allocReg): add only new registers to dynAllocRegs,
2088           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
2089             #1489055, #1445850, and probably #1483693
2090
2091 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
2092
2093         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
2094         bug in for-loop that didn't emit the last of CONFIG and ID registers
2095
2096 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
2097
2098         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
2099           with offset
2100         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
2101           1489016, 1434401 and 1490124
2102         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
2103           1489016, 1434401 and 1490124
2104
2105 2006-05-17 Borut Razem <borut.razem AT siol.net>
2106
2107         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
2108           thanks Stas Sergeev
2109
2110 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2111
2112         * device/include/mcs51/P89c51RD2.h,
2113         * device/include/mcs51/P89LPC901.h,
2114         * device/include/mcs51/P89LPC922.h,
2115         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
2116
2117 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
2118
2119         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
2120         to fix missing stack pragma in compiled binary object file,
2121
2122 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
2123
2124         * support/packihx/configure.in,
2125         * support/packihx/configure: removed warning, autoconf >= 2.5x can
2126         determine sizeof basic types even while cross compiling
2127
2128 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
2129
2130         * src/avr/gen.c (aopop),
2131         * src/ds390/gen.c (aopOp),
2132         * src/hc08/gen.c (aopOp),
2133         * src/mcs51/gen.c (aopop),
2134         * src/pic16/gen.c (pic16_aopOp),
2135         * src/pic/gen.c (aopOp),
2136         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
2137         if size of operand is smaller than spill location
2138
2139 2006-05-12 Borut Razem <borut.razem AT siol.net>
2140
2141         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
2142           have to have CR/LF line endings even if they are checked out on *nix
2143           or on WIN32 in cygwin binmode
2144
2145 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
2146
2147         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
2148         * device/include/ds80c390.h: added sfr16 definitions
2149         * src/ds390/gen.c,
2150         * src/ds390/gen.h,
2151         * src/ds390/main.c,
2152         * src/ds390/ralloc.c,
2153         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
2154           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
2155           bit returning functions
2156         * support/regression/tests/sfr16.c: enabled test on ds390
2157
2158 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2159
2160         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
2161         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
2162
2163 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
2164
2165         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
2166         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
2167           (cl_address_space constructor): removed expensive initialization,
2168           (cl_address_space::get_cell): extended for late initialization,
2169           (cl_address_space::*): use late initialization,
2170           (cl_address_decoder::activate): removed expensive initialization,
2171           This reduced regression test running time by 25%
2172
2173 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
2174
2175         * packihx/,
2176         * configure.in,
2177         * configure,
2178         * sdcc.dsw,
2179         * Makefile.bcc,
2180         * Makefile.in,
2181         * support/packihx/Makefile.in,
2182         * support/packihx/clean.mk,
2183         * support/packihx/Makefile.bcc,
2184         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
2185
2186 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2187
2188         * src/SDCCval.c (valNot): fix for regression test failure
2189           of not.c on big endian hosts
2190
2191 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
2192
2193         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
2194
2195 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2196
2197         * device/lib/mcs51/Makefile.in: changed string comparison operator
2198           to = for POSIX compliance; == is bash extension
2199
2200 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
2201
2202         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
2203           kosmonaut_pirx
2204
2205 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
2206
2207         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
2208         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
2209         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
2210         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
2211         bug report #1478657,
2212
2213 2006-05-05 Borut Razem <borut.razem AT siol.net>
2214
2215         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
2216           making the html
2217
2218 2006-05-02 Borut Razem <borut.razem AT siol.net>
2219
2220         * doc/Makefile.in: removed *.ind dependency since there is no rule to
2221           create *.ind, which made make to fail if invoked with -j 2
2222
2223 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
2224
2225         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
2226           Hubert Sack for patch 1479782
2227
2228 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
2229
2230         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
2231
2232 2006-05-01 Raphael Neider <rneider AT web.de>
2233
2234         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
2235           (create_pic): store only prefix-free device name,
2236           (init_pic): check for device names with "16" prefix,
2237           (list_valid_pics),
2238         * src/pic/device.h (struct PIC_device),
2239         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
2240             stored device name,
2241         * device/include/pic/pic12f{635,675,629,683}.h,
2242         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
2243         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
2244         * device/include/pic/pic16f505.h,
2245         * device/lib/pic/libdev/pic16f505.c: removed
2246         * device/include/pic/pic14devices.txt: added support for pic12f
2247             devices, removed unsupported non 16-bit devices
2248             [above changes provided by patch from Zik Saleeba]
2249         * src/pic/*, src/pic16/*, device/include/pic16/*,
2250           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
2251
2252 2006-05-01 Borut Razem <borut.razem AT siol.net>
2253
2254         * configure.in, configure, doc/Makefile.in:
2255           sync with nightly build makefile - latex, dvipdf and dvips
2256           not needed any more
2257
2258 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
2259
2260         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
2261         in the library source
2262
2263 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
2264
2265         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
2266
2267 2006-04-28 Raphael Neider <rneider AT web.de>
2268
2269         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
2270         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
2271           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
2272         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
2273
2274 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
2275
2276         * device/lib/pic/libdev/Makefile.in,
2277         * device/lib/hc08/Makefile.in,
2278         * device/lib/gbz80/Makefile.in,
2279         * device/lib/z80/Makefile.in,
2280         * device/lib/ds390/Makefile.in,
2281         * device/lib/ds400/Makefile.in: added srcdir to include search path,
2282         thanks to Borut for the bug report
2283         * configure.in,
2284         * configure: always create doc/Makefile independent from --enable-doc
2285         * Makefile.in: always install from directory doc independent from
2286         --enable-doc
2287         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
2288         removed
2289         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
2290         * doc/Makefile.in: install *.txt if present
2291         * device/include/Makefile.in (install): added installation of pic/*.inc
2292         and pic/*.txt files again, they were erroneously removed
2293
2294 2006-04-28 Raphael Neider <rneider AT web.de>
2295
2296         * src/pic/{gen.c,main.h,pcode.c},
2297         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
2298             concerning signedness with casts
2299
2300 2006-04-28 Raphael Neider <rneider AT web.de>
2301
2302         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
2303             definition of an interrupt handler,
2304         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
2305             interrupt handler stuff from picglue() to separate routine,
2306           (picglue): enabled definition of intr handlers in files w/o main()
2307
2308 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2309
2310         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
2311           compilation with MSVC 2005 Express Edition (VC8)
2312
2313 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
2314
2315         * device/lib/Makefile: fixed build of gbz80 lib
2316
2317 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2318
2319         * support/regression/tests/bug-460010.c,
2320         * support/regression/tests/bug-524691.c,
2321         * support/regression/tests/bug-716242.c: removed conditional defines
2322           that are already in testfwk.h
2323
2324 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
2325
2326         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
2327           (AccAXRsh1): added, shift right by 1,
2328           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
2329            AccAXLrl1
2330         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
2331
2332 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
2333
2334         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
2335         remove cast to same type
2336         * src/SDCCast.c (decorateType): fix for RFE 1475742,
2337         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
2338         * as/z80/Makefile,
2339         * link/z80/Makefile: removed, they have moved to
2340         Makefile.in files
2341         * configure,
2342         * configure.in: replaced duplicate message about ucsim by missing sdcpp
2343         * install-sh: fix bug #1204398 by setting umask 0022
2344         * device/lib/Makefile: separate build of z80 and gbz80 lib
2345
2346 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
2347
2348         Enabled VPATH feature: changed nearly all Makefiles (149 files).
2349         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
2350
2351         One basic decision: e.g. src/clean.mk includes further files. In order
2352         to make this work there are two solutions:
2353         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
2354           run configure on them. This way they can use
2355           'include $(srcdir)/port-clean.mk'
2356         - always include clean.mk by the Makefile at the same level. To avoid
2357           that `make clean` tries to include and build Makefile.dep the
2358           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
2359           implemented, because now even `make uninstall` doesn't create
2360           Makefile.in. clean.mk could be eliminated by pasting it in
2361           Makefile.in.
2362
2363         * debugger/mcs51/Makefile.in: build own objects from library sources
2364         (SLIB, SDCC) in current directory
2365
2366         * configure, configure.in: renamed --disable-device-lib-build in
2367         --disable-device-lib; added --enable-doc, the required tools are
2368         searched by configure; added result message; the toolchain for the
2369         belonging ports are now only built, if the port is enabled.
2370
2371         * support/regression/*: all output is written in directory gen, because
2372         the fwk and ports directories don't livet in the build tree using vpath
2373
2374         * doc/sdccman.lyx: renamed --disable-device-lib-build to
2375         --disable-device-lib, added --enable-doc, added section VPATH
2376
2377         * sim/ucsim/configure.in,
2378         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
2379         z80 are enabled by default
2380
2381 2006-04-24 Raphael Neider <rneider AT web.de>
2382
2383         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
2384             to config word, "pic14_"-prefixed some extern functions
2385           (pic14_emitConfigWord): emit __config directive(s) if assignment to
2386             config word has been found
2387         * src/pic/device.h: added prototypes
2388         * src/pic/pcode.c: added "pic14_"-prefix where needed
2389         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
2390             fixup
2391         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
2392             words,
2393           (pic14emitRegularMap): ignore config words,
2394           (pic14createInterruptVect): moved generating __config directives away
2395           (picglue): have __config directives emitted
2396
2397 2006-04-24 Borut Razem <borut.razem AT siol.net>
2398
2399         * doc/Makefile: sync with nightly build makefile
2400
2401 2006-04-24 Raphael Neider <rneider AT web.de>
2402
2403         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
2404             registers that have not been assigned proper liveranges,
2405             fixes #1469504 and #1474602,
2406           (pCodeRegOptimizeRegUsage): fixed typo in comment
2407
2408 2006-04-24 Borut Razem <borut.razem AT siol.net>
2409
2410         * device/examples/main8051.c: deleted - it was removed from CVS
2411           24.mar.2000 and after that modified 18.feb.2001, so it reappered
2412           after the transition to Subversion
2413         * src/SDCCalloc.h: deleted - it was removed  from CVS
2414           3.feb.2001 and after that modified 18.feb.2001, so it reappered
2415           after the transition to Subversion
2416         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
2417           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
2418           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
2419           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
2420
2421 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
2422
2423         * as/asx8051.dsp: added mcs51/strcmpi.h
2424         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
2425         * as/hc08/aslink.h: updated lnksect prototype
2426         * as/hc08/asm.h,
2427         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
2428         * as/hc08/asmain.c,
2429         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
2430           (newdot): handle A_ABS
2431         * as/hc08/asout.c,
2432         * as/mcs51/asout.c (outarea): output address
2433         * as/hc08/lkaomf51.c,
2434         * as/mcs51/lkaomf51.c: disabled unused array UsageType
2435         * as/hc08/m08pst.c,
2436         * as/mcs51/i51pst.c,
2437         * as/z80/z80pst.c: "ABS" is not A_OVR
2438         * as/hc08/lkarea.c (newarea): read a_addr,
2439           (lnkarea): added codemap array, sort absolute areas to the front,
2440            combine all GSINITx/GSFINAL,
2441           (find_empty_space, allocate_space): new functions,
2442           (lnksect): return next address, handle absolute sections
2443         * as/mcs51/lkarea.c (newarea): read a_addr,
2444           lnksect2 prototype changed,
2445           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
2446           (find_empty_space, allocate_space): new, factored out of lnksect2,
2447           (lnksect2): return next address, handle absolute sections
2448         * as/hc08/lkhead.c,
2449         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
2450         * as/hc08/lklibr.c (addfile, fndsym),
2451         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
2452           index out of range and detect both '\' and '/'
2453         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
2454         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
2455           regression tests (ds390 cannot return bool yet)
2456         * doc/sdccman.lyx: changed version number, document changed --no-peep,
2457           document critical interrupts on z80, document changed SDCC define
2458         * src/asm.c (_asxxxx_mapping): fixed .org directive,
2459           (_a390_mapping): added .org directive
2460         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
2461           (genMultOneByte): fixed warnings
2462         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
2463           ones
2464         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
2465         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
2466           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
2467         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
2468         * src/pic16/main.c: removed newReg prototype
2469         * src/pic16/pcode.c,
2470         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
2471           warnings
2472         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
2473           ones
2474         * src/pic16/ralloc.c
2475         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
2476           to fix warnings
2477         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
2478           from short to PIC_OPTYPE
2479         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
2480         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
2481           optype from short to PIC_OPTYPE
2482         * src/port.h: made int_size unsigned to fix warnings
2483         * src/SDCC.y: fixed warning on MSVC
2484         * src/SDCCicode.c (getArraySizePtr): return unsigned int
2485         * src/SDCCopt.c (convertToFcall): fixed warnings
2486         * src/SDCCsymt.h: removed double prototype for genSymName
2487         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
2488           offset int to fix warnings
2489
2490 2006-04-22 Borut Razem <borut.razem AT siol.net>
2491
2492         * doc/sdccman.lyx, */Makefile, */Makefile.in:
2493           references to CVS replaced with Subversion
2494
2495 2006-04-21 Borut Razem <borut.razem AT siol.net>
2496
2497         * doc/sdccman.lyx, */Makefile, */Makefile.in:
2498           references to CVS replaced with Subversion
2499
2500 2006-04-19 Borut Razem <borut.razem AT siol.net>
2501
2502         * src/version.awk: adapted for svn
2503         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
2504           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
2505           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
2506           /binutils-avr/etc/*.vi, *.jin: removed all properties
2507           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
2508
2509 2006-04-19 Borut Razem <borut.razem AT siol.net>
2510
2511         * CVS to Subversion migration completed
2512
2513 2006-04-18 Borut Razem <borut.razem AT siol.net>
2514
2515         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
2516           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
2517
2518 2006-04-17 Borut Razem <borut.razem AT siol.net>
2519
2520         * device/include/Makefile.in: added pic/*.inc to the installation
2521
2522 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
2523
2524         * support/regression/collate-results.py: fixed output in case of
2525         a valdiag error
2526         * support/regression/generate-cases.py: fixed splitting of pathnames
2527         with dots
2528         * as/hc08/lklibr.c (addfile),
2529         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
2530
2531 2006-04-11 Raphael Neider <rneider AT web.de>
2532
2533         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
2534         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
2535         * src/pic16/pcode.c (assignValnums): fixed #1460578
2536
2537 2006-04-11 Raphael Neider <rneider AT web.de>
2538
2539         * device/lib/pic/libdev/*.c,
2540         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
2541           fixes #1468739, enables compilation in --std-c99 mode
2542         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
2543
2544 2006-04-11 Raphael Neider <rneider AT web.de>
2545
2546         * src/pic/device.c (find_device): removed debug output
2547           (list_valid_pics): enabled verbose listing of supported devices
2548         * device/include/stdbool.h: define bool as char for pic14/16 as well
2549
2550 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2551
2552         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
2553
2554 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2555
2556         * .version: bumped version to 2.5.6
2557         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
2558
2559 2006-04-06 Raphael Neider <rneider AT web.de>
2560
2561         * .version: bumped version to 2.5.6 (pic14 ABI changed)
2562         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
2563         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
2564           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
2565             pic14_constructAbsMap
2566           (pic14printPublics): declare absolute global symbols as global
2567           (pic14createInterruptVect),
2568         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
2569           (newReg): assume new registers unused, use correct name in
2570             hashtable (reg->name instead of name), more debugLog output
2571         * src/pic/device.h (PIC_device): added fields for verbose output
2572         * src/pic/device.c: moved device definition to pic14devices.txt,
2573             added routines for runtime parsing of pic14devices.txt,
2574             added support for second config word
2575         * src/pic/main.c (_process_pragma): removed #pragma maxram,
2576           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
2577           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
2578           (_pic14_parseOptions): moved pCodeInitRegisters here
2579           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
2580         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
2581           (pCodeInitRegisters): rewrapped comments, perpared new approach to
2582             handling the pseudo stack
2583         * device/lib/Makefile.in: ignore failures in objects-pic16,
2584         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
2585         * device/lib/pic/NEWS: document new dependency on picXXX.lib
2586         * device/lib/pic/Makefile.subdir,
2587         * device/lib/pic16/Makefile.subdir: improved clean rules
2588         * device/lib/pic/libdev/: NEW, pic14 device libraries
2589         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
2590         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
2591         * device/include/Makefile.in: create subdir and install pic14 headers
2592         * device/include/pic/p16f_common.inc: removed unused declarations
2593         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
2594             PICs from inc2h.pl v1.6,
2595             replaced BIT_AT macros with struct declarations
2596         * device/include/pic/pic14devices.txt: definition of supported devices,
2597             all above improvements contributed by Zik Saleeba, thanks
2598         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
2599         * support/scripts/sdcc.nsi: also install pic14 device libraries and
2600             headers
2601
2602 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
2603
2604         * device/include/mcs51/c8051f410.h: added interrupt numbers,
2605         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
2606           thanks to Charles Olds
2607
2608 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2609
2610         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
2611
2612 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
2613
2614         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
2615         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
2616         * support/regression/bug1464657.c: added, new test
2617
2618 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
2619
2620         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
2621           version number
2622
2623 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
2624
2625         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
2626           --no-peep and --peep-file <file> are used don't use default rules but
2627           do use the <file>
2628
2629 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
2630
2631         * src/mcs51/gen.c (genCall): fixed bug 1457608
2632
2633 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2634
2635         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
2636         changes seem to cause (trigger?) problems with the build system.
2637
2638 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
2639
2640         * src/SDCCpeeph.c (operandsLiteral): new, added,
2641           (callFuncByName): inserted operandsLiteral
2642         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
2643
2644 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2645
2646         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
2647         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
2648
2649 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
2650
2651         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
2652           implemented patch 1120823 Thanks to Willy De la Court (normal
2653           interrupts need an interrupt number now if they are made critical),
2654           and enabled nesting of critical functions though not for gbz80
2655           (genCritical, genEndCritical): added functions
2656           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
2657         * src/z80/mappings.i: added "ei" to all mappings
2658
2659 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2660
2661         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
2662         submitted by the Debian SDCC maintainer Aurelien Jarno:
2663         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
2664         archive with gcc 4.1 on mips and wrote the patch"
2665
2666 2006-03-16 Raphael Neider <rneider AT web.de>
2667
2668         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
2669           the left operand is shorter than the result (c* = lit-c* + int),
2670           fixes bug #1450796
2671         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
2672           OP_SYMBOL
2673
2674 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
2675
2676         * src/.version: increased version number to 2.5.5
2677         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
2678         linking is done manually in pic16 port's _linkEdit,
2679         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
2680         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
2681         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
2682         allocate asmop as AOP_ACC,
2683         (aopForRemat): added parameter 'bool result' in function declaration,
2684         (pic16_aopGet): return AOP_ACC when accessing WREG,
2685         (pic16_popGetTempReg): minor modification,
2686         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
2687         'pic16_allocWithIdx',
2688         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
2689         calling function in absolute addresses,
2690         (genAssign): take into account AOP_ACC asmop,
2691         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
2692         * src/pic16/pcoderegs.c: some debug functions and lines added,
2693         * src/pic16/ralloc.c (decodeRegType): added but commented out,
2694         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
2695         register too,
2696         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
2697         call to allocReg, not by manually allocating a new one,
2698         (pic16_assignRegisters): now before going through the register
2699         allocating functions mark all registers as free. This eliminates some
2700         side effects resulting from peephole parser done earlier in the backbone
2701
2702 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
2703
2704         * src/SDCCicode.c (geniCodeLogic),
2705         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
2706
2707 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
2708
2709         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
2710           (genSend): bugfix, do not allocate and free twice,
2711           (shiftRLong): handle partially overlapping aops
2712         * support/regression/tests/bitopcse.c: fixed warning redefined idata
2713
2714 2006-03-08 Borut Razem <borut.razem AT siol.net>
2715
2716         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
2717           for pic16
2718
2719 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
2720
2721         * support/regression/tests/bug1409955.c: new, added
2722         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
2723         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
2724           (aopForSym, aopOp): increment asmop.allocated if reused,
2725           (freeAsmop): decrement asmop.allocated and check for zero instead of
2726           using asmop.freed,
2727           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
2728           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
2729            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
2730            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
2731            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
2732            genSignedRightShift, genRightShift, genDataPointerGet,
2733            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
2734            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
2735             in reverse order from allocation,
2736           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
2737             added swappedLR to keep track
2738         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
2739           pdata & code for GCC, z80, gbz80 & hc08
2740         * support/regression/tests/zeropad.c: moved defines to testfwk.h
2741
2742 2006-03-08 Raphael Neider <rneider AT web.de>
2743
2744         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
2745
2746 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
2747
2748         * device/include/mcs51/c8051f410.h: new SiLabs mcu
2749         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
2750         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
2751
2752 2006-03-06 Borut Razem <borut.razem AT siol.net>
2753
2754         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
2755           made the linker quiet
2756
2757 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
2758
2759         * src/pic16/gen.c (genPcall): fixed bug #1443644
2760         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
2761         which dumps before the function entry point a data byte which represents
2762         the number of the local variables used by the specified function, added
2763         'xinst' for initial support for Extended Instruction Support,
2764         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
2765         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
2766         port->fun_prefix anymore (may change later),
2767         (genFunction, genEndFunction): do not store/restore local registers for
2768         _main (this should take care the --main-return command line option in
2769         the future),
2770         (genOr): removed some legacy pic-port instructions,
2771         * src/pic16/genarith.c (genAddLit): re-enabled old code because
2772         performing operations with SFR's causes data to be written more than
2773         once to each SFR. Perhaps SFRs should be handled in special cases...
2774         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
2775         pcode.h
2776         * src/pic16/main.c (_process_pragma): stack bound checking did not take
2777         into account for stack starting position,
2778         (struct OPTIONS pic16_optionsTable): added command line argument
2779         --extended or -y for Extended Instruction Support,
2780         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
2781         (deassignLRs): *** perhaps the most important change, old 'for' code
2782         (commented out for reference), didn't account for some registers which
2783         were left marked 'not free' after a pointer operation. The change
2784         reduces register usage a lot in some cases
2785
2786 2006-03-04 Borut Razem <borut.razem AT siol.net>
2787
2788         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
2789           _clean
2790         * support/regression/tests/bug-524697.c: decreased array size for
2791           mcs51 to fit into the internal RAM
2792         * support/regression/Makefile.in: a little bit more verbose
2793
2794 2006-03-03 Borut Razem <borut.razem AT siol.net>
2795
2796         * support/regression/fwk/lib/testfwk.c,
2797           support/regression/fwk/include/testfwk.h: introduced function
2798           _prints(), nonrecursive _printn(), call _initEmu() from main()
2799         * support/regression/ports/gbz80/support.asm,
2800           support/regression/ports/ucz80/support.asm,
2801           support/regression/ports/z80/support.asm,
2802           support/regression/ports/ds390/support.c,
2803           support/regression/ports/hc08/support.c,
2804           support/regression/ports/host/support.c,
2805           support/regression/ports/mcs51/support.c,
2806           support/regression/ports/xa51/support.c: added empty _initEmu()
2807           function
2808         * support/regression/ports/pic16/gpsim.cmd,
2809           support/regression/ports/pic16/spec.mk,
2810           support/regression/ports/pic16/support.c,
2811           support/regression/Makefile.in: added pic16 regression test
2812
2813 2006-03-01 Raphael Neider <rneider AT web.de>
2814
2815         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
2816           genConstPointerGet): use safe way of generating MOVFF to cover
2817             literals as well as registers, fixes bug #1440527
2818         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
2819             dereference
2820           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
2821             more correctly, fixes bug #1232186
2822           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
2823         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
2824             gplink guess the correct processor in more cases, applied patch
2825             from Till Riedel attached to and fixing bug #1436552
2826
2827 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2828
2829         * support/regression/tests/array.c: added, contains check for #1434401
2830         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
2831
2832 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
2833
2834         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
2835         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
2836         * device/include/mcs51/c8051f326.h,
2837         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
2838         * device/include/mcs51/c8051f000.h,
2839         * device/include/mcs51/c8051f018.h,
2840         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
2841           PCON_IDLE,PCON_STOP and added sfr16 definitions
2842
2843 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
2844
2845         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
2846           genGetWord): fixed bug 1409955
2847
2848 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
2849
2850         * device/include/hc08/mc68hc908gp32.h,
2851         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
2852
2853 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
2854
2855         * src/SDCCast.c (constExprValue): return NULL if not a value
2856         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
2857         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
2858         * support/regression/tests/bitfields.c: enabled signed bitfield for all
2859
2860 2006-02-13 Borut Razem <borut.razem AT siol.net>
2861
2862         * src/regression/ptrarg.c: added, fails due to bug #1430967
2863         * src/regression/Makefile: ptrarg.c added, ...
2864
2865 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
2866
2867         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
2868         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
2869
2870 2006-02-11 Borut Razem <borut.razem AT siol.net>
2871
2872         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
2873           print "Processor: xxx" message to stdout only if --verbose
2874
2875 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
2876
2877         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
2878         * support/regression/tests/bug1426356.c: added
2879         * support/regression/tests/bitfields.c: removed 2 tests
2880
2881 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
2882
2883         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
2884         * device/include/mcs51/c8051f330.h,
2885         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
2886           PCON_IDLE,PCON_STOP and added sfr16 definitions
2887         * device/lib/_divsint.c,
2888         * device/lib/_divuint.c,
2889         * device/lib/_divulong.c,
2890         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
2891           register bank bug for small stackauto
2892
2893 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
2894
2895         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
2896
2897 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
2898
2899         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
2900         * all.dsp: corrected several bin paths
2901         * device/include/mcs51/c8051f120.h,
2902         * device/include/mcs51/c8051f300.h,
2903         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
2904           to PCON_IDLE,PCON_STOP
2905         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
2906         * device/lib/printf_large.c (output_float): fixed bug 1388703
2907         * support/regression/tests/bug1057979.c: added test for bug 1388703
2908
2909 2006-02-08 Raphael Neider <rneider AT web.de>
2910
2911         * src/pic/pcode.c (pciTRIS): fixed typo,
2912           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
2913           (LinkFlow): fixed handling of flows that end in a call,
2914           (ReuseReg): perform safety check earlier
2915         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
2916             to work with flows at the beginning of a pBlock,
2917             fixes #1426557 (Symbol not previously defined),
2918           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
2919             usage information
2920           (RemoveUnusedRegisters): update register usage info
2921         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
2922             created, reuse existing ones instead
2923         * src/pic/gen.c (genPcall): fixed #1424719
2924
2925 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
2926
2927         * link/z80/lkmain.c,
2928         * link/z80/lklex.c,
2929         * link/z80/lkdata.c,
2930         * link/z80/aslink.h: fixed build on current cygwin:
2931         replaced getline() by lk_getline()
2932
2933 2006-02-01 Borut Razem <borut.razem AT siol.net>
2934
2935         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
2936           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
2937           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
2938           src/regression/bool1.c, src/regression/bool2.c,
2939           src/regression/bool3.c, src/regression/call1.c,
2940           src/regression/compare.c, src/regression/compare10.c,
2941           src/regression/compare2.c, src/regression/compare3.c,
2942           src/regression/compare4.c, src/regression/compare5.c,
2943           src/regression/compare6.c, src/regression/compare7.c,
2944           src/regression/compare8.c, src/regression/compare9.c,
2945           src/regression/configword.c, src/regression/for.c,
2946           src/regression/inline.c, src/regression/mult1.c,
2947           src/regression/nestfor.c, src/regression/or1.c,
2948           src/regression/pointer1.c, src/regression/ptrfunc.c,
2949           src/regression/rotate1.c, src/regression/rotate2.c,
2950           src/regression/rotate3.c, src/regression/rotate4.c,
2951           src/regression/rotate5.c, src/regression/rotate6.c,
2952           src/regression/rotate7.c, src/regression/string1.c,
2953           src/regression/struct1.c, src/regression/sub.c,
2954           src/regression/sub2.c, src/regression/switch1.c,
2955           src/regression/while.c, src/regression/xor.c,
2956           src/regression/create_stc, src/regression/simulate,
2957           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
2958           regression tests
2959         * src/regression/gpsim_assert.h: added
2960
2961 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
2962
2963         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
2964         ((void (code *) (void)) 0) ();
2965         * as/hc08/aslex.c,
2966         * as/hc08/aslink.h,
2967         * as/hc08/asm.h,
2968         * as/hc08/asmain.c,
2969         * as/hc08/lkdata.c,
2970         * as/hc08/lklex.c,
2971         * as/hc08/lkmain.c,
2972         * as/mcs51/aslex.c,
2973         * as/mcs51/aslink.h,
2974         * as/mcs51/asm.h,
2975         * as/mcs51/asmain.c,
2976         * as/mcs51/lkdata.c,
2977         * as/mcs51/lklex.c,
2978         * as/mcs51/lkmain.c,
2979         * as/z80/aslex.c,
2980         * as/z80/asm.h,
2981         * as/z80/asmain.c: fixed build on current cygwin:
2982         replaced getline() by as_getline()
2983
2984 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
2985
2986         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
2987         declarator in the symbol chain
2988         * src/SDCCsymt.h,
2989         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
2990         parameter list for function pointers
2991         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
2992         * support/regression/tests/bug-716242.c: added
2993
2994 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
2995
2996         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
2997         offset if possible
2998         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
2999
3000 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
3001
3002         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
3003         inifinitely recurseable, added static
3004         * support/regression/tests/bug-1408066.c: added
3005
3006 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
3007
3008         * src/SDCCicode.h,
3009         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
3010         renamed, added possibility to create "postLoopLbl"-labels
3011         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
3012         newiTempLoopHeaderLabel
3013         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
3014         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
3015         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
3016         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
3017         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
3018         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
3019         (basicInduction): fixed bug #136564, made static,
3020         (loopInduction): changed parameter of basicInduction, made static,
3021         (addPostLoopBlock): added
3022         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
3023         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
3024         findLoopEndSeq
3025         * support/regression/tests/bug-136564.c: added
3026         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
3027         --std-sdcc99 to LIBSDCCFLAGS
3028
3029 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
3030
3031         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
3032         while loop
3033         * support/regression/tests/bug-1406131.c: added
3034
3035 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
3036
3037         * src/SDCCast.c (decorateType): fix promotion of unary minus
3038         * src/SDCCsymt.c (computeType): beautified
3039         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
3040         (valUnaryPM, valComplement): fix sign and promotion,
3041         (valNot): ANSI: result type is int (SDCC: unsigned char)
3042         * support/regression/tests/uminus.c: speedup by removing superflous
3043         test case 'int'
3044         * support/regression/tests/onebyte.c: added promotion and signedness
3045         tests for unary minus
3046         * support/regressions/tests/bug-477927.c: disable warning about
3047         uninitialized variables
3048         * support/regression/tests/not.c: added
3049
3050 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
3051
3052         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
3053         * src/mcs51/gen.c (gen51Code): show final register usage after
3054         fillGaps in asm with --i-code-in-asm
3055         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
3056         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
3057         incUsed, rliveClear, adjustIChain): made static,
3058         (setFromRange): excluded because it's unused,
3059         (findPrevUseSym, markWholeLoop): added,
3060         (findPrevUse): rewritten; fixes bug 895992; now a complete search
3061         through all branches of predecessors enables sdcc to emit the warning
3062         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
3063         (rlivePoint): made static, added parameter emitWarnings which is only
3064         true during the first run out of two,
3065         (findRecursiveSucc, findRecursivePred): removed,
3066         (computeLiveRanges): made static, added parameter emitWarnings,
3067         (dumpIcRlive): added for debugging only
3068         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
3069         removed prototype of setFromRange()
3070         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
3071         in call of computeLiveRanges()
3072         * support/regression/tests/bug-895992.c: added
3073         * support/regression/tests/bug-971834.c: added
3074         * support/valdiag/tests/bug-895992.c: added
3075         * support/valdiag/tests/bug-971834.c: added
3076
3077 2005-12-18 Raphael Neider <rneider AT web.de>
3078
3079         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
3080           (genUnpackBits): improved code for direct operands,
3081           (genPackBits): improved code for literal assignment to bitfields
3082             and for direct destination operands (no FSR indirection),
3083             prevented redundant AND, fixes #1362800,
3084           (AccLsh): added parameter to disable masking of the result
3085         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
3086           skip instructions with side-effects (like incfsz),
3087           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
3088         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
3089         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
3090           fixes #1375263
3091
3092 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
3093
3094         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
3095         volatile variables as spill location
3096
3097 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
3098
3099         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
3100         replacing literals
3101         * support/regression/tests/bug-1376320.c: added
3102
3103 2005-12-08 Raphael Neider <rneider AT web.de>
3104
3105         * src/pic/device.c: renamed is_shared to pic14_is_shared
3106         * src/pic/gen.c (genIfx): re-enabled handling of sbits
3107         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
3108           (is_valid_identifier): added for above workaround
3109
3110 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
3111
3112         * device/lib/Makefile.in: fixed to enable port-specific-objects
3113         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
3114           char, thanks Hubert Sack
3115         * doc/sdccman.lyx: documented --xstack-loc,
3116           elaborated a bit more on interrupts and pitfalls,
3117           removed "setjmp/longjmp unsupported",
3118           documented some unsupported C99 features
3119         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
3120         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
3121           if, thanks Hubert Sack
3122         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
3123         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
3124           make make_library
3125         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
3126           regression tests can report resource usage (rfe 700441)
3127         * support/regression/collate-results.py: report resource usage
3128         * support/regression/ports/ds390/spec.mk,
3129         * support/regression/ports/hc08/spec.mk,
3130         * support/regression/ports/mcs51/spec.mk,
3131         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
3132         * support/regression/ports/ds390/uCsim.cmd,
3133         * support/regression/ports/hc08/uCsim.cmd,
3134         * support/regression/ports/mcs51/uCsim.cmd,
3135         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
3136         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
3137           library, use the default one
3138         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
3139           building the library
3140
3141 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
3142
3143         * config.dsp: added dependency on .version and configure_vc.awk
3144         * device/include/setjmp.h: updated for --stack-auto and --xstack
3145         * device/include/mcs51/at89c51snd1c.h: corrected line endings
3146         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
3147         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
3148         * device/lib/libsdcc.lib: added _setjmp
3149         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
3150           (decorateType): fixed bug 1372851,
3151           (optimizeGetHbit): fixed warning
3152         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
3153           array initialisation
3154         * support/regression/tests/bug1057979.c: added test for bug 1358192
3155         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
3156
3157 2005-12-03 Borut Razem <borut.razem AT siol.net>
3158
3159         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
3160           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
3161
3162 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
3163
3164         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
3165         createIval): implement symbol independant "flexible array member",
3166         (createIvalCharPtr): implemented flexible array initialisation with a
3167         string
3168         * src/SDCCsymt.c (copyStruct): removed,
3169         (getSize): fixed misleading comment,
3170         (getAllocSize): removed, the additional allocation size is now in
3171         sym->flexArrayLength,
3172         (checkStructFlexArray): new, syntax checks for flexible array members,
3173         (compStructSize): added syntax checks for "flexible array members"
3174         (copyStruct): removed,
3175         (copyLinkChain): removed inefficient fix for bug 770487
3176         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
3177         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
3178         symbol->flexArrayLength
3179         * src/SDCCerr.c,
3180         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
3181         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
3182         * support/regression/tests/structflexarray.c: added
3183         * support/valdiag/tests/structflexiblearray.c: added
3184
3185 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
3186
3187         * src/SDCCast.c (decorateType): fixed bug 1368489
3188         * support/Util/SDCCerr.c,
3189         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
3190
3191 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3192
3193         * device/include/mcs51/at89c51snd1c.h: added file submitted by
3194           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
3195
3196 2005-11-27 Borut Razem <borut.razem AT siol.net>
3197
3198         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
3199           support/cpp2/mkdeps.h: added command line option
3200           -obj-ext=<extension> to SDCPP to define object file externion, used
3201           for generation of make dependencies (-M)
3202         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
3203
3204 2005-11-26 Borut Razem <borut.razem AT siol.net>
3205
3206         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
3207           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
3208           added pic and pic16 libraries
3209
3210 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3211
3212         * device/include/float.h: Corrected typo in prototype of __fsgt
3213
3214 2005-11-25 Borut Razem <borut.razem AT siol.net>
3215
3216         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
3217           added creation of model-mcs51-stack-auto libraries
3218
3219 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
3220
3221         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
3222         and fields-list too
3223         * src/SDCCast.c (createIvalArray): removed obsolete comment
3224
3225 2005-11-24 Borut Razem <borut.razem AT siol.net>
3226
3227         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
3228           added missing device/lib/mcs51/crt*.asm sources
3229
3230 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
3231
3232         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
3233
3234 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
3235
3236         * device/lib/_fs2schar.c,
3237         * device/lib/_fs2sint.c,
3238         * device/lib/_fs2slong.c: optimized inline asm
3239
3240 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3241
3242         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
3243           Better handling of floats between -1.0 and 0.0.
3244
3245 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3246
3247         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
3248           (the missing "if"s prohibited removal of redundant labels)
3249
3250 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3251
3252         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
3253           Properly convert floats between -1.0 and 0.0 to long, int, and char
3254           types (max integer value of negative floats tends to zero).
3255         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
3256           Removed changes made so to work properly with floats between
3257           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
3258           and _fs2char.c
3259
3260 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
3261
3262         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
3263         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
3264         (genCast) cosmetic change
3265         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
3266         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
3267         from mcs51
3268         * support/regression/tests/bitfields (testSignedBitfields): added
3269
3270 2005-11-18 Borut Razem <borut.razem AT siol.net>
3271
3272         * sdcc/device/lib/Makefile.in: remove all unnecessary files
3273         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
3274           introduced SILENT option to make building of pic16 libraries less
3275
3276 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3277
3278         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
3279           Now they work properly with floats between -1.0 and 0.0
3280         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
3281
3282 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
3283
3284         * src/SDCCicode.c (printOperand): added missing else
3285
3286 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
3287
3288         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
3289         reformatted for better readability
3290         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
3291         signed bitfields
3292
3293 2005-11-17 Borut Razem <borut.razem AT siol.net>
3294
3295         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
3296           introduced SILENT option to make building of pic16 libraries less
3297           verbose - used for nightly snapshot build
3298         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
3299           available on Win32 platforms.
3300         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
3301           medium, large, pic and pic16
3302
3303 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3304
3305         * device/lib/printf_large.c: Temporary patch for bug 1358192:
3306           printf("%f"...) sets fraction to zero.
3307
3308 2005-11-16 Raphael Neider <rneider AT web.de>
3309
3310         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
3311           fixes #1357221
3312         * src/pic/gen.c (genIfx): implemented for CARRY bit
3313         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
3314           to generic pointers, fixes #1357332,
3315           (pic16_movLit2f): NEW,
3316           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
3317
3318 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
3319
3320         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
3321
3322 2005-11-11 Raphael Neider <rneider AT web.de>
3323
3324         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
3325         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
3326           compute pointer's type from operand,
3327           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
3328           improved single bit reads, fixes bug #1353379
3329
3330 2005-11-09 Borut Razem <borut.razem AT siol.net>
3331
3332         * support/scripts/sdcc.nsi: added lib/pic to the package
3333
3334 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
3335
3336         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
3337
3338 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
3339
3340         * support/regression/tests/bug1348008.c: added
3341         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
3342         * support/regression/tests/bug1337835.c: updated comment
3343
3344 2005-11-06 Borut Razem <borut.razem AT siol.net>
3345
3346         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
3347           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
3348           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
3349           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
3350           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
3351           dynamic construction of cl_error_class and derivates - 2.nd try
3352
3353 2005-11-05 Borut Razem <borut.razem AT siol.net>
3354
3355         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
3356           bug, which caused Bus Errors on sparc solaris
3357
3358 2005-11-04 Borut Razem <borut.razem AT siol.net>
3359
3360         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
3361           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
3362           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
3363           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
3364           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
3365           and derivates to resolve the initialization problem on OSX
3366
3367 2005-11-02 Borut Razem <borut.razem AT siol.net>
3368
3369         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
3370           corrected typo - #include <winsock2.h>
3371
3372 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
3373
3374         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
3375           (_asxxxx_mapping): added org directive for future enhancements
3376
3377 2005-11-01 Borut Razem <borut.razem AT siol.net>
3378
3379         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
3380           enabled sockets on WIN32
3381         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
3382
3383 2005-10-31 Borut Razem <borut.razem AT siol.net>
3384
3385         * support/regression/generate-cases.py: escape backslashes in {testcase}:
3386           WIN32 backslash path delimiters should be escaped when used in C strings
3387         * support/regression/tests/bitfields.c: exclude failing assertions for
3388           __CYGWIN32__ and __MINGW32__ hosts
3389
3390 2005-10-30 Borut Razem <borut.razem AT siol.net>
3391
3392         * src/SDCCutil.c: corrected double comparison typo
3393
3394 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
3395
3396         * device/lib/medium/Makefile: added for new memory model medium
3397         * device/include/asm/mcs51/features.h: updated for medium/pdata
3398         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
3399           added Multiply & Accumulate sbit's and MAC0_PAGE define
3400         * device/include/mcs51/c8051f300.h: added sfr16 definitions
3401         * device/include/mcs51/c8051f310.h: added sfr16 definitions
3402         * device/lib/_mullong.c: update for medium model
3403         * device/lib/incl.mk: added medium model
3404         * doc/sdccman.lyx: documented medium model
3405         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
3406         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
3407         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
3408         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
3409           (allocParms): set SCLS and OCLS to pdata for medium model
3410         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
3411           for pdata,
3412           (powof2): return <0 if not power of 2
3413         * src/avr/gen.c (genBitWise): use updated powof2
3414         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
3415           (shiftR2Left2Result): small optimization in setup, save acc when storing,
3416           (shiftLLeftOrResult): use B if necessary
3417         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
3418         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
3419         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
3420         * support/regression/Makefile.in: added test-mcs51-medium
3421         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
3422
3423 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
3424
3425         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
3426         specifier unsigned
3427         * device/lib/time.c (mktime): fixed bug 1334315
3428
3429 2005-10-28 Raphael Neider <rneider AT web.de>
3430
3431         * device/include/pic/p16f_common.inc: added common declarations
3432         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
3433
3434 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
3435
3436         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
3437           (aopPutUsesAcc): added to predict accumulator use,
3438           (assignResultValue): save acc if necessary,
3439           (genMinusDec): store result if indirectly addressed,
3440           (genDivOneByte):  save acc if necessary,
3441           (movLeft2Result): bugfix if left already in acc,
3442           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
3443             attention to accumulator use (esp. pdata),
3444           (genReceive): receive pdata correctly
3445         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
3446         * src/SDCCicode.h: added isOperandInPagedSpace prototype
3447
3448 2005-10-27 Raphael Neider <rneider AT web.de>
3449
3450         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
3451
3452 2005-10-27 Raphael Neider <rneider AT web.de>
3453
3454         * .version: changed version to 2.5.4
3455         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
3456         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
3457           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
3458             arithmetics support routines
3459         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
3460         * device/lib/Makefile.in: also create installdir for pic
3461
3462         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
3463           pic14 port as well
3464         * src/pic/device.c (dump_sfr): rewritten to delegate register
3465           placement to the linker (use `extern sym' rather than sym EQU addr),
3466           (validAddress): fixed to check last specified address
3467         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
3468           (popGetLit): truncate literal value to 8 bit,
3469           (popGet): moved assert to more appropriate place
3470           (popGetExternal): create pCode operand from and mark the according
3471             symbol as being `extern'
3472           (popGetAddr): added sanity check on immediate's offset, provide
3473             GPOINTER tag on demand
3474           (aopPut): fixed for immediates,
3475           (mov2w_op): move operand's address or contents to WREG (depending on
3476             operand type), safer variant of mov2w,
3477           (movwf,call_libraryfunc): NEW, handy abbreviations,
3478           (get_argument_pcop,get_return_val_pcop,pass_argument,
3479           get_returnvalue): interface for accessing function parameters and
3480             return values,
3481           (assignResultValuei,genRet): use new parameter/return value interface
3482           (pic14_getDataSize): back to old version handling generic pointers,
3483           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
3484             provided implementation and/or fixed old one,
3485           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
3486             calls, removed legacy 8051 reference code
3487           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
3488           (loadSignToC): NEW, move the operands sign bit to CARRY,
3489           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
3490             genRightShiftSigned, accepts negative shift counts,
3491           (setup_fsr): load FSR and adjust IRP (indirect memory access),
3492           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
3493             generic pointers, __data pointers and __code pointers,
3494           (genUnpackBits,genPackBits): rewritten to work with generic pointers
3495             and signed bitfields, limit bitfields to 8 bit,
3496           (genDataPointerGet): fixed number of bytes read,
3497           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
3498           (genPointerGet,genPointerSet): fixed handling of __code pointers,
3499             pointers to constant data are no longer assumed to point to __code
3500             space, removed invalid pointer types,
3501           (bitpatternFromVal): retrieve the PICs representation of an integer
3502             or float literal,
3503           (genDataPointerSet): fixed assigning to po_immediate operands,
3504           (genGenPointerSet): implemented as library call,
3505           (genIfx): fixed incorrect condition,
3506           (genAddrOf): limit generic pointers' addresses to 2 bytes,
3507             provide GPOINTER tag according to destination's storage class,
3508           (genCast): added code to handle casting to generic pointers, added
3509             sign-/zero extension of the result
3510           (aop_isLitLike,op_isLitLike): fixed handling of immediates
3511         * src/pic/gen.h: added macros to access IRP bit in STATUS register
3512         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
3513           extend the result
3514         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
3515           address/register resides in the shared banks
3516           (emitSymbolToFile): improved to handle global and `pinned' symbols,
3517             put all variables into separate sections (have the linker arrange
3518             them)
3519           (picglue): put init code and interrupt handlers in separate sections
3520         * src/pic/main.c: added port specific options table, modified to PORT
3521           structure to make GPOINTERs 3 byte, added pic14_options
3522           (_pic14_do_link): private linking routine (update paths to libraries,
3523             add libsdcc.lib by default)
3524         * src/pic/main.h: declare pic14_options
3525         * src/pic/pcode.c: fixed instructions i/o relations,
3526           (RegCond): reverted to correct version,
3527           (newpCodeOpLit): truncate literals to 8 bit,
3528           (genericPrint): added debug output,
3529           (getRegFromInstruction): fixed for various operand types, simplified
3530           (BuildFlow): fixed broken handling of isntructions with labels
3531           (LinkFlow): start at last instruction in flow (skip trailing comments),
3532             pass the flow on to the next instruction after CALL
3533           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
3534           (insertPCodeInstruction): fixed inserting after a skip instruction,
3535           (DoBankSelect): fixed for labeled instructions
3536           (OptimizepBlock): honor --nopeep switch
3537           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
3538         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
3539         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
3540           (pCodeOptime2pCodes): allow disabling this optimization via
3541             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
3542             but is still buggy), started implementation of a dataflow based
3543             pCode optimization (CSE + dead code elimination)
3544           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
3545         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
3546           names are independant of the stack location and therefore portable across
3547           devices
3548
3549 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
3550
3551         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
3552           (selectSpil): fixed bug 1337835 by not spilling bit variables
3553         * support/regression/tests/bug1337835.c: added test for this bug
3554         * src/mcs51/peeph.def: restart after rule 3.c,
3555           addded rules 263.x to optimize loading constants
3556
3557 2005-10-26 Raphael Neider <rneider AT web.de>
3558
3559         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
3560         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
3561           (genAssign): emit warning when casting literals to generic pointer
3562             type, also applies when taking the address of a fixed variable,
3563           (genCast): improved casting to generic pointers
3564         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
3565           extern variables, added verbose error message
3566         * device/include/pic16/{string.h,errno.h}: added #pragma library c
3567
3568 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
3569
3570         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
3571         carry must be complemented too
3572         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
3573         could be emitted by genMinus
3574         * src/SDCCval.c (constVal): fixed bug 1305065
3575
3576 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
3577
3578         * src/SDCCast.c (addCast): added promotion for bit variables
3579         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
3580         promotion casts + optimisation
3581         (optimizeGetWord): fix warning 'i' might be used uninitialized
3582         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
3583         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
3584
3585 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
3586
3587         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
3588         all chars are promoted to int; promotion should be handled in SDCCast.c
3589
3590 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3591
3592         * device/lib/_strcmp.c: Fixed bug 1326457
3593
3594 2005-10-11 Raphael Neider <rneider AT web.de>
3595
3596         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
3597         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
3598
3599 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
3600
3601         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
3602         * support/regression/tests/sfr16.c: added test for the sfr32 bug
3603
3604 2005-10-04 Raphael Neider <rneider AT web.de>
3605
3606         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
3607           device/lib/pic16/pics.all: added pic18f1320
3608         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
3609
3610 2005-09-30 Raphael Neider <rneider AT web.de>
3611
3612         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
3613         * src/pic16/devices.inc: NEW, provides device descriptions
3614         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
3615
3616 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
3617
3618         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
3619           GETHBIT
3620
3621 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
3622
3623         * doc/sdccman.lyx: updated Highest Order Bit documentation,
3624           documented Any Order Bit, Higher Order Byte and Higher Order Word
3625         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
3626         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
3627           (optimizeGetAbit): new, to get any bit, not only the high bit,
3628           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
3629           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
3630           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
3631           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
3632             RIGHT_OP: also try GETBYTE, GETWORD optimization,
3633             GETABIT, GETBYTE, GETWORD: decorate them,
3634           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
3635           (ast_print): added GETABIT, GETBYTE, GETWORD
3636         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
3637         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
3638           (geniCodeBinary): new generic binary icode,
3639           (ast2iCode): added GETABIT, GETBYTE, GETWORD
3640         * src/port.h: updated comment for PORT.hasExtBitOp
3641         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
3642           (genGetByte): new, to get a single byte,
3643           (genGetWord): new, to get a word from a long,
3644           (gen51Code): added GETABIT, GETBYTE, GETWORD
3645         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
3646
3647 2005-09-23 Raphael Neider <rneider AT web.de>
3648
3649         * configure.in, configure: have device/lib/pic configured
3650         * device/lib/Makefile.in: added model-pic14
3651         * device/lib/clean.mk: added pic/ to clean rule
3652         * device/lib/pic: added rudimentary pic14 library providing support
3653           functions for multiplication/division/generic pointer access
3654         * src/SDCCopt.c (convilong): mark support functions as extern
3655           for pic14 port as well
3656         * src/pic/gen.c (genMult): added assertions,
3657           (genpic14Code): emit warning on unhandled iCodes
3658         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
3659         * src/pic/pcode.c (pCodeOpCopy),
3660         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
3661           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
3662           SFR_REGISTER}), made safe for future extensions
3663         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
3664           instructions even if preceeded by SKIP instructions (also remove
3665           them); removed unused code
3666         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
3667           prevents leaving parts of the structure uninitialized after copying
3668
3669 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
3670
3671         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
3672           ago by me
3673         * support/regression/tests/addsub.c: added test for the bug
3674
3675 2005-09-21 Raphael Neider <rneider AT web.de>
3676
3677         * device/include/pic16/pic18f1220.h,
3678           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
3679         * device/lib/pic16/Makefile.rules: added missing opening paren
3680         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
3681           are provided in genutils.c,
3682           (genUminusFloat,genUminus,genCmpEq): added asserts on different
3683           operand/result sizes,
3684           (genCmp): assert on NULL pointers first, then check deref'ed values
3685         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
3686           result size
3687
3688 2005-09-18 Raphael Neider <rneider AT web.de>
3689
3690         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
3691           as these are now unused,
3692           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
3693         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
3694           local, avoids uninitialized pointer dereference on r->name
3695         * src/pic16/ralloc.c (newReg): fixed indentation
3696
3697 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
3698
3699         * src/SDCCval.c (constVal): fixed bug 730366
3700         * support/Util/SDCCerr.c,
3701         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
3702
3703 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
3704
3705         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
3706
3707 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
3708
3709         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
3710
3711 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
3712
3713         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
3714           (hex2dec): made hex_digit unsigned char, removed ascii dependance
3715         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
3716           (hex2dec): made hex_digit unsigned char, removed ascii dependance
3717         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
3718         * packihx/packihx.c (hexDigit): made c unsigned char
3719         * as/mcs51/lklibr.c (fndsym),
3720         * link/z80/lkgb.c (gb),
3721         * link/z80/lklibr.c (fndsym),
3722         * link/z80/lkrloc.c (relr),
3723         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
3724         * src/SDCC.lex (checkCurrFile, process_pragma),
3725         * src/SDCCglue.c (spacesToUnderscores),
3726         * src/SDCCmain.c (setParseWithComma, processFile),
3727         * src/asm.c (tvsprintf, printCLine),
3728         * src/avr/gen.c (emitcode, aopPut),
3729         * src/ds390/gen.c (emitcode),
3730         * src/hc08/gen.c (emitcode, emitinline),
3731         * src/mcs51/gen.c (emitcode, genInline),
3732         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
3733           tokenizeLineNode),
3734         * src/pic/ralloc.c (debugLog),
3735         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
3736           tokenizeLineNode),
3737         * src/pic16/ralloc.c (debugLog),
3738         * src/z80/main.c (_process_pragma):
3739            made all ctype.h function calls safe
3740         * src/SDCCopt.c: include math.h for fabs
3741         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
3742           and used them throughout the code to make ctype.h function calls safe
3743         * src/ds390/main.c (asmLineNodeFromLineNode),
3744         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
3745         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
3746            unsigned char*
3747         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
3748           (newpCodeAsmDir): made ctype.h function calls safe
3749         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
3750           pic16_emitcode):  made lbp unsigned char*
3751         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
3752           (pic16_newpCodeAsmDir): made ctype.h function calls safe
3753         * src/xa51/gen.c (emitcode),
3754         * src/z80/gen.c (_emit2): made lbp unsigned char*
3755         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
3756            char*
3757
3758 2005-09-05 Raphael Neider <rneider AT web.de>
3759
3760         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
3761           access bank splitpoint
3762
3763 2005-09-05 Raphael Neider <rneider AT web.de>
3764
3765         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
3766
3767 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
3768
3769         * .version: changed to version 2.5.3
3770         * doc/sdccman.lyx: changed version to 2.5.3,
3771           documented --codeseg and --constseg and pragma codeseg and constseg,
3772           documented bit parameters (reentrant) and bit returning
3773         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
3774            currFunc->recvSize, but is this ok for all ports?
3775           (ast2iCode): result of ~ on unsigned char must be cast to int for
3776            bool to work
3777         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
3778           function pointers in bit space
3779         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
3780           (processFuncArgs): call port.reg_parm() with reentrancy info
3781         * src/port.h,
3782         * src/avr/main.c,
3783         * src/ds390/main.c,
3784         * src/hc08/main.c,
3785         * src/pic/main.c,
3786         * src/pic16/main.c,
3787         * src/xa51/main.c,
3788         * src/z80/main.c: port.reg_parm prototype extended with
3789           "bool reentrant" parameter
3790         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
3791           options.stackAuto for allocating bit register parameters
3792         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
3793           (genSend): set BitBankUsed if it is,
3794           (selectRegBank): factored out of genCall for use in genPcall,
3795           (genCall): removed redundant dtype assignmen, use selectRegBank,
3796           (genPcall): handle returning in Carry properly, save in F0 if needed,
3797           (genReceive): handle bit register parameters
3798         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
3799           (mcs51_assignRegisters): enable bit registers for all reentrant
3800            functions and don't set BitBankUsed unconditionally
3801         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
3802         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
3803         * support/regression/tests/funptrs.c: added tests for BOOL and for return
3804
3805 2005-08-27 Borut Razem <borut.razem AT siol.net>
3806
3807         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
3808         ppc-osx (Darwin) does not support -u option. It seems that it is
3809         supported only on Linux - GNU cp
3810
3811 2005-08-25 Borut Razem <borut.razem AT siol.net>
3812
3813         * sim/ucsim/gui.src/serio.src/Makefile.in,
3814           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
3815           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
3816           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
3817           install and strip, since the strip at /usr/ccs/bin should be used
3818           on solaris
3819
3820 2005-08-24 Borut Razem <borut.razem AT siol.net>
3821
3822         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
3823
3824 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
3825
3826         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
3827         ffffffffu
3828
3829 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
3830
3831         * as/mcs51/aslink.h: completed lkrloc.c prototypes
3832         * as/mcs51/lkmain.c (link_main): fixed warning
3833         * device/include/stdbool.h: ds390 has no advanced bit support yet
3834         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
3835         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
3836         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
3837           and updated their macros
3838         * src/SDCCval.c (constVal): updated comment for renamed b_long
3839
3840 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
3841
3842         * as/mcs51/asdata.c: changed ctype['['] to BINOP
3843         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
3844           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
3845           (oprio): set priority for '['
3846         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
3847            and adb_24_bit
3848         * as/mcs51/asm.h: added defines R_BIT and S_BIT
3849         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
3850         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
3851         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
3852           added overlayable BIT_BANK area
3853         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
3854           (summary2): explain 'T' in legenda
3855         * as/mcs51/lkrloc.c: replaced old K&R style,
3856           (relr): added R_BIT processing,
3857           (errmsg): added "Bit-addressable relocation error",
3858           (adb_bit): added for converting from byte- to bit-addressable space,
3859           (adb_24_bit): added for converting from byte- to bit-addressable space
3860         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
3861            used in reentrant functions now even as return value
3862         * device/lib/_gptrput.c (_gptrput): removed obsolete code
3863         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
3864           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
3865         * src/SDCCglobl.h: added indicator BitBankUsed
3866         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
3867            the bit registers b0-b7
3868         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
3869           (geniCodeCast): fixed bug 1263853,
3870           (geniCodeLogicAndOr): put result in bool or char,
3871           (geniCodeReceive): added parameter func for accessing the return type,
3872           (geniCodeFunctionBody): pass func to geniCodeReceive
3873         * src/SDCCmain.c: added indicator BitBankUsed
3874         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
3875         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
3876           (checkSClass): don't put automatic bool/bit on stack,
3877           (checkFunction): removed check on function cannot return bit
3878         * src/SDCCsymt.h: added newBoolLink prototype
3879         * src/mcs51/gen.c (rb1regs): added bit registers,
3880           (movc): created for assigning to carry,
3881           (pushReg, popReg): created for pushing registers,
3882           (sameRegs): check both AOP_REG and AOP_CRY types,
3883           (aopOp): handle bit registers,
3884           (aopPut): optimization no self-assign,
3885           (saveRegisters): push reg->base (bits) only once for bit registers,
3886            and use pushReg,
3887           (unsaveRegisters): pop reg->base only once and use popReg,
3888           (assignResultValue): added parameter func and return in carry for bits,
3889           (genIpush): optimization no reload in A if not changed,
3890           (genSend): bit parameters in reentrant functions are passed in bit
3891            registers by first assigning to bits in B, then save registers and
3892            copy B to bits,
3893           (genCall): handle returning in Carry properly, save it in F0 if needed,
3894           (genPcall): updated assignResultValue call, this is not safe yet for bit
3895            returning function !!!
3896           (genFunction): don't generate equ's for bit registers and use pushReg,
3897           (genEndFunction): take care of bit returning functions and use popReg,
3898           (genRet): return bit in Carry,
3899           (genIfx): optimize bit registers and other directly addressable bits,
3900           (genReceive): updated assignResultValue call
3901         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
3902           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
3903            registers when using stack-auto
3904         * src/mcs51/ralloc.c (_G): added allBitregs,
3905           (regs8051): added the bit registers,
3906           (createStackSpil): use macro IS_BIT,
3907           (getRegBit): added to allocate a bit register, else spill,
3908           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
3909           (updateRegUsage): factored out to ease stepping while debugging,
3910           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
3911            also allocate bit registers,
3912           (fillGaps): handle bit registers,
3913           (findAllBitregs): added to create bit vector with all bit registers,
3914           (mcs51_allBitregs): returns this bit vector,
3915           (mcs51_assignRegisters): when using stack-auto use bit registers for
3916            passing parameters and creating local variables
3917         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
3918
3919 2005-08-22 Borut Razem <borut.razem AT siol.net>
3920
3921         * device/lib/Makefile.in: replaced find option -or with -o
3922           to make it run on solaris
3923
3924 2005-08-22 Raphael Neider <rneider AT web.de>
3925
3926         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
3927           fixes #1265442 (crash on Solaris)
3928
3929 2005-08-20 Borut Razem <borut.razem AT siol.net>
3930
3931         * configure, configure.in: added tests for libsocket and libnsl libraries,
3932           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
3933           from support/regression/Makefile.in
3934         * support/regression/Makefile.in: added
3935         * device/lib/pic16/Makefile.common.in: force make to use bash shell
3936         * sim/ucsim/libtool: regenerated on sparc-solaris
3937         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
3938           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
3939           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
3940           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
3941           sparc-solaris, which doesn't use GNU ld linker
3942         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
3943         * as/Makefile: find on sparc-solaris does not support -maxdepth option
3944
3945 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
3946
3947         * src/mcs51/peeph.def: updated comments
3948
3949 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3950
3951         * device/lib/_gptrget.c,
3952         * device/lib/_gptrput.c: slightly shorter
3953         * doc/sdccman.lyx: incremented version
3954         * src/mcs51/peeph.def: moved peephole comments to the line of first
3955           change to better keep line correlation, reanimated 186.e
3956         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
3957
3958 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
3959
3960         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
3961           David Saxton with quotes around file name.
3962
3963 2005-08-15 Borut Razem <borut.razem AT siol.net>
3964
3965         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
3966           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
3967           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
3968           make tests run on x86_64 platform
3969
3970 2005-08-13 Raphael Neider <rneider AT web.de>
3971
3972         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
3973           as it might be executed DURING a build (parallel make is wonderful)
3974
3975 2005-08-13 Raphael Neider <rneider AT web.de>
3976
3977         * device/lib/Makefile.in (port-specific-objects-pic16):
3978           revert to cp $(PORT)/bin/*.* $(PORTDIR)
3979         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
3980           dependency
3981         * device/lib/pic16/Makefile.rules: build subdirs before creating
3982           the library, removed builddir rule, create $(builddir) early in
3983           recurse rule, use empty recurse rule for leaf directories
3984         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
3985           mkdir errors (race condition), removed duplicate suffix "hex"
3986           from clean rules
3987         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
3988         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
3989           prevents mkdir -p from aborting on Alpha
3990
3991 2005-08-12 Raphael Neider <rneider AT web.de>
3992
3993         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
3994           db-statements in order to allow for arrays of pointers in code
3995           sections to be placed without interspersed 0-padding, fixes
3996           bug #1256215
3997         * (emitStatistics): fixed division by zero for pic18f1220
3998         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
3999           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
4000         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
4001         * (pic16_pCodeConstString): keep track of already emitted string
4002           literals to prevent "duplicate definitions of symbol _str_NR"
4003         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
4004           debug message
4005         * device/lib/Makefile.in: ignore failing PIC16 library builds
4006         * device/lib/pic16/Makefile: do not build if gputils are missing
4007         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
4008
4009 2005-08-10 Raphael Neider <rneider AT web.de>
4010
4011         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
4012           my last commit)
4013
4014 2005-08-10 Raphael Neider <rneider AT web.de>
4015
4016         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
4017           Rokas' patch to add the new fixed point type "__fixed16x16"
4018         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
4019           functions for __fixed16x16 arithmetics
4020         * device/lib/pic16: reimplemented the build system to support
4021           a separate build directory, better handling of libio (create
4022           the library in a separate subdir for each architecture) and
4023           easier configuration (centralized in Makefile.common)
4024
4025 2005-08-07 Raphael Neider <rneider AT web.de>
4026
4027         * src/pic16/gen.c (genrshTwo): fixed sign extension
4028         * src/pic16/device.c: added pic18f2320, 4220 and 4320
4029         * device/include/pic16/pic18f2220.h: changed some bit definitions,
4030           added T0CONbits
4031         * device/include/pic16/pic18f4220.h: NEW, header for
4032           pic18f4220 and pic18f4320
4033         * device/include/pic16/pic18fregs.h: added new devices,
4034           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
4035         * device/include/pic16/signal.h: resolved name clashes
4036           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
4037           to also allow testing for interrupt enable bits, added
4038           comments on how to use the macros
4039         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
4040         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
4041           register definitions for the devices
4042         * device/lib/pic16/pics.all: added new devices
4043         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
4044           allocated memory
4045         * device/lib/pic16/libc/stdlib/memfree: do not count
4046           the block header as free memory
4047         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
4048           simplified and added missing end-of-blocklist-marker
4049           (reported by Peter Onion, fixes #1252814)
4050         * (_mergeHeapBlock): fixed loop condition
4051         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
4052           len==0, restructured code
4053         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
4054           up a bit, reduced bitfield accesses, prevent endless loops
4055           in case of heap corruption
4056         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
4057           "unreferenced arguments/must return a value" warnings
4058         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
4059           replaced BAUDREG with SPBRG
4060         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
4061           device/lib/pic16/debug/gstack/gstack.c: replaced
4062           _naked, _asm, _endasm with __naked, __asm, __endasm
4063
4064 2005-08-05 Raphael Neider <rneider AT web.de>
4065
4066         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
4067           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
4068
4069 2005-08-05 Borut Razem <borut.razem AT siol.net>
4070
4071         * device/lib/Makefile.in: added missing ';'
4072         * configure: removed ^M characters
4073
4074 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4075
4076         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
4077           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
4078           License
4079
4080 2005-08-04 Borut Razem <borut.razem AT siol.net>
4081
4082         * configure.in: pic16 libraries build 2nd try - enable running
4083           configure in device/lib/pic16
4084         * configure: regenerated from configure.in
4085         * device/lib/Makefile.in: create $(PORT)/bin directory
4086
4087 2005-08-03 Raphael Neider <rneider AT web.de>
4088
4089         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
4090           to get/set values via pointers
4091         * (genUnpackBits,genPackBits): changed detection of
4092           ptr->bitfield vs. sym.bitfield, fixed access via generic
4093           pointers, removed dead (wrong) code for multibyte bitfields
4094         * (genNearPointerGet, genGenPointerGet): removed useless code,
4095           fixed bitfield detection, fixes #1250594
4096         * (genNearPointerSet): removed useless code
4097         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
4098           and introduced macro pic16_emitpcode that conditionally emits
4099           the origin of the following pCode (useful for debugging SDCC)
4100         * src/pic16/pcode.c: changed (and disabled) some debug outputs
4101         * (createDefmap): fixed handling of LFSR for --optimize-df
4102
4103 2005-08-02 Borut Razem <borut.razem AT siol.net>
4104
4105         * device/lib/Makefile.in: pic16 libraries build enabled since
4106           gputils-0.13.2 are now localy installed at sourceforge's compile farm
4107
4108 2005-08-02 Raphael Neider <rneider AT web.de>
4109
4110         * src/pic16/gen.c (genPackBits): removed deprecated warning
4111         * (genGenPointerSet): fixed bitfield detection
4112
4113 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4114
4115         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
4116
4117 2005-07-31 Raphael Neider <rneider AT web.de>
4118
4119         * device/lib/pic16/libdev/pic18f458.c,
4120           device/include/pic16/pic18f458.h: added missing T0CONbits
4121
4122 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
4123
4124         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
4125
4126 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
4127
4128         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
4129
4130 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4131
4132         * device/include/mcs51/at89c51ed2.h: added.
4133
4134 2005-07-23 Raphael Neider <rneider AT web.de>
4135
4136         * src/pic/gen.h: added emitpcode macro for debugging
4137         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
4138           and replace by macro adding debug information on demand
4139         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
4140         * (gencjne): tried to fix; replaced with correct (slower) code
4141         * (gen{Unp,P}ackBits): fixed single bit access
4142         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
4143         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
4144           previous instruction
4145         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
4146           register has to be handled with care (forbidding movement
4147           of assignments/uses, removing assignments completely, ...)
4148         * (pCodeOptime2pCodes): make use of regIsSpecial
4149         * added lots of debugging output (commented out)
4150         * src/pic/rallloc.c (deassignLRs): prevent operand registers
4151           from being reused as result UNLESS it is known to work
4152
4153 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
4154
4155         * support/Util/dbuf.h: include <stddef.h> for size_t
4156         * .version: changed to version 2.5.2
4157
4158 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4159
4160         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
4161
4162 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4163
4164         * src/hc08/gen.c (genMinus): fixed bug #1241835,
4165           (genModOneByte): removed needless psha/pula
4166
4167 2005-07-22 Raphael Neider <rneider AT web.de>
4168
4169         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
4170           have PIC14 handled like PIC16, fixes broken pic14 linker calls
4171         * src/pic/gen.c (resolveIfx): do not "invent" labels
4172         * (genSkipc): changed to positive logic
4173         * (genSkipCond): removed as no longer needed
4174         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
4175           backport from PIC16
4176         * (genLeftShift): check operands are in different registers
4177         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
4178           INCF does not update CARRY...
4179         * src/pic/main.c: fixed _linkCmd
4180         * src/pic/pcode.c (unlinkpCode): added inactive code
4181         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
4182           alive (do not assign result and operand overlapping registers)
4183
4184 2005-07-22 Raphael Neider <rneider AT web.de>
4185
4186         * src/pic/device.c (dump_sfr): replaced register declaration with
4187           call to emitSymbolToFile() to avoid duplicate symbols
4188         * (assignRelocatableRegisters): do not declare external symbols
4189         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
4190           right (take size of type, not etype)
4191         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
4192         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
4193         * (packRegsForAccUse): disabled assignment of WREG as
4194           the result reg to prevent occurence of just fixed #1235003,
4195           fixes #1242954
4196         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
4197           symbols (avoids duplicate symbols in .asm file)
4198         * (pic14emitRegularMap): use emitSymbolToFile()
4199         * src/pic/gen.c (aopOp): fixed spillLocation handling
4200         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
4201         * (genDataPointerSet): removed unneccessary variables/output
4202
4203 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
4204
4205         * as/mcs51/lkarea.c: enlarged codemap for banked memory
4206         * device/lib/mcs51/crtbank.asm: added # to 0x0F
4207
4208 2005-07-21 Raphael Neider <rneider AT web.de>
4209
4210         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
4211           architecture cannot handle them efficiently, fixes bug #1235003
4212         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
4213           check for empty sets before using them (fixes bug #1232190)
4214
4215 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
4216
4217         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
4218           (lnksect2): generate warnings for memory overlap
4219         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
4220           constseg to set the name of these segments so you can instruct the linker
4221           to place them in banks
4222         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
4223         * src/SDCCglobl.h: added MODEL_HUGE to enum,
4224           added code_seg and const_seg to options
4225         * src/SDCCglue.c (emitMaps): use options.const_seg,
4226           (createInterruptVect): put interrupt vectors in segment HOME,
4227           (glue): put HOME before static segment and put the main glue in HOME,
4228           (glue): use options.code_seg
4229         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
4230         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
4231           these segments so you can instruct the linker to place them in banks
4232           (linkEdit): use code_loc for HOME segment which should be the first
4233           segment in code memory now
4234         * src/SDCCmem.c: fixed more stuff like bug 1238386
4235         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
4236           (changePointer): don't change function pointers to code pointers for
4237           banked functions,
4238           (compareType): added exceptional check for banked function pointers
4239         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
4240         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
4241           after static in code memory
4242         * src/mcs51/gen.c: added aopLiteralLong prototype,
4243           (aopForSym): use getSize for functions,
4244           (genCall): generate banked calls over one trampoline __sdcc_banked_call
4245           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
4246           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
4247           the segment,
4248           (genPcall): use call for literal function pointers and generate banked
4249           calls over the one trampoline so there's only one place for the user to
4250           modify according to his/hers hardware,
4251           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
4252           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
4253         * src/mcs51/main.c: added keyword banked,
4254           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
4255         * support/Util/SDCCerr.c,
4256         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
4257           needed for passing the bank and address to the trampoline
4258         * device/lib/mcs51/crtbank.asm: added for bankswitching
4259         * device/lib/mcs51/Makefile: added crtbank
4260
4261 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4262
4263         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
4264           for fields at offset 0 of a struct or union as reported
4265           on 2005-07-07 in the developer mailing list.
4266
4267 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
4268
4269         * src/SDCCmem.c: fixed bug 1238386
4270
4271 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4272
4273         * src/mcs51/peeph.def: added labelrefcounting for peepholes
4274           (patch #1144962), added peephole 300, enabled 259.x
4275         * doc/sdccman.lyx: removed screenshot and provided link instead
4276
4277 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4278
4279         * doc/sdccman.lyx: added section about debugging with ddd
4280         * doc/figures/ddd_example.eps: screenshot of debugging session
4281
4282 2005-07-04 Raphael Neider <rneider AT web.de>
4283
4284         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
4285           like CODE pointers, fixes #1115683
4286         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
4287           call, fixes bugs #1232211, #1228110,
4288           fixed wrong casts to pCodeFlow from pCodeInstructions
4289
4290 2005-07-04 Raphael Neider <rneider AT web.de>
4291
4292         * src/pic/gen.c (popGet): changed assert to allow for
4293           bit operands
4294         * (popGetAddr): changed signature to provide
4295           an additional index, patched all call sites
4296         * (genCmpEq): handle literal-like operands correctly
4297         * (genAddrOf): added sanity checks on __code/__data pointers
4298         * (genAssign): added handling of symbols from __code section
4299         * (gencjne): do not generate code for comparisons whose result
4300           is neither stored nor used, fixes bug #1171114
4301         * (AccLsh, AccRsh): operate on operand instead of WREG
4302         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
4303           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
4304           by known count
4305         * rewrote complete shift-by-literal logic, commented unused
4306           functions out
4307         * (genConstPointerGet): get multiple bytes (if result size > 1),
4308           fixed handling of non-immediate addresses
4309         * (genPointerGet): handle CODE pointers like CONST pointers
4310         * (genpic14Code): insert C-SRC lines as Cource-pCodes
4311         * ({aop,op}_isLitLike): NEW, single place to decide whether an
4312           operand is to be treated as a literal or not
4313         * (mov2w,genPcall,genCmpEq),
4314           src/pic/genarith.c: use aop_isLitLike() to decide between
4315           literal/register contents
4316         * (addSign): added missing offset
4317         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
4318           only emit comment in debug-mode,
4319           use {aop,op}_isLitLike throughout the file
4320         * src/pic/glue.c: fix initializers for pointers (work in progress)
4321         * src/pic/pcode.c (get_op): honor index on _const symbols
4322         * ({reset,dump}pCodeStatistics): NEW, estimate code size
4323         * (dumppBlock): added pCode size estimation
4324         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
4325           check for IS_SYMOP before OP_SYMBOL'ing
4326         * fixed indentation, compacted switch-statements
4327         * (allocReg): find free register and allocate it instead of
4328           allocating new registers all the time
4329         * (deassignLRs): prevent POINTER_GET's from being assigned the same
4330           registers as its operands (necessary only for multibyte GETs)
4331
4332 2005-07-01 Raphael Neider <rneider AT web.de>
4333
4334         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
4335           debugging .asm-output macros FENTRY + FEXIT
4336         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
4337           way... I wonder...
4338         * (emitpComment): NEW, printf to pCode
4339         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
4340           offset handling
4341         * (popGetAddr): NEW, variant of popGet to access an immediates
4342           high(er) bytes instead of the n'th byte of memory they reference,
4343           replaced popGet with popGetAddr where neccessary
4344         * (genDataPointerGet): reactivated and fixed implementation
4345         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
4346           accesses
4347         * (genDataPointerSet): fixed multibyte assignments
4348         * (genpic14Code): fixed --i-code-in-asm handling
4349         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
4350         * (genPlus): fixed index-out-of-bounds error
4351         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
4352         * src/pic/ralloc.c: added debugging output macro FENTRY2
4353         * (spillThis): fixed indentation, enbraced for-body for clarity
4354         * (rematStr): commented out as now unused
4355         * (regTypeNum): commented out special spill case (overwrites
4356           arbitrary values)
4357         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
4358
4359 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
4360
4361         * doc/sdccman.lyx: documented sfr16/sfr32,
4362           added example for using storage class with function pointers
4363         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
4364
4365 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
4366
4367         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
4368         * device/lib/_itoa.c,
4369         * device/lib/_ltoa.c: optimized codesize
4370         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
4371           but don't know how to suppress the double warning.
4372         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
4373         * support/Util/SDCCerr.c,
4374         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
4375
4376 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
4377
4378         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
4379           fixed old K&R prototypes
4380         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
4381         * device/lib/_gptrget.c,
4382         * device/lib/_gptrgetc.c,
4383         * device/lib/_gptrput.c: changed versions for new memory indicator values,
4384           also new versions for small generic pointers and banked generic pointers
4385         * src/port.h: added const_name
4386         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
4387         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
4388         * src/SDCCcse.c (findPrevIc): check all associative operators
4389         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
4390         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
4391         * src/SDCCmem.c: updated comments,
4392           set far-space to 0 for pdata, results in optimized code
4393         * src/SDCCmem.h: added macro CONST_NAME
4394         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
4395           moving the info into the highest bits, see also gptrget/gptrput
4396         * src/src.dsp: added sdcc.ico to project files
4397         * src/avr/gen.c (genCast): fixed bug 0x%d
4398         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
4399         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
4400           relation between ptr_type and DCL_TYPE,
4401           (genCast): fixed bug 0x%d
4402         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
4403           (CODE)" for const_name
4404         * src/hc08/gen.c (genCast): fixed bug 0x%d
4405         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
4406           (hc08_port): added "CONST (CODE)" for const_name
4407         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
4408           (aopForRemat, adjustArithmeticResult): disconnected direct relation
4409           between ptr_type and DCL_TYPE,
4410           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
4411           operand* and took AOP() inside function so sfr-ness can be checked,
4412           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
4413           new prototype,
4414           (genFunction, genEndFunction): optimized stack setup,
4415           (genMinus): optimized for literals with ending zeroes (in bytes),
4416           (genCast): fixed bug 0x%d
4417         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
4418           (mcs51_port): added "CONST (CODE)" for const_name
4419         * src/mcs51/peeph.def: made rule 226 more generic
4420         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
4421         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
4422         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
4423         * src/z80/main.c (z80_port): added NULL for const_name,
4424           (gbz80_port): added NULL for const_name
4425         * support/regression/tests/bug663539.c,
4426         * support/regression/tests/sfr16.c: new tests
4427
4428 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4429
4430         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
4431
4432 2005-06-24 Raphael Neider <rneider AT web.de>
4433
4434         * device/lib/pic16/libdev/pic18f[68][567]20.c:
4435           corrected typos...
4436         * device/include/pic16/signal.h: added USBIF
4437           and SIG_USB
4438
4439 2005-06-24 Raphael Neider <rneider AT web.de>
4440
4441         * device/lib/pic16/libdev/pic18f2455.c,
4442           device/include/pic16/pic18f2455.h: NEW
4443         * device/include/pic16/pic18fregs.h,
4444           device/lib/pic16/pics.all,
4445           src/pic16/device.c: added 18f2455
4446         * device/lib/pic16/libdev/pic18f[68][567]20.c,
4447           device/include/pic16/{pic18f[68][567].h,usart.h}:
4448           replaced MULTIPLE_USARTS define with more relaible
4449           compatibility sfrs (for USART access)
4450
4451 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
4452
4453         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
4454           and the output asm file line is printed on two lines.
4455
4456 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4457
4458         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
4459           BGT, BLE, BHI, and BLS instructions
4460         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
4461           genCmpEq): removed
4462         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
4463           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
4464           fixes bug #1216342
4465         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
4466
4467 2005-06-15 Raphael Neider <rneider AT web.de>
4468
4469         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
4470         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
4471         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
4472           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
4473           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
4474
4475 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4476
4477         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
4478           Marcel Telka in bug #1215704
4479
4480 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
4481
4482         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
4483           located in shared memory bank.
4484
4485 2005-05-31 Raphael Neider <rneider AT web.de>
4486
4487         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
4488           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
4489           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
4490
4491 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
4492
4493         * device/lib/_strncpy.c: fixed the fix
4494
4495 2005-05-26 Raphael Neider <rneider AT web.de>
4496
4497         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
4498           initializers with \0, bug #1208187
4499         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
4500           intializers with \0, bug #1208187
4501
4502 2005-05-26 Raphael Neider <rneider AT web.de>
4503
4504         * src/pic16/glue.c (pic16_printIvalChar): fixed string
4505           initializers with \0, bug #1208187
4506         * src/pic16/main.c (_process_pragma): added sanity checks
4507           for stack position and size, emit warnings when appropriate
4508
4509 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
4510
4511         * device/lib/_strncpy.c: fixed not filling with \0
4512
4513 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4514
4515         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
4516           createFunction),
4517         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
4518           compound_statement),
4519         * src/SDCCsymt.h,
4520         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
4521
4522 2005-05-24 Raphael Neider <rneider AT web.de>
4523
4524         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
4525
4526 2005-05-24 Raphael Neider <rneider AT web.de>
4527
4528         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
4529           TRISE definitions, closes bug #1162453
4530
4531 2005-05-22 Raphael Neider <rneider AT web.de>
4532
4533         * src/pic16/main.c (_process_pragma): check for missing
4534           arguments to pragmas code and udata
4535         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
4536           consistency fixes to match other headers (thanks to Jim Paris)
4537         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
4538
4539 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
4540
4541         * src/SDCCicode.c (isOperandEqual): fixed missing ;
4542
4543 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
4544
4545         * support/regression/tests/bug1198642.c: new test
4546         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
4547         * src/SDCCcse.c (findPrevIc): added comment, please have a look
4548         * support/scripts/resource.h,
4549         * support/scripts/resource.rc,
4550         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
4551         * support/scripts/sdcc.ico: added 32x32 icon
4552
4553 2005-05-18 Raphael Neider <rneider AT web.de>
4554
4555         * device/lib/pic16/libdev/pic18f*.c,
4556         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
4557           keywords to "__sfr" and "__at (X)"
4558         * device/include/pic16/pic18fregs.h: added pic18f4520
4559         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
4560           #1203088 (MPLAB compatibility)
4561
4562 2005-05-17 Raphael Neider <rneider AT web.de>
4563
4564         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
4565         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
4566         * device/lib/pic16/pics.all: added new devices
4567         * src/pic16/device.c: added support for pic18f4520
4568
4569 2005-05-16 Raphael Neider <rneider AT web.de>
4570         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
4571         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
4572         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
4573           convenience function for bit access
4574
4575 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
4576
4577         * device/lib/printf_large.c: fixed bug 1193299
4578         * support/regression/tests/bug1057979.c: added test %3.3s
4579
4580 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4581
4582         * device/include/mcs51/8051.h,
4583         * device/include/mcs51/8052.h: made parseable with lint
4584         * device/include/mcs51/lint.h: added include file for (sp)lint
4585         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
4586         * doc/cdbfileformat.lyx,
4587         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
4588
4589 2005-05-14 Raphael Neider <rneider AT web.de>
4590
4591         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
4592         * device/lib/pic16/libc/stdlib/itoa.c (new)
4593         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
4594         * device/lib/pic16/libio/Makefile: exclude subdir according to
4595           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
4596         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
4597         * src/pic16/gen.c (genFunction): prevent annoying warning
4598         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
4599           nameclashes on BeOS
4600         * support/cpp2/cppmain.c (cpp_output_string): new
4601         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
4602           fixes bug 1116802
4603
4604 2005-05-13 Borut Razem <borut.razem AT siol.net>
4605
4606         * src/SDCCmain.c (linkEdit): fixed bug 1195202
4607
4608 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4609
4610         * .version: changed to version 2.5.1; back to bleeding edge development
4611
4612 2005-05-11 Borut Razem <borut.razem AT siol.net>
4613
4614         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
4615           generate PDF version 1.3 documents
4616
4617 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4618
4619         * .version: changed to version 2.5.0
4620
4621 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4622
4623         * doc/sdccman.lyx: updated weblinks, index and smaller updates
4624
4625 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4626
4627         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
4628         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
4629         well as many smaller updates.
4630         * .version: changed to version 2.5.0-pre1
4631
4632 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4633
4634         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
4635
4636 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
4637
4638         * support/regression/tests/bug1185672.c: added
4639         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
4640           bug 1185672
4641         * src/mcs51/gen.c (genCall): added comments, made it look safer
4642         * src/mcs51/gen.c (genEndFunction): simplified
4643
4644 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
4645
4646         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
4647
4648 2005-04-14 Borut Razem <borut.razem AT siol.net>
4649
4650         * fixed bug 1045046 - SIGSEGV with really simple code?:
4651           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
4652           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
4653
4654 2005-04-14 Borut Razem <borut.razem AT siol.net>
4655
4656         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
4657           src/pic16/device.h: temporarily disabled experimental #inline pragma
4658           for 2.5.0 release
4659
4660 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
4661
4662         * device/include/z80/stdio.h,
4663         * device/include/z80/string.h: removed these highly incomplete files so
4664           SDCC can use the default ones in device/include/
4665
4666 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4667
4668         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
4669         gcc warning.
4670         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
4671         fix sdcpp warnings.
4672
4673 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
4674
4675         * device/include/malloc.h: removed redundant __reentrant prototypes
4676         * device/lib/_mullong.c: added working xstack variant in asm (C version
4677           doesn't pass regression tests)
4678         * device/lib/bpx.c: used __data and made bpx char for mcs51
4679         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
4680           (createFunction): fixed bug with xstackPtr
4681         * src/SDCCcse.c: corrected comments
4682         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
4683           (killDeadCode, eBBlockFromiCode): removed unused code
4684         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
4685           corrected comments
4686         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
4687           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
4688           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
4689           (genModOneByte): fixed warning in MSVC
4690         * src/mcs51/main.c (): added comments
4691         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
4692
4693 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
4694
4695         * src/SDCCmain.c (linkEdit): oops, changed one line too many
4696
4697 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
4698
4699         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
4700
4701 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
4702
4703         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
4704         characters arrays of larger size than the declared one.
4705
4706 2005-04-10 Borut Razem <borut.razem AT siol.net>
4707
4708         * src/pic/gen.c (genInline),
4709           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
4710           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
4711           (findNextInstruction), (findPrevInstruction),
4712           (findInstructionUsingLabel),
4713           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
4714         * src/pic/pcode.c (findLabel): added missing '\n'
4715         * src/src.dsp: added SDCCdwarf2.c to the project
4716
4717 2005-04-09 Borut Razem <borut.razem AT siol.net>
4718
4719         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
4720
4721 2005-04-08 Raphael Neider <rneider AT web.de>
4722
4723         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
4724           into the chain after a given one) and mergeDefmapSymbols (combine
4725           defmap entries for each symbol per pcode)
4726         * (createDefmap): have defmap entries merged in the end
4727         * (defmapReplaceSymRef): split defmap entries covering two accesses to
4728           a symbol before replacing one access type's symbol, merge symbols in
4729           the end (replacement symbol might already have an entry)
4730         * (assignValnums): keep reference to written WREG intact
4731
4732 2005-04-08 Raphael Neider <rneider AT web.de>
4733
4734         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
4735           Alpha)
4736
4737 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
4738
4739         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
4740         bytes
4741
4742 2005-04-07 Raphael Neider <rneider AT web.de>
4743
4744         * device/include/pic16/usart.h: added compatibility defines for
4745           devices with more than one USART
4746         * device/include/pic16/pic18f[68][567]20.h: activated above defines
4747
4748 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
4749
4750         * device/lib/Makefile.in: updated for port specific include
4751
4752 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
4753
4754         * support/regression/ports/mcs51/spec.mk: added mcs51 include
4755
4756 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
4757
4758         * device/include/8051.h,
4759         * device/include/8052.h,
4760         * device/include/at89S8252.h,
4761         * device/include/at89c55.h,
4762         * device/include/at89x051.h,
4763         * device/include/at89x51.h,
4764         * device/include/at89x52.h,
4765         * device/include/mcs51reg.h,
4766         * device/include/reg51.h,
4767         * device/include/reg764.h,
4768         * device/include/regc515c.h,
4769         * device/include/sab80515.h: (re)moved these 12 files
4770         * device/include/mcs51/8051.h,
4771         * device/include/mcs51/8052.h,
4772         * device/include/mcs51/at89S8252.h,
4773         * device/include/mcs51/at89c55.h,
4774         * device/include/mcs51/at89x051.h,
4775         * device/include/mcs51/at89x51.h,
4776         * device/include/mcs51/at89x52.h,
4777         * device/include/mcs51/mcs51reg.h,
4778         * device/include/mcs51/reg51.h,
4779         * device/include/mcs51/reg764.h,
4780         * device/include/mcs51/regc515c.h,
4781         * device/include/mcs51/sab80515.h: and added them here
4782
4783 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
4784
4785         * device/include/stdarg.h: changed SDCC specific keywords to double
4786           underlined form.
4787         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
4788           mcs51 and ds390.
4789         * device/include/hc08/mc68hc908gp32.h,
4790         * device/include/hc08/mc68hc908jb8.h,
4791         * device/include/hc08/mc68hc908jkjl.h,
4792         * device/include/hc08/mc68hc908qy.h: fixed comments
4793         * device/include/mcs51/README: updated
4794         * device/include/mcs51/c8051f120.h: added PINRSF
4795         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
4796         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
4797           amidst code. Also inline is not supported.
4798
4799 2005-04-06 Raphael Neider <rneider AT web.de>
4800
4801         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
4802         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
4803           callers stack/frame pointers
4804
4805 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
4806
4807         * device/include/pic16/usart.h: added, missing in previous commit,
4808         * device/include/pic16/adc.h: fixed typo,
4809         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
4810         commit,
4811         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
4812         <p18fxxx.inc>
4813         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
4814         uninitialized because a bug appears with gplink
4815         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
4816         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
4817         complains for unrecognised option
4818
4819 2005-04-05 Raphael Neider <rneider AT web.de>
4820
4821         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
4822           structs as well (using memcpy)
4823         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
4824           on ISRs (GOTO has no label)
4825         * src/pic16/device.h: added OF_OPTIMIZE_DF
4826         * src/pic16/main.c: added compiler switch --optimize-df to enable the
4827           new data flow analysis/optimization
4828         * src/pic16/pcode.c: added (prototypes for and implementation of)
4829           dataflow analysis functions, fixed pCodeInstructions' inCond and
4830           outCond values, made RCALL a branch instruction
4831         * (pic16_unlinkpCode): keep C line if possible
4832         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
4833           C line moved if possible
4834         * (pic16_getRegFrompCodeOp): NEW, improved version of...
4835         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
4836           to use new pic16_getRegFrompCodeOp (works for more SFRs)
4837         * (pic16_BuildFlow): fixed skip instructions with label (did not start
4838           new flow)
4839         * (pic16_getJumptabpCode): NEW, needed in...
4840         * (LinkFlow): fixed handling of jumptables, calls and conditional
4841           branches
4842         * (pic16_InsertCommentAfter): NEW
4843         * (pic16_pCodeReplace): made verbose and flow preserving
4844         * (AnalyzeFlow): added call to data flow analysis
4845         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
4846         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
4847         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
4848
4849 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4850
4851         * src/SDCCast.c (decorateType): fixed bug #1105626
4852
4853 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
4854
4855         * device/include/asm/pic16/features.h,
4856         * pic18f*.h headers,
4857         * device/include/pic16/adc.h,
4858         * device/include/pic16/delay.h,
4859         * device/include/pic16/i2c.h,
4860         * device/include/pic16/malloc.h,
4861         * device/include/pic16/stdio.h,
4862         * device/include/pic16/stdlib.h,
4863         * device/include/pic16/string.h,
4864         * device/lib/pic16/libc/stdio/printf_tiny.c,
4865         * device/lib/pic16/libc/stdio/printf_small.c,
4866         * device/lib/pic16/libc/stdio/strmgpsim.c,
4867         * device/lib/pic16/libc/stdio/strmmssp.c,
4868         * device/lib/pic16/libc/stdio/strmusart.c,
4869         * device/lib/pic16/libc/stdio/vfprintf.c,
4870         * device/lib/pic16/libc/stdlib/ltoa.c,
4871         * device/lib/pic16/libc/stdlib/putchar.c,
4872         * device/lib/pic16/libc/stdlib/x_ftoa.c,
4873         * device/lib/pic16/libc/stdlib/memchrpgm.c,
4874         * device/lib/pic16/libc/stdlib/memchrram.c,
4875         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
4876         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
4877         * device/lib/pic16/libio/adc/adcbusy.c,
4878         * device/lib/pic16/libio/adc/adcread.c,
4879         * device/lib/pic16/libio/adc/adcsetch.c,
4880         * device/lib/pic16/libio/usart/ubaud.c,
4881         * device/lib/pic16/libio/usart/ubusy.c,
4882         * device/lib/pic16/libio/usart/udrdy.c,
4883         * device/lib/pic16/libio/usart/uopen.c,
4884         * device/lib/pic16/libio/usart/uputc.c,
4885         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
4886         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
4887         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
4888         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
4889         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
4890         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
4891         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
4892         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
4893         specific keywords to double underlined form,
4894         * device/lib/pic16/libc/Makefile.rules,
4895         * device/lib/pic16/libsdcc/Makefile.rules,
4896         * device/lib/pic16/libm/Makefile,
4897         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
4898         to compile with C standard set in Makefile.common
4899         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
4900         rand.c and crc.c in compilation process,
4901         * device/lib/pic16/libsdcc/int/divuint.c,
4902         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
4903         `c' from signed to unsigned,
4904         * device/lib/pic16/startup/crt0.c,
4905         * device/lib/pic16/startup/crt0i.c,
4906         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
4907         keywords to double underlined form, bug fixes in _do_cinit function
4908         which prevented the correct initialization of the .idata segment,
4909         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
4910         core to enter a infinite loop
4911         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
4912
4913 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4914
4915         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
4916
4917 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4918
4919         * device/include/Makefile.in: add support for hc08 subdirectory
4920         * device/include/hc08/: new subdirectory
4921         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
4922         Lucas Loizaga, thanks!
4923         * device/include/hc08/mc68hc908qy.h,
4924         * device/include/hc08/mc68hc908gp32.h,
4925         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
4926         their own directory. Changed internal macro names to use the compiler
4927         reserved namespace. Changed SDCC specific keywords to double
4928         underlined form.
4929         * device/include/math.h,
4930         * device/include/malloc.h,
4931         * device/include/stdarg.h,
4932         * device/include/stdbool.h
4933         * device/include/string.h,
4934         * device/include/tinibios.h,
4935         * device/include/ds400rom.h,
4936         * device/include/8051.h,
4937         * device/include/8052.h,
4938         * device/include/80c51xa.h,
4939         * device/include/at89c55.h,
4940         * device/include/at89S8252.h,
4941         * device/include/at89x51.h,
4942         * device/include/at89x52.h,
4943         * device/include/ds80c390.h,
4944         * device/include/reg764.h,
4945         * device/include/regc515c.h,
4946         * device/include/sab80515.h,
4947         * device/include/mcs51/c8051f000.h,
4948         * device/include/mcs51/c8051f018.h,
4949         * device/include/mcs51/c8051f020.h,
4950         * device/include/mcs51/c8051f040.h,
4951         * device/include/mcs51/c8051f060.h,
4952         * device/include/mcs51/c8051f120.h,
4953         * device/include/mcs51/c8051f300.h,
4954         * device/include/mcs51/c8051f310.h,
4955         * device/include/mcs51/c8051f320.h,
4956         * device/include/mcs51/c8051f330.h,
4957         * device/include/mcs51/c8051f350.h,
4958         * device/include/z180.h: Changed SDCC specific keywords to double
4959         underlined form.
4960
4961 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
4962
4963         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
4964         18F4455,
4965         * (pic16_assignConfigWordValue): disable testing of configuration
4966         register value with config mask,
4967         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
4968         function with port->fun_prefix,
4969         * (genFunction): when generating a naked interrupt function never
4970         create an absolute segment placed in interrupt vector address, place
4971         the actual interrupt function at IVA instead, when an interrupt
4972         function is generated with unspecified interrupt then do not create
4973         the absolute section,
4974         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
4975         code for generating a call to generic pointer get/put function with
4976         a call to function pic16_callGenericPointer(),
4977         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
4978         the call to the generic pointer get/put functions with prefixing the
4979         function name with port->fun_prefix,
4980         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
4981         * src/pic16/main.c (_process_pragma): prefix function with
4982         port->fun_prefix,
4983         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
4984         calling assembler, old 18Fxxxx macro is deprecated,
4985         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
4986         PC_ASMDIR in while condition,
4987         * (findInstruction): add PC_ASMDIR in while condition,
4988         * (buildCallTree): prefix main with port->fun_prefix,
4989         * (pic16_pCode2str): fixed bug that didn't emit the memory access
4990         identifier for variable with banked access in instructions BTFSS,
4991         BTFSC, BCF, BSF, BTG
4992         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
4993         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
4994         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
4995         perform optimization when enviroment variable NO_REG_OPT is set,
4996         * (insideLRBlock): NEW, return 1 if register is inside an
4997         INF_LOCALREGS block,
4998         * (RemoveRegFromLRBlock): remove a register that is completely
4999         eliminated by register optimization, but it is still left in local
5000         register store/restore in/from stack block,
5001         * (Remove2pcodes): after removing register, check to see if it
5002         should be removed from local register store/restore in/from stack
5003         block,
5004         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
5005         DUMMY_READ_VOLATILE,
5006
5007         * device/include/pic16/adc.h: minor prototype modifications and
5008         update,
5009         * device/include/pic16/malloc.h: added GPL notice various
5010         modifications,
5011         * device/include/pic16/stdint.h: NEW, standard header for ints
5012         * device/include/pic16/delay.h: NEW, header for delay functions,
5013         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
5014         delay1mtcy,
5015         * device/include/pic16/signal.h: NEW, header providing helper macros
5016         for implementing signal handlers,
5017         * device/include/pic16/stdio.h: added prototypes for functions,
5018         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
5019         prototypes for stdin and stdout, added macro PUTCHAR to
5020         automatically implement putchar function prototype,
5021         * device/include/pic16/usart.h: modified and updated USART library,
5022         * device/lib/pic16/libio/adc/,
5023         * device/lib/pic16/libio/i2c: some modifications to improve library
5024         performance,
5025         * device/lib/pic16/libc/stdio/: modifications for the new printf*
5026         family of functions,
5027         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
5028         family of functions and other sources,
5029         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
5030         of the PIC18Fxx[28] devices,
5031         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
5032         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
5033         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
5034         _do_cinit function, because the previous failed when local variables
5035         where not placed in the same memory bank,
5036         * device/lib/pic16/libsdcc/char/: various modifications to improve
5037         library performance,
5038         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
5039         information on the new functions of the c library and more...
5040
5041 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5042
5043         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
5044
5045 2005-03-26 Raphael Neider <rneider AT web.de>
5046
5047         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
5048           if condition == CARRY)
5049         * (genCmp): adapted to new genSkipc semantics
5050         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
5051           on rIfx (genCmp was broken)
5052
5053 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5054
5055         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
5056         * src/z80/main.c (_keywords[]),
5057         * src/SDCCglobal.h (struct options),
5058         * src/SDCC.y,
5059         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
5060         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
5061         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
5062         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
5063         always available in leading double underscore form. The C99 support is
5064         mostly missing, but it's a start.
5065         * support/regression/tests/bug-227710.c: fixed nonconforming use of
5066         reserved identifier "__data".
5067
5068 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
5069
5070         * src/mcs51/peeph.def: fixed bug 1170013
5071
5072 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
5073
5074         * device/include/mcs51reg.h: fixed bug 842007
5075
5076 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5077
5078         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
5079         last time.
5080
5081 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5082
5083         * src/port.h (struct PORT),
5084         * src/avr/ralloc.c (avr_assignRegisters),
5085         * src/avr/main.c,
5086         * src/ds390/ralloc.c (ds390_assignRegisters),
5087         * src/ds390/main.c,
5088         * src/hc08/ralloc.c (hc08_assignRegisters),
5089         * src/hc08/main.c,
5090         * src/mcs51/ralloc.c (mcs51_assignRegisters),
5091         * src/mcs51/main.c,
5092         * src/pic/ralloc.c (pic14_assignRegisters),
5093         * src/pic/main.c,
5094         * src/pic16/ralloc.c (pic16_assignRegisters),
5095         * src/pic16/main.c,
5096         * src/xa51/ralloc.c (xa51_assignRegisters),
5097         * src/xa51/main.c,
5098         * src/z80/ralloc.c (z80_assignRegisters),
5099         * src/z80/ralloc.h,
5100         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
5101         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
5102         * src/SDCCcse.h,
5103         * src/SDCCdflow.c (computeDataFlow),
5104         * src/SDCCdflow.h,
5105         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
5106         * src/SDCCloop.h,
5107         * src/SDCCcflow.c (*),
5108         * src/SDCCcflow.h,
5109         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
5110         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
5111         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
5112         immedDom() returning wrong block; probably fixes bug #1160833)
5113
5114 2005-03-20 Borut Razem <borut.razem AT siol.net>
5115
5116         * support/scripts/inc2h.pl: WIN32 port
5117
5118 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
5119
5120         * device/lib/makefile.in: added abs.c and labs.c
5121
5122 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
5123
5124         * device/include/stdint.h: added
5125         * device/lib/abs.c: added
5126         * device/lib/labs.c: added
5127         * device/include/stdlib.h: added abs() and labs() prototypes
5128         * device/lib/libsdcc.lib: added abs and labs
5129         * device/include/float.h,
5130         * device/lib/_fsmul.c,
5131         * device/lib/printf_fast.c,
5132         * device/lib/printf_tiny.c: updated comments
5133
5134 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5135
5136         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
5137         bug #1164313
5138
5139 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5140
5141         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
5142         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
5143
5144 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
5145
5146         * device/lib/printf_large.c: removed inline assembly for portability and
5147           readability. Use printf_fast if speed or size are more important.
5148         * src/pic16/gen.c: removed conditions around use of DEBUGpc
5149         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
5150
5151 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
5152
5153         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
5154         prevent compiler warning
5155
5156 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
5157
5158         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
5159         moved to level 0 and declared as static. Also they are explicit
5160         placed in access bank. This was necessery because some times they
5161         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
5162         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
5163         optimizations. Currently only compare to unsigned char is implemented,
5164         * src/pic16/gen.c: added fReturnIdx array,
5165         * (struct resolvedIfx) is moved to gen.h and made public,
5166         * (struct _G): added sregsAlloc and sregsAllocSet fields,
5167         * (aopForSym): added an optimization to directly store in stack of
5168         the operand of a SEND iCode,
5169         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
5170         but as registers instead (AOP_REG) using the fReturnIdx array,
5171         * (pic16_freeAsmop): remove the freed register from the
5172         _G.sregsAlloc field,
5173         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
5174         a compare of 'WREG',
5175         * (pic16_popGetTempRegCond): changed function prototype, now
5176         function takes also a bitVector argument v which holds the current
5177         set of registers that are allocated for stack access by aopForSym,
5178         registers allocated in aopForSym for accessing stack symbols are not
5179         any more part of the functions usedRegs field,
5180         * (genCall): some times aopOp is called for a stack variable to be
5181         send, aopForSym might perform the push, if this is true make sure
5182         that genCall doesn't push the variable twice by testing _G.resDirect,
5183         * (genFunction): changed testing for unspecified interrupt number
5184         from 256 to INTNO_UNSPEC,
5185         * modified selection scheme of frame pointer generation. Previously
5186         if function did use local registers a frame pointer was generated,
5187         now a frame pointer is generated only if function has arguments
5188         (that need PLUSW2 register access), or has stack arguments, or the
5189         compiler is not instructed to omit the frame pointer,
5190         * (genEndFunction): before restoring local registers that were saved
5191         in the function preamble, also restore the registers that *might*
5192         have been allocated for stack access,
5193         * (genRet): removed some old comments,
5194         * (genCmp, the active (RN's) version): added a call to the
5195         pic16_genCmp_special function to perform the compare with a more
5196         robust and optimized way,
5197         * (genInline): a feature has been added in inline code generation,
5198         which allows a wildcard variable substitution when writing inline
5199         assembly. Code is incomplete and experimental therefore undocumented,
5200         * (genCast): changed order of aopOp for result and right to allow
5201         aopForSym to directly load the result if possible,
5202         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
5203         perform an optimized compare on some selected special occasions,
5204         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
5205         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
5206         generate an IVT any more,
5207         * src/pic16/main.c (pic16_optionsTable): added command line option
5208         --optimize-cmp,
5209         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
5210         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
5211         macros,
5212         * src/pic16/NOTES: Raphael Neider added in list of active developers
5213         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
5214         jumptable_end to prevent bug #,
5215         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
5216         inCond and outCond fields,
5217         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
5218         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
5219         turn off register spilling,
5220         * (packRegsForOneUse): synced with other ports' versions although it
5221         is not used currently,
5222         * (pic16_packRegisters): added an optimization while reading
5223         structure bitfields, some registers may be saved (malloc code is
5224         decreased by 80 bytes)
5225
5226 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
5227
5228         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
5229         left is a bitfield, if yes, then don't optimize assignment. Perhaps
5230         this can be optimized more?
5231
5232 2005-03-10 Raphael Neider <rneider AT web.de>
5233
5234         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
5235           genNearPointerGet): (hopefully) fixed access to bitfields via
5236           pointers (p->bitN = x; and x = p->bitN; failed)
5237
5238 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
5239
5240         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
5241
5242 2005-03-09 Raphael Neider <rneider AT web.de>
5243
5244         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
5245
5246 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
5247
5248         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
5249         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
5250           (regTypeNum): set REG_BIT type if necessary
5251         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
5252         * support/regression/tests/critical.c: check bug 1144613
5253
5254 2005-03-02 Raphael Neider <rneider AT web.de>
5255
5256         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
5257
5258 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5259
5260         * src/avr/ralloc.c (serialRegAssign),
5261         * src/ds390/ralloc.c (serialRegAssign),
5262         * src/hc08/ralloc.c (serialRegAssign),
5263         * src/mcs51/ralloc.c (serialRegAssign),
5264         * src/pic/ralloc.c (serialRegAssign),
5265         * src/pic16/ralloc.c (serialRegAssign),
5266         * src/xa51/ralloc.c (serialRegAssign),
5267         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
5268
5269 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
5270
5271         * src/SDCCast.c (decorateType): fixed bug 1124787
5272
5273 2005-02-20 Hubert Sack <sack AT digiplan.de>
5274         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5275
5276         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
5277         patch #1121755
5278
5279 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5280
5281         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
5282         to keep the correct label reference count when adding/removing references
5283         to labels. A peephole file using this is appended to patch #1144962.
5284
5285 2005-02-14 Raphael Neider <rneider AT web.de>
5286
5287         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
5288         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
5289         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
5290           retrievals of result operand's value on assignment
5291
5292 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
5293
5294         * device/include/pic16/string.h: modified prototype for memccpy()
5295         to memccpy(void *, void *, char, size_t)
5296         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
5297         check whether to omit frame pointer or not,
5298         * (genInline): convert all occurences of "\n" to LF in inline
5299         assembler blocks, this helps formatting the inline text,
5300         * (pic16_loadFSR0): modified prototype,
5301         * (genNearPointerGet, genNearPointerSet): reorganization of code,
5302         removed some 8051 legacy code,
5303         * (genPackBits): enabled handling bitfields exceeding one byte in size,
5304         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
5305         before allocating temporary registers in functions,
5306
5307 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
5308
5309         * support/regression/tests/bitvars.c: corrected the "fix"
5310
5311 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
5312
5313         * support/regression/tests/bitvars.c,
5314         * support/regression/tests/bitwise.c,
5315         * support/regression/tests/rotate.c: "fixed" problems on Alpha
5316
5317 2005-02-10 Raphael Neider <rneider AT web.de>
5318
5319         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
5320           different size for Alpha
5321         * src/pic16/gen.c (genCmpEq) : improved compare with 0
5322
5323 2005-02-09 Raphael Neider <rneider AT web.de>
5324
5325         * src/SDCC.lex(doPragma) : save and restore warning options as well
5326           (also added new stack plus clone- and copyAndFreeSDCCERRG())
5327         * have #pragma less_pedantic set the errorlevel to WARNING
5328           (fixes #1117001)
5329         * (cloneOptimize) : fixed wrong malloc's size
5330         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
5331           facilitate correct handling of #pragma (save|restore)
5332
5333 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
5334
5335         * src/mcs51/gen.c: removed non-standard C nameless struct/union
5336
5337 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
5338
5339         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
5340
5341 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
5342
5343         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
5344
5345 2005-02-02 Raphael Neider <rneider AT web.de>
5346
5347         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
5348         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
5349         * (pic16_storeForReturn): fixed to allow returning function pointers
5350         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
5351         * device/include/pic16/{stddef.h,stdbool.h}: added
5352
5353 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
5354
5355         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
5356
5357 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
5358
5359         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
5360         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
5361          appeared to be required
5362
5363 2005-01-31 Borut Razem <borut.razem AT siol.net>
5364
5365         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
5366           include/mcs51 and include/z80 directories to the package
5367
5368 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5369
5370         * src/hc08/gen.c (genFunction): fixed bug #1112752
5371
5372 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5373
5374         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
5375
5376 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5377
5378         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
5379
5380 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
5381
5382         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
5383
5384 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
5385
5386         * device/include/c8051fxxx.h: removed these 6 files
5387         * device/include/mcs51/c8051fxxx.h: added these 11 new files
5388
5389 2005-01-26 Raphael Neider <rneider AT web.de>
5390
5391         * src/pic16/gen.c (genAssign): fixed assignment from longs
5392           in codespace (were cut to three bytes)
5393         * (genDummyRead): implemented (except for CODESPACE...),
5394           fixed bug #1108575
5395         * src/pic16/glue.c (emitStatistics): beautified
5396         * device/lib/pic16/libm/Makefile: added include path
5397
5398 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5399
5400         * src/z80/gen.c (aopPut): fixed bug #1103902
5401
5402 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5403
5404         * device/lib/expf.c: fixed bug #1095792
5405
5406 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
5407
5408         * device/lib/pic16/libm: added Math library sources
5409
5410 2005-01-24 Raphael Neider <rneider AT web.de>
5411
5412         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
5413           to enable upcast to pCodeOpReg2 (there is no type tag to
5414           differenciate the two and pic16_popGet2p cast into PCOR2)
5415         * src/pic16/main.c (_process_pragma): fixed another malloc bug
5416           (sizeof(sectNames) changed to sizeof(sectName))
5417           Both patches fix segfaults under MinGW.
5418
5419 2005-01-23 Raphael Neider <rneider AT web.de>
5420
5421         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
5422           Safe_[mc]?alloc()'ed variables
5423         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
5424           of (byte sized) temporaries (assign them to WREG for now)
5425         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
5426           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
5427           this might fix SIGSEGVs on MinGW...
5428         * src/SDCCopt.c (killDeadCode): restored original behaviour
5429           (volatile operands might get thrown away though)
5430
5431 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
5432
5433         * src/pic16/gen.c: fixed bug #1106975,
5434         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
5435         pointer update, INTCON is saved, global interrupts are disabled and
5436         restored after updateing TOS.
5437         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
5438         * added function attribute 'shadowregs' to take advantage of shadow
5439         registers,
5440         * added function attribute 'wparam' as an alternative to the wparam
5441         pragma,
5442         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
5443         user declares a non-ISR function as 'shadowregs',
5444         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
5445
5446 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
5447
5448         * .version: bumped version number to 2.4.8
5449         * device/lib/pic16/pics.all: list of PIC18F devices supported by
5450         pic16 port,
5451         * device/lib/pic16/libio/i2c/: I2C module support library,
5452         * device/include/pic16/i2c.h: I2C support library header,
5453         * device/lib/pic16/libc/stdio/: standard IO support sources,
5454         * (printf_small.c): printf_small() source, supports float print,
5455         * (printf_tiny.c): printf_tiny() source, does not support floats,
5456         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
5457         enable global optimizations for entire library source, other
5458         Makefiles in the source tree are also modified to reflect this,
5459         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
5460         function,
5461         * doc/sdccman.lyx: updated to reflect new changes,
5462         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
5463         sym->onStack if-case,
5464         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
5465         sbit, idata, _idata, xdata, _xdata,
5466         * added pragma library, to link an external library, (see doc),
5467         * removed command line options, --pomit-config-words, --pomit-ivt,
5468         --pleave-reset-vector,
5469         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
5470         when calling assembler to reflect memory model used, also define
5471         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
5472         reflect stack model used,
5473         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
5474         on stack return NULL,
5475
5476 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
5477
5478         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
5479           of the operands is volatile. Fixes #1020220
5480
5481 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
5482
5483         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
5484         * (OptimizeRegUsage): make sure that there is really no other flow where
5485           the first pCode is used
5486
5487 2005-01-22 Raphael Neider <rneider AT web.de>
5488
5489         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
5490           to fix #1106967 (pCode->seq are not set up correctly)
5491
5492 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5493
5494         * src/SDCCglue.c (glue): make sure code area is declared before the
5495         static initialization area.
5496
5497 2005-01-21 Raphael Neider <rneider AT web.de>
5498
5499         * device/lib/Makefile.in: fixed test for pic16 install dir
5500         * device/lib/pic16/*/Makefile*: modified compile flags to enable
5501           optimizations
5502         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
5503           added --optimize-goto compiler switch and pragma wparam documentation
5504         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
5505         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
5506           and PRODH closing bug #1071770 (peephole optimizer)
5507
5508 2005-01-19 Raphael Neider <rneider AT web.de>
5509
5510         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
5511           cmdLine buffers (used when calling sdcpp...) are large enough
5512           (MAX_PATH=256 truncates arguments leading to system halts when
5513           used in MinGW...)
5514         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
5515         * (genUminus): rewritten to for efficiency
5516         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
5517           used uninitialized in some cases)
5518         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
5519           copy the third byte from the int -- now assumes 0x80 (data memory)
5520         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
5521           operands (genAddLit expects the iCode's operands to swapped as
5522           well), fixed leftover bytes (crashed for short left operands)
5523         * (pic16_genMinusDec): performance improvements, removed false
5524           PIC14 emitSKPNCs
5525         * (pic16_genMinus): fixed to cope with differently sized operands
5526         * src/pic16/glue.c (pic16_glue): added new banksel optimization
5527           for --obanksel > 1
5528         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
5529         * src/pic16/graph.[ch]: implementation of directed graphs, used by
5530           new banksel optimization
5531         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
5532           analysis for temporary registers (segfaults...)
5533         * src/pic16/peeph.def: added rule
5534
5535 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
5536
5537         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
5538         which converts a float number to its ASCII representation
5539         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
5540         functions to convert the fractional and integer part of a float to ASCII,
5541         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
5542         realloc.c): added _MALLOC_SPEC to explicit place variables in data
5543         ram
5544         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
5545         _STATMEM macros,
5546         * device/include/pic16/adc.h: added GPL info,
5547         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
5548         a pCodeOp as tested operand,
5549         * (genNearPointerGet): optimized bit testing, does not use
5550         intermediate register for bit value, test directly instead with
5551         BTFSS, BTFSC, works only for single bits,
5552         * (genpic16Code): dump the name of the iCode in the asm,
5553         * src/pic16/ralloc.c (decodeOp): removed static declaration and
5554         renamed to pic16_decodeOp,
5555         * (serialRegAssign): do not allocate a temporary register for iCode
5556         sequences that test a single bit for 1/0
5557
5558 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
5559
5560         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
5561         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
5562         access stack and frame pointers. They are initially assigned to
5563         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
5564         accessing SFRs. Updated all occurences of modification of stack or
5565         frame pointer in gen.c and pcode.c,
5566         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
5567         assigning of a literal value to pointers,
5568         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
5569         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
5570         selected
5571
5572 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
5573
5574         * doc/sdccman.lyx: update documentation about stack pragma, added
5575         some info for stack memory models
5576
5577 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5578
5579         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
5580
5581 2005-01-08 Raphael Neider <rneider AT web.de>
5582
5583         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
5584           udata sections to fix bug #1097823
5585
5586 2005-01-05 Raphael Neider <rneider AT web.de>
5587
5588         * src/pic16/gen.c (genGenericShift): added handling of differently
5589           sized left operand and result
5590
5591 2005-01-04 Raphael Neider <rneider AT web.de>
5592
5593         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
5594         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
5595           to hold the condition bit)
5596         * added new version of genCmp (old code available via #define)
5597         * added new version of genShiftLeft/genShiftRight in a generic
5598           way, now supports shifting by negative values
5599         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
5600           shiftCount (expected by genGenericShift)
5601         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
5602         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
5603           dump
5604         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
5605           is an invalid literal too...)
5606
5607 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
5608
5609         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
5610         from Raphael Neider,
5611         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
5612         for 8-bit literals. This fixes some literal operands which are sign
5613         extended to 16-bits ints when instruction needs only 8-bits.
5614
5615 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
5616
5617         * device/lib/logf.c: added mcs51 assembly version
5618         * device/lib/expf.c: added mcs51 assembly version
5619         * device/lib/_logexpf.c: new shared asm code for expf and logf
5620         * device/include/math.h: add defines for assembly math library
5621         * device/lib/Makefile.in: build new _logexpf.c
5622         * device/lib/libfloat.lib: use new _logexpf.c
5623
5624 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
5625
5626         * src/pic/device.c
5627         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
5628           device types which have less than 0x7f registers.
5629
5630 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
5631
5632         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
5633
5634 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
5635
5636         * device/lib/printf_fast.c: only build on supported arch.
5637         * device/lib/printf_tiny.c: only build on supported arch.
5638         * device/lib/printf_fast_f.c: only build if asm float lib
5639         * device/lib/_fsget1arg.c: only build if asm float lib
5640         * device/lib/_fsget2args.c: only build if asm float lib
5641         * device/lib/_fsnormalize.c: only build if asm float lib
5642         * device/lib/_fsreturnval.c: only build if asm float lib
5643         * device/lib/_fsrshift.c: only build if asm float lib
5644         * device/lib/_fsswapargs.c: only build if asm float lib
5645         * device/include/stdio.h: don't provide print_fast,
5646           print_fast_f, print_tiny prototypes if --xstack used
5647
5648 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
5649
5650         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
5651         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
5652           to the SOURCES
5653
5654 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
5655
5656         * device/lib/printf_fast_f.c: same as printf_fast, but
5657           with floating point enabled
5658         * device/lib/printf_fast.c: minor tweaks
5659         * device/include/stdio.h: add printf_fast_f
5660
5661 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
5662
5663         * src/SDCCmain.c: make --float-reent default for mcs51
5664         * device/lib/_fsadd.c: added mcs51 assembly version
5665         * device/lib/_fssub.c: added mcs51 assembly version
5666         * device/lib/_fsmul.c: added mcs51 assembly version
5667         * device/lib/_fsdiv.c: added mcs51 assembly version
5668         * device/lib/_fseq.c: added mcs51 assembly version
5669         * device/lib/_fsneq.c: added mcs51 assembly version
5670         * device/lib/_fsgt.c: added mcs51 assembly version
5671         * device/lib/_fslt.c: added mcs51 assembly version
5672         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
5673         * device/lib/Makefile.in: add _fscmp to build
5674         * device/lib/libfloat.lib: add _fscmp to build
5675
5676 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
5677
5678         * device/lib/_fs2slong.c: added mcs51 assembly version
5679         * device/lib/_fs2sint.c: added mcs51 assembly version
5680         * device/lib/_fs2schar.c: added mcs51 assembly version
5681         * device/lib/_fs2ulong.c: added mcs51 assembly version
5682         * device/lib/_fs2uint.c: added mcs51 assembly version
5683         * device/lib/_fs2uchar.c: added mcs51 assembly version
5684         * device/lib/_slong2fs.c: added mcs51 assembly version
5685         * device/lib/_sint2fs.c: added mcs51 assembly version
5686         * device/lib/_schar2fs.c: added mcs51 assembly version
5687         * device/lib/_ulong2fs.c: added mcs51 assembly version
5688         * device/lib/_uint2fs.c: added mcs51 assembly version
5689         * device/lib/_uchar2fs.c: added mcs51 assembly version
5690         * device/include/float.h: added #define to select asm vs c
5691
5692 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
5693
5694         * device/lib/printf_fast.c: improvements to float output
5695         * device/include/float.h: add defines for assembly float library
5696         * device/lib/_fsget1arg.c: receive 1 float arg
5697         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
5698         * device/lib/_fsnormalize.c: normalize a float
5699         * device/lib/_fsreturnval.c: return float, various helper routines
5700         * device/lib/_fsrshift.c: right shift a float's mantissa
5701         * device/lib/_fsswapargs.c: swap 2 floats
5702         * device/lib/Makefile.in: build these 6 new files for mcs51
5703         * device/lib/libfloat.lib: add these 6 files to the library
5704
5705 2004-12-26 Borut Razem <borut.razem AT siol.net>
5706
5707         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
5708           built by gcc 3.4.2
5709
5710 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
5711
5712         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
5713           and fully reentrant and register bank neutral.
5714         * device/lib/printf_fast.c: added float (not enabled by default),
5715           added compact/slower integer (also not enabled by default),
5716           improved size/speed of fast integer code, other minor changes
5717         * device/include/stdio.h, device/lib/Makefile.in,
5718           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
5719
5720 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
5721
5722         * src/pic16/pcode.c: declaring variables other than at the start of a
5723           block is not supported in C by VC6.
5724
5725 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
5726
5727         * applied a previous patch from Raphael Neider that wasn't included
5728         in the previous commits, which fixes infinite loops within jumptable
5729         improvements,
5730         * made some fixes that previous patches introduced
5731
5732 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
5733
5734         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
5735         that fixes an issue with AOP_PCODE asmop's offset,
5736         * (pic16_popCopyReg): update instance field too,
5737         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
5738         function of pic port,
5739         * (genCmp, genAnd, genAssign),
5740         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
5741
5742 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
5743
5744         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
5745         variables initial values to idata section,
5746         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
5747         variables in some functions. This utilizes parmBytes field of iCode
5748         structure to hold the offset of the variable in stack. (might be
5749         able to use the stack field too?)
5750         * applied patch from Raphael Neider # ### , # ###
5751         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
5752         variable initial values in idata section,
5753         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
5754         for static variables with initial value
5755         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
5756         applied fix in while loop from Raphael Neider.
5757
5758 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
5759
5760         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
5761         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
5762         * src/ds390/ralloc.c (serialRegAssign): spill bits
5763         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
5764         * support/Util/SDCCerr.c,
5765         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
5766         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
5767         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
5768
5769 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
5770
5771         * device/include/sdcc-lib.h: inserted LGPL, added includes
5772           asm/ds390/features.h and asm/mcs51/features.h
5773         * device/include/asm/default/features.h,
5774         * device/include/asm/gbz80/features.h,
5775         * device/include/asm/z80/features.h: added empty _AUTOMEM
5776           and _STATMEM
5777         * device/include/asm/ds390/features.h,
5778         * device/include/asm/mcs51/features.h: added files with defines for
5779           _AUTOMEM and _STATMEM indicating automatic and static storage class
5780         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
5781         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
5782         * src/SDCCicode.c (geniCodeCast),
5783         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
5784         * src/SDCCloop.c (loopInduction): removed unused variable lr
5785         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
5786           to convertToFcall to include char modulo (RFE 1065037), added check
5787           if left operand is unsigned and use abs of literal value
5788         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
5789           as it doesn't work after conversion from peephole.def to peephole.rul
5790         * src/mcs51/gen.c (toBoolean): added check for size,
5791           (genModOneByte): optimized code for signed char modulo a literal
5792           power of 2 (thanks to Hubert Sack),
5793           (genRRC): removed unnecessary "clr c",
5794           (genRLC): replaced "add a,acc" with cheaper "rlc a"
5795         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
5796           jump optimization,
5797           swapped rules 256.c and 256.d,
5798           extended 256.d by using new multiple checks (thanks Erik),
5799           added rules 256.e and 256.f,
5800           updated rule 261.a and 261.b to new generated code
5801         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
5802
5803 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5804
5805         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
5806           induction related bugs, including first part of bug #1074377
5807
5808 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
5809
5810         * applied patch from bug-report #1076292,
5811         * applied patches for genAnd and Goto-optimizations for Raphael
5812         Neider,
5813         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
5814         dump a less iCode information,
5815         * src/pic16/device.h (pic16_options_t): added field debgen,
5816         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
5817         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
5818         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
5819         puclic,
5820         * (various functions): added macros FENTRY and FENTRY2 to functions,
5821         to emit function prologue,
5822         * (various functions): fixed indentation,
5823         * (genNearPointerGet): fixed loading of FSR0,
5824         * (genPackBits): applied patch from Raphael Neider to fix updating
5825         of FSR0 and touching only the modified bits,
5826         * src/pic16/genarith.c (various functions): added macros FENTRY to
5827         emit function prologue in comments,
5828         * src/pic16/pcode.h: added functions debugf2, debugf3,
5829         * src/pic16/ralloc.c: partial fix for packForPush caused
5830         segmentation fault,
5831
5832 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5833
5834         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
5835           <stsp AT users.sourceforge.net> with reversed byte order
5836         * support/regression/tests/rotate.c: added (ds390 skips some tests)
5837
5838 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5839
5840         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
5841           bug #1074377
5842         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
5843         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
5844
5845 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
5846
5847         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
5848
5849 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5850
5851         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
5852           conditions,
5853           (setFromConditionArgs): friendly operand parser for peephole rules,
5854           (operandBaseName, operandsNotRelated): new peephole condition
5855           "operandsNotRelated" -- similar to "operandsNotSame", but takes
5856           architecture specific register naming into account, handles n-way
5857           comparisons, and supports quoted literals
5858         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
5859
5860 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5861
5862         * src/mcs51/peeph.def: fixed bug #1076940
5863
5864 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
5865
5866         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
5867
5868 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5869
5870         Adding support for replacing ljmps with sjmps in jumptables
5871         generated for switch statements. For now you need to set the
5872         environment variable SDCC_SJMP_JUMPTABLE to enable this.
5873         Now 4 algorithms for mcs51 jumptable generation are used:
5874         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
5875         addresses loaded pc-relative for up to 112 cases and stack-pushing
5876         target addresses loaded with offset from dptr for up to 256 cases.
5877
5878         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
5879         * src/mcs51/main.c: adapted constants for switch table generation
5880         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
5881
5882 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
5883
5884         * device/lib/printf_large.c (_print_format): fixed bug 1073386
5885         * support/regression/tests/bug1057979.c: added test for bug 1073386
5886
5887 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
5888
5889         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
5890         compilers
5891
5892 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
5893
5894         * src/pic16/device.h,
5895         * src/pic16/genarith.c,
5896         * src/pic16/glue.c,
5897         * src/pic16/main.c,
5898         * src/pic16/pcode.c: applied patches #1068154 and #1070213
5899
5900 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
5901
5902         Large cummulative patch for pic16 port.
5903         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
5904         to call when a stack overflow occurs,
5905         * (malloc.h): added CVS Id tag,
5906         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
5907         variable,
5908         * added libc directory. The current version of LibC contains string
5909         functions, ctype functions and macros and some functions of the
5910         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
5911         be extensively tested in the future. Standard disclaimer here.
5912         Library is not automatically build yet. But one can build it by
5913         invoking 'make' inside the libc directory.
5914         * added ADC library under libio. Preliminary version yet.
5915
5916         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
5917         * src/pic16/gen.c (aopForRemat): asmop size is filled by
5918         aopForRemat() now and not by pic16_aopOp(),
5919         * (pic16_popGetTempReg): removed warning messgae when allocating
5920         temporary registers, its a buggy feature and will be removed,
5921         * (pic16_popGet): set register instance field in AOP_CRY,
5922         * (pic16_outBitC): fixed for results in size greater than 1,
5923         * (genUminusFloat): fixed for pic16, ported code from mcs51,
5924         * (pic16_storeForReturn): optimized return of 0,
5925         * (genCmp): experimental code for new genCmp which uses PIC18's
5926         special compare&skip instructions. Initial tests fail some times
5927         with variables grater than 1 byte in size, so new code is disabled,
5928         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
5929         a single bit,
5930         * (genCast): began a fix to optimize the casting of a bit to another
5931         bit, now assigning a bitfield to another bitfield will fail, sorry,
5932         * src/pic16/main.c: disabled the use of lr-support feature,
5933         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
5934         * added some function prototypes, added function _debugf prototype,
5935         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
5936         bits with offset (case PO_GPR_BIT),
5937         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
5938         command line,
5939         * (isBankInstruction): modified to return 0 for no banking instruction,
5940         and 1 for banking instruction,
5941         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
5942         caused stop processing pCodes after a inline assembly block,
5943         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
5944         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
5945         registers when it shouldn't,
5946         * src/pic16/ralloc.c (allocReg): add preliminary support for
5947         supporting a limited set of temporary registers,
5948
5949 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5950
5951         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
5952           genDataPointerSet): ensure assignments always copy in MSB to LSB
5953           order,
5954           (loadRegFromAop): recognize CLRH optimization,
5955           (genFunction): optimize RECEIVE iCodes in reentrant functions
5956
5957 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5958
5959         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
5960           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
5961           selected.
5962         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
5963         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
5964           contiguous with data
5965
5966 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5967
5968         * device/lib/_gptrget.c (_gptrget),
5969         * device/lib/_gptrgetc.c (_gptrgetc),
5970         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
5971           instead of sjmp to ret
5972         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
5973           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
5974
5975 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
5976
5977         * .version: bumped version to 2.4.7
5978         * device/lib/_gptrget.c (_gptrget): is now _naked
5979         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
5980         * device/lib/_gptrput.c (_gptrput): is now _naked
5981         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
5982           (createFunction): fixed xstack
5983         * src/SDCCglue.c (emitMaps): set allocation required for bit area
5984         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
5985           or bit either,
5986           (geniCodeCritical): store original interrupt state in an iTemp bit
5987           var unless stack-auto
5988         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
5989         * src/SDCCmain.c (setIncludePath): added include/target to search path
5990         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
5991         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
5992           prototype,
5993           (processFuncArgs): put bit vars in bit area
5994         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
5995           unsaveRBank): fixed xstack,
5996           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
5997           (genFunction, genEndFunction): fixed xstack,
5998           (genAssign): optimization don't walk backwards through mem
5999         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
6000         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
6001         * support/regression/Makefile: also make library (for stack-auto) when
6002           making "all" and added "test-mcs51-xstack-auto"
6003         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
6004         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
6005         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
6006         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
6007         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
6008           make-library by MAKE_LIBRARY
6009         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
6010           regression tests for xstack
6011         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
6012         * support/regression/tests/critical.c: test for critical on mcs51
6013
6014 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6015
6016         * support/regression/ports/ucz80/spec.mk: use include and lib files from
6017           built version of sdcc instead of installed version
6018
6019 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
6020
6021         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
6022         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
6023           vprintf.c now
6024         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
6025         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
6026           WARNING: remove device/lib/build/z80/printf.o by hand when
6027           updating from previous build!
6028         * device/lib/z80/printf.c: updated comment
6029         * support/regression/tests/bug1057979.c: test all ports now
6030         * support/regression/tests/bug1065458.c: file added
6031
6032 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6033
6034         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
6035           *_start and *_end symbols for static functions
6036
6037 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
6038
6039         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
6040           and search crt0.o in all library paths,
6041           (setIncludePath): proper handling of --nostdinc,
6042           (setLibPath): proper handling of --nostdlib
6043         * support/regression/Makefile,
6044         * support/regression/ports/ds390/spec.mk,
6045         * support/regression/ports/gbz80/spec.mk,
6046         * support/regression/ports/hc08/spec.mk,
6047         * support/regression/ports/mcs51/spec.mk,
6048         * support/regression/ports/mcs51-large/spec.mk,
6049         * support/regression/ports/mcs51-stack-auto/spec.mk,
6050         * support/regression/ports/z80/spec.mk: use include and lib files from
6051           built version of sdcc instead of installed version
6052         * doc/sdccman.lyx: fixed typo in --nostdinc
6053
6054 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
6055
6056         * src/pic/pcode.c,
6057         * src/pic/device.c,
6058         * src/pic/ralloc.c,
6059         * src/pic/gen.c : added support to generate code for struct bit fields.
6060
6061 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
6062
6063         * as/xa51/xa_version.h,
6064         * device/include/errno.h,
6065         * device/include/regc515c.h,
6066         * device/lib/_itoa.c,
6067         * device/lib/_ltoa.c,
6068         * device/lib/ser_ir_cts_rts.c,
6069         * sim/ucsim/xa.src/glob.cc,
6070         * sim/ucsim/xa.src/inst_gen.cc,
6071         * sim/ucsim/xa.src/xa_bit.cc,
6072         * sim/ucsim/xa.src/xa_sfr.cc,
6073         * sim/ucsim/z80.src/inst_dd.cc,
6074         * sim/ucsim/z80.src/inst_fdcb.cc,
6075         * support/scripts/keil2sdcc.pl,
6076         * src/pic16/pic16.dsp,
6077         * src/pic16/pic16a.dsp: corrected cvs line endings
6078         * device/lib/printf_large.c: fixed bug 1057979
6079         * src/pic16/gen.c: fixed non-C standard code
6080         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
6081         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
6082         * support/regression/ports/mcs51/support.c: reload T1 asap
6083         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
6084           pdata use and clear idata startup behaviour
6085         * support/regression/tests/bug1057979.c: added
6086
6087 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
6088
6089         * device/examples/ds390/ow390/ad26.h,
6090         * device/examples/ds390/ow390/cnt1d.h,
6091         * device/examples/ds390/ow390/crcutil.c,
6092         * device/examples/ds390/ow390/ownet.h,
6093         * device/examples/ds390/ow390/owsesu.c,
6094         * device/examples/ds390/ow390/swt12.h,
6095         * device/examples/ds390/ow390/swtoper.c,
6096         * device/examples/ds390/ow390/temp10.h,
6097         * device/examples/ds390/ow390/thermodl.c,
6098         * device/examples/ds390/tinitalk/tinitalk.dsp,
6099         * device/examples/ds390/tinitalk/tinitalk.dsw,
6100         * device/examples/mcs51/clock/hw.h,
6101         * device/examples/mcs51/simple2/go.bat,
6102         * device/examples/serialcomm/windows/serial.h,
6103         * device/examples/xa51/dummy.c,
6104         * device/examples/xa51/hello.c,
6105         * device/include/80c51xa.h,
6106         * device/include/at89x051.h: corrected cvs line endings
6107
6108 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
6109
6110         * src/pic16/main.c (options): added command line --gstack, to trace
6111         stack over/under flows,
6112         * added pragma 'wparam' to allow passing first byte of function
6113         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
6114         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
6115         call to __gstack_test function and sets up the symbol as extern,
6116         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
6117         * popaop): added call to pic16_testStackOverflow,
6118         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
6119         wparamList list,
6120         * (genCall, genPcall): now all parameters are passed via stack
6121         except in functions that are pass to wparam pragma in which WREG is
6122         used too,
6123         * (genPcall): REENTRANT flag is checked to see if variable prototype
6124         contains reentrant keyword, don't call a non-reentrant function, via
6125         a reentrant function pointer or vice versa, functions are never
6126         passed via WREG,
6127         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
6128         D.Winkler,
6129         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
6130         SIGSEGV when accessing a NULL register stucture,
6131         * (pic16_printGPointerType): modified to handle UPPER modifier for
6132         function initializers, changed prototype of function to simpler one,
6133         * (pic16_printIvalFuncPtr): check to see if function is already
6134         added in externs list,
6135         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
6136         optimized a move from W to SFR with a move to the same register
6137         later after a CALL,
6138         * device/lib/pic16/debug: NEW directory, contains debug features
6139         which are enabled when linking with libdebug.lib, currently command
6140         line option --gstack enables stack pointer tracing for over/under
6141         flow, corresponding sources are in debug/gstack
6142
6143 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
6144
6145         * doc/sdccman.lyx: updated SDCC version,
6146         * (PIC16 port): update list of command line options,
6147         * src/pic16/device.h (structure pic16_options_t): added field gstack
6148         to enable stack overflow tracing on push/pops,
6149         * src/pic16/device.c (statistics structure): added statistics
6150         structure,
6151         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
6152         pic16_dump_int_registers): increase statistics counters for each
6153         * variable which is encountered
6154         * (pic16_dump_usection): emit each .udata variable to its own udata
6155         section,
6156         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
6157         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
6158         parameters via stack, otherwise use old scheme,
6159         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
6160         assembler output file,
6161         * src/pic16/main.c: added command line options --gstack to enable
6162         push/pop tracing for stack overflow,
6163         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
6164         instructions): added size of each instruction,
6165         * (pic16_countInstruction): estimate size of instructions in
6166         the_pFile list, inline assembly blocks are not counted,
6167         * (pic16_FixRegisterBanking): trace previous register usage, when
6168         banksel optimizations is greater than 0, don't emit a redudant
6169         banksel directive,
6170
6171 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
6172
6173         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
6174         * src/pic16/ralloc.c : applied same fix for pic16.
6175         * src/pic/gen.c : tidied it up a little.
6176
6177 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6178
6179         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
6180         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
6181
6182 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6183
6184         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
6185
6186 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6187
6188         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
6189         non-reentrant function __modsint in the interrupt function (thus
6190         corrupting math operations during serial I/O)
6191         * device/lib/ser_ir.c: as above, changed buffersize
6192         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
6193         256.c,d for zeroing
6194         * doc/Makefile: added option -t for rsync
6195
6196 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6197
6198         * src/SDCCast.h (struct ast),
6199         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
6200
6201 2004-10-20 Borut Razem <borut.razem AT siol.net>
6202
6203         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
6204         package
6205
6206 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
6207
6208         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
6209         makefile targets,
6210         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
6211         support functions to replace long sequences of MOVFF's from access
6212         bank registers to stack and vice versa,
6213         * src/pic16/device.h: added new field opt_flags, where optimization
6214         flags can be set to enable certain features,
6215         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
6216         * pBlock, (genFunction, genEndFunction): surroung loop for
6217         saving/loading used registers in stack with PC_INFO pCodes,
6218         INF_LREGS. Code in between can then be optimized by pCode optimizer
6219         to support function calls,
6220         * (genDataPointerSet): fixed bug which loaded float fields in
6221         structures with corrupt data,
6222         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
6223         in a standard way debug info on stderr. Feature used for developing
6224         and debugging only,
6225         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
6226         obsolete chunks of code,
6227         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
6228         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
6229         * pic16/src/pcode.c (pic16_newpCodeInfo,
6230         * (pic16_newpCodeOpLocalRegs),
6231         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
6232         feature,
6233         * (pic16_pCodeConstString): printing of the initial value of a
6234         symbol as a comment is inhibited since parsing was already done by
6235         copyStr and output is corrupt,
6236         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
6237
6238 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6239
6240         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
6241
6242 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
6243
6244         * as/mcs51/lkarea.c: removed old K&R style,
6245           (lnksect): changed check on boundary error,
6246           (lnksect2): changed check on boundary error,
6247           (lnksect2): extend XSTK to end of page if size = 1
6248         * as/mcs51/lkmain.c: removed old K&R style,
6249           (Areas51): create l_IRAM symbol
6250         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
6251         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
6252           model-mcs51-stack-auto, added model-mcs51-xstack-auto
6253         * device/lib/_mullong.c: added version to be compiled with xstack
6254         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
6255         * device/lib/mcs51/crtxclear.asm: clear pdata as well
6256         * device/lib/mcs51/crtxstack.asm: fixed comment
6257         * src/SDCCglue.c: maxInterrupts defaults to 0,
6258           (emitMaps): added pdata,
6259           (createInterruptVect): (re)moved default,
6260           (glue): added pdata,
6261           (glue): moved __start__xstack to XSTK with default size 1
6262         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
6263           and options.float_rent when options.stackAuto is set,
6264           (linkEdit): only write XDATA_NAME if provided on command line
6265         * src/SDCCmem.h,
6266         * src/SDCCmem.c: added pdata
6267         * src/port.h: added pdata_name to PORT
6268         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
6269           (saveRegisters, unsaveRegisters): removed usage of B,
6270           (genMinus): fixed accumulator clash,
6271           (genJumpTab): added comment, this needs another look
6272         * src/mcs51/gen.c: added check for "B in use" paranoia,
6273           added pushB() and popB()
6274         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
6275           chance
6276         * src/avr/main.c,
6277         * src/ds390/main.c,
6278         * src/hc08/main.c,
6279         * src/mcs51/main.c,
6280         * src/pic/main.c,
6281         * src/pic16/main.c,
6282         * src/xa51/main.c,
6283         * src/z80/main.c: (reset_regparms) made void parameter explicit and
6284           added PSEG (PAG,XDATA) or NULL to port specifier
6285         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
6286         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
6287           (_mcs51_genInitStartup): removed __start__xstack equ,
6288           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
6289         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
6290         * src/z80/gen.c (_rleAppend): fixed warnings
6291         * support/regression/tests/zeropad.c: added pdata test
6292         * .version: bumped to 2.4.6
6293
6294 2004-10-17 Borut Razem <borut.razem AT siol.net>
6295
6296         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
6297         as a part of nightly build
6298
6299 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
6300
6301         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
6302         WREG holds the first byte function parameters,
6303         * (aopForSym): take special case for symbols which are in FARSPACE
6304         but in CODESPACE too,
6305         * (assignResultValue): modified to take into account _G.useWreg,
6306         * (genCall): don't use wreg for parameter passing when function is
6307         declared as reentrant, too, added optimization INCF to stack
6308         pointer when stack parameter count is 1,
6309         * (genFunction, genEndFunction): refurnished and fixed to not using
6310         wreg for passing parameters when function has varargs or is
6311         reentrant, fixed bug with symbol name compare for generating
6312         functions in absolute address,
6313         * (pic16_storeForReturn): refurnished,
6314         * (genCmp): began writing a new version of the function, not ready
6315         yet, therefore it is disabled,
6316         * (genAssign): do not read code memory when assigning a function to
6317         a pointer function,
6318         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
6319         array of characters, not pointer,
6320         * (pic16initialComments): in debug mode emit an .ident directive for
6321         the assembler,
6322         * (_process_pragma): emit a new warning type (internal to pic16)
6323         when setting stack to default length, emit a similar warning when
6324         placing a function at absolute address and address is not word aligned
6325         * (_pic16_parseOptions): added 'return TRUE' statement,
6326         * (_pic16_linkEdit): if compiling a source, then add the source's
6327         file object, first in the list of objects to link,
6328
6329 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
6330
6331         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
6332         * src/pic/main.c : removed VC warning.
6333         * src/pic/gen.c : changed comment.
6334
6335 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
6336
6337         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
6338         reference to a deprecated symbol _GPTRREG was causing failure to
6339         link. Thanks G. M. Gallant for the info.
6340
6341 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
6342
6343         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
6344         comments for Bugs item #954788.
6345
6346 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
6347
6348         * src/pic16/device.c (pic16_dump_gsection,
6349         * pic16_groupRegistersInSection): handle symbols declared to be in
6350         access bank differently,
6351         * src/pic16/gen.c (struct _G): added field resDirect,
6352         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
6353         send values read from stack directly to result and don't allocate
6354         temporary values,
6355         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
6356         same registers,
6357         * (pic16_sameRegsOfs): NEW,
6358         * (freeAsmop): if _G.resDirect is set then do not mark registers as
6359         free because they were not allocated from temporary pool,
6360         * pic16_popRegFromString): workaround to fix a problem with
6361         allocating variables twice or never,
6362         * (genGenPointerGet): using PRODL instead of FSR0H,
6363         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
6364         instead of FSR0H,
6365         * (genAssign): take advantage of the _G.resDirect flag,
6366         * (genCast): around line 11844, use mov2f instead of directly
6367         MOVFF'ing between operands to account for literal values,
6368         * src/pic16/genutils.c: some new debug functions for gpsim have been
6369         added,
6370         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
6371         float with integer part only,
6372         * src/pic16/main.c (_process_pragma): handle pragma udata access to
6373         place variables in access bank
6374         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
6375         updated sources to reflect recent changes in gen.c
6376
6377 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
6378
6379         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
6380         sources that searched for headers in installation path, now the
6381         device/include/pic16 is used,
6382         * src/pic16/glue.c (pic16glue),
6383         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
6384         .line directives if not in debug mode, this suppresses assembler's
6385         warnings for ignored directives
6386
6387 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
6388
6389         * src/port.h: made reset_regparms prototype void parameter explicit.
6390         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
6391         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
6392         * doc/sdccman.lyx: documented warning disabling and how to use
6393           printf_large to make it print floats.
6394         * device/include/stdbool.h: NEW
6395         * device/lib/_atof.c,
6396         * device/lib/_divuint.c,
6397         * device/lib/_divulong.c,
6398         * device/lib/expf.c,
6399         * device/lib/printf_large.c,
6400         * device/lib/sincosf.c,
6401         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
6402         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
6403           a completely reentrant lib.
6404
6405 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
6406
6407         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
6408         * device/include/pic16/stdio.h: fixed bug with colon
6409
6410 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
6411
6412         * device/include/pic16/stdio.h,
6413         * device/include/pic16/stdlib.h,
6414         * device/include/pic16/math.h: NEW
6415         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
6416         declared as _naked to reduce overhead
6417         * device/lib/Makefile.in (target port-specific-objects-pic16):
6418         changed * to *.* so to ignore the CVS directory,
6419         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
6420         stacked variables back in stack,
6421         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
6422         corruption
6423
6424 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
6425
6426         * .version: bumped version number to 2.4.5
6427         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
6428         * support/Util/SDCCerr.c (messages structure): added entry for
6429         W_POSSBUG2
6430
6431         Large cumulative patch for pic16 port and libraries.
6432         * device/include/pic16/sdcc-lib.h,
6433         * device/include/pic16/stdarg.h,
6434         * device/include/asm/pic16/features.h,
6435         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
6436         * device/include/pic16/float.h: changes reentrant keyword with
6437         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
6438         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
6439         updated target build-libraries to include objects from gptr,
6440         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
6441         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
6442         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
6443         all function headings,
6444         * src/SDCCmain.c: added global parameter userIncDirsSet,
6445         * (parseCmdLine): when option -I is encountered add directory to
6446         userIncDirsSet too,
6447         * src/version.awk: added space between control and long,
6448         * src/pic16/NOTES: added some notes for the port,
6449         * src/pic16/gen.c: added prototype for mov2fp function,
6450         * (fReturnpic16[]): properly named return value registers,
6451         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
6452         * (aopForSym): added code to handle symbols with onStack flag set,
6453         symbols onStack are allocated PTRSIZE bytes,
6454         * (aopFreeAsmop): handles special case where asmops are stack objects,
6455         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
6456         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
6457         added argument lock to trace flaws in allocating temporary registers
6458         when developing port,
6459         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
6460         * (pic16_popRegFromString): reenabled allocating a direct register
6461         from string,
6462         * (assignResultValue): various beautifications,
6463         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
6464         referenced function argument,
6465         * (genIpush): reenabled to allow stacked arguments, handles only
6466         ic->parmPush iCodes,
6467         * (genCall, genPcall): major changes to allow for variable argument
6468         functions, fixed a bug with falsely restoring stack pointer after
6469         returning from call,
6470         * (genFunction): pending code for critical function,
6471         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
6472         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
6473         * (genNearPointerGet): fixed bug with indirect reading, was always
6474         reading from INDF0
6475         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
6476         pointers,
6477         * (genAddrOf): rewrote code to take address of a stacked function parameter
6478         * (genCast): fixed casting to generic pointer type,
6479         * src/pic16/gen.h: added AOP_STA,
6480         * (struct asmop): added field stk,
6481         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
6482         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
6483         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
6484         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
6485         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
6486         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
6487         generic pointers,
6488         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
6489         and library paths,
6490         * (pic16_port structure): generic pointer size is set to 3,
6491         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
6492         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
6493         compiler warning,
6494         * src/pic16/ralloc.c (allocReg): prevent allocating register when
6495         operand is an iTemp,
6496
6497 2004-09-24 Martin Helmling <mh AT octo-soft.de>
6498
6499         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
6500         * debugger/mcs51/simi.c: addapt new syntax of s51
6501
6502 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
6503
6504         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
6505         * src/pic16/pcode.c: commented out some calls to free() in order to
6506         fix bug #989576,
6507
6508 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6509
6510         * src/SDCCicode.h,
6511         * src/SDCCicode.c (isiCodeInFunctionCall),
6512         * src/avr/ralloc.c (selectSpil),
6513         * src/pic/ralloc.c (selectSpil),
6514         * src/pic16/ralloc.c (selectSpil),
6515         * src/ds390/ralloc.c (selectSpil),
6516         * src/hc08/ralloc.c (selectSpil),
6517         * src/xa51/ralloc.c (selectSpil),
6518         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
6519         stack in the middle of a function call sequence (fixes bug #1020268)
6520         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
6521         costs associated with the minimum switch case.
6522
6523 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6524
6525         * src/SDCC.lex: fixed bug #1030549
6526
6527 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6528
6529         * src/SDCCcse.h (struct cseDef),
6530         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
6531         over a function call if the CSE is derived from a symbol whose
6532         address has been taken (fixes bug #1029883)
6533         * support/regression/tests/bug-1029883: a new regression test for
6534         this bug
6535
6536 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6537
6538         * src/hc08/gen.c (emitinline): fixed bug #1029778
6539         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
6540         to a cast object is no longer a syntax error ("fixes" bug #1030006,
6541         and starts toward RFE #905167)
6542
6543 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
6544
6545         * src/pic16/gen.c (mov2f): New function to move an operand to
6546         another without considering if it is a literal or a register,
6547         * (pic16_sameRegs): don't check if they are both AOP_REG,
6548         * (AccRsh): removed andmask=0 lines,
6549         * (genLeftShift): duplicated to be improved in future versions,
6550         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
6551         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
6552         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
6553         * (pic16initMnemonics): added initialization for POC_INFSNZW,
6554         * (insertBankSwitch): fixed inserting banksel directives algorithm
6555         for instructions that follow a skip instruction, this fixes a report
6556         for broken subtraction code generation,
6557         * src/pic16/ralloc.c (deassignLRs): do not free register if current
6558         iCode is a left op, just in case result and right share the same
6559         registers
6560
6561 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6562
6563         * src/hc08/main.c,
6564         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
6565         preservation of HX
6566         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
6567         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
6568         on 2004-09-12; it was buggy
6569
6570 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
6571
6572         * src/SDCCsymt.h: removed RESULT_CHECK
6573         * src/SDCCast.c,
6574         * src/SDCCglue.c,
6575         * src/SDCCval.c,
6576         * src/pic/glue.c,
6577         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
6578
6579 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
6580
6581         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
6582         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
6583         configuration values no more rejected by compiler, they are assigned
6584         to configuration registers with a warning message instead,
6585         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
6586         the for-loop so last conf register is emitted too,
6587         * (_pic16_initPaths): link library libsdcc.lib by default,
6588         * (_hasNativeMulFor): modified test for multiplication according to
6589         Raphael Neider's remarks. Integer multiplication is also done with
6590         support functions,
6591         * device/include/pic16/pic18fregs.h: corrected type error in while
6592         testing and including 18f6720 header file
6593
6594 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
6595
6596         * src/pic16/device.h (pic16_options): removed field use_crt,
6597         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
6598         until an optimization to handle single bits is added,
6599         * (pic16_loadFSR0): moved before genUnpackBits,
6600         * (genAnd): some white lines removed,
6601         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
6602         leave_reset flags in pic16_options when using crt modules,
6603
6604 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
6605
6606         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
6607           for bugs 898889 & 979599. Also used some safer print instructions.
6608
6609 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
6610
6611         * src/pic16/device.h (pic16_options_t): added field use_crt,
6612         crt_name, no_crt,
6613         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
6614         catch a probable future bug,
6615         * src/pic16/gen.c: aopIdx function commented out,
6616         * (genAssign): commented out old code which used aopIdx,
6617         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
6618         code, added if conditionals to take into account the --use-crt
6619         command line options,
6620         * src/pic16/main.c (pic16_optionsTable): added new command line
6621         options, --use-crt= and --no-crt,
6622         * (_pic16_linkEdit): now the proper crt object is added in the
6623         linker command line except than when --no-crt is specified,
6624         * src/pic16/pcode.c,
6625         * src/pic16/pcode.h: added some structures and functions for a new
6626         optimization scheme to compansate for instruction overhead between
6627         same iCodes, this scheme is currently under development and is not
6628         working in any way,
6629         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
6630         to && operator,
6631         * device/lib/pic16/startup/crt0i.c,
6632         * device/lib/pic16/startup/crt0iz.c: added global char variable
6633         __uflags to force the generation of an idata section
6634
6635 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
6636
6637         * doc/Makefile,
6638         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
6639         * doc/sdccman.lyx: updated sdcc version to 2.4.4
6640
6641 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6642
6643         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
6644         Frieder) and clarified the default code optimization mode
6645
6646 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6647
6648         * src/SDCC.lex (doPragma, process_pragma),
6649         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
6650         "opt_code_size", and "opt_code_balanced"
6651         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
6652         regrouped options by category, added support for category headers
6653         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
6654         and "--opt-code-size"
6655         * doc/sdccman.lyx: documented these new options and pragmas
6656         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
6657         preference into account
6658
6659 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
6660
6661         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
6662           geniCodePreDec): Fixed bug 904237 by generating a warning
6663         * src/SDCCerr.h,
6664         * src/SDCCerr.c: added warning W_SIZEOF_VOID
6665
6666 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
6667
6668         * src/pic/device.c : When no max ram set validate full memory range.
6669         * src/pic/pcode.c,
6670         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
6671
6672 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
6673
6674         * device/lib/_gptrget.c,
6675         * device/lib/_gptrput.c: updated comment
6676         * device/lib/calloc.c,
6677         * device/lib/free.c,
6678         * device/lib/malloc.c,
6679         * device/lib/realloc.c: added LGPL, made them reentrant-safe
6680         * src/SDCCcse.c (cseBBlock),
6681         * src/SDCCicode.c (printOperand, geniCodeArray),
6682         * src/SDCCicode.h (struct operand): fixed bug 868103
6683         * support/regression/tests/bug-868103.c: added
6684         * src/SDCCast.c (searchLitOp),
6685         * src/SDCCcse.h (struct cseDef),
6686         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
6687         * src/SDCCicode.h (struct operand),
6688         * src/SDCCsymt.h (struct sym_link),
6689         * src/avr/gen.c (hasInc),
6690         * src/ds390/gen.c (hasInc),
6691         * src/hc08/gen.c (genPlusIncr, hasInc),
6692         * src/mcs51/gen.c (hasInc),
6693         * src/pic16/glue.c (pic16_printIvalChar),
6694         * src/pic16/ralloc.c (regWithIdx),
6695         * src/xa51/gen.c (hasInc) : removed warnings
6696         * src/SDCCast.c (createBlock): added comment ???
6697         * src/hc08/ralloc.c: updated comments
6698
6699 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6700
6701         * doc/sdccman.lyx: updated section on switch statements, added
6702         section about semaphore locking
6703         * doc/Makefile: added option -info for latex2html
6704         * device/lib/_gptrget.c,
6705         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
6706
6707 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
6708
6709         * src/pic/device.h,
6710         * src/pic/device.c,
6711         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
6712          maxram is less than 0x100.
6713
6714 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
6715
6716         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
6717
6718 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6719
6720         * src/port.h,
6721         * src/mcs51/main.c,
6722         * src/ds390/main.c,
6723         * src/z80/main.c,
6724         * src/hc08/main.c,
6725         * src/pic/main.c,
6726         * src/pic16/main.c,
6727         * src/avr/main.c,
6728         * src/xa51/main.c
6729         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
6730         a jump table is the best form for a switch statement, including
6731         automatic insertion of missing cases to make the case range
6732         continuous. Developed in collaboration with Frieder Ferlemann.
6733
6734 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6735
6736         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
6737         accumulator result if it needs sign extension
6738
6739 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
6740
6741         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
6742
6743 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
6744
6745         * device/lib/gbz80/printf.c,
6746         * device/lib/z80/printf.c: removed define for NULL
6747
6748 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
6749
6750         * as/xa51/xa_link.c,
6751         * device/examples/ds390/ow390/ad26.c,
6752         * device/examples/ds390/ow390/cnt1d.c,
6753         * device/examples/ds390/ow390/counter.c,
6754         * device/examples/ds390/ow390/ds2480.h,
6755         * device/examples/ds390/ow390/ds2480ut.c,
6756         * device/examples/ds390/ow390/findtype.c,
6757         * device/examples/ds390/ow390/gethumd.c,
6758         * device/examples/ds390/ow390/owllu.c,
6759         * device/examples/ds390/ow390/ownetu.c,
6760         * device/examples/ds390/ow390/swt12.c,
6761         * device/examples/ds390/ow390/swtloop.c,
6762         * device/examples/ds390/ow390/temp.c,
6763         * device/examples/ds390/ow390/temp10.c,
6764         * device/examples/ds390/ow390/thermo21.c,
6765         * device/examples/ds390/ow390/tinilnk.c,
6766         * device/examples/ds390/ow390/tstfind.c,
6767         * device/examples/serialcomm/windows/serial.cpp,
6768         * device/examples/serialcomm/windows/test_serialcomm.cpp,
6769         * device/include/reg51.h: fixed line endings for cvs
6770
6771 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6772
6773         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
6774         packRegsForAccUse, packRegisters): new accumulator register
6775         packing algorithm
6776         * support/regression/ports/hc08/support.c (_putchar): suppress
6777         warning of unused variable
6778         * src/SDCCicode.c: added SWAP entry to codeTable
6779
6780 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
6781
6782         * device/lib/sprintf.c: forgot to add this file before previous commit
6783
6784 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
6785
6786         * src/pic16/gen.c (genPackBits): added operand right in function
6787         parameters, load result directly if p_type is POINTER (that is
6788         called by genNearPointerSet)
6789         * (genUnPackBits): added operand left in function parameters,
6790         * (genNearPointerGet, genNearPointerSet): prevent the loading of
6791         FSR0 if accessing bitfields,
6792
6793 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
6794
6795         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
6796           _print_format; updated printf, sprintf, vsprintf
6797         * device/include/asm/default/features.h: corrected comment/define
6798         * device/lib/Makefile.in: added sprintf.c
6799         * device/lib/libsdcc.lib: added sprintf module
6800         * device/lib/printf_large.c,
6801         * device/lib/vprintf.c,
6802         * device/lib/sprintf.c: totally refactored printf_large and vprintf
6803           into these 3 files
6804         * support/regression/Makefile: changed ALL_PORTS into a usefull default
6805         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
6806         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
6807           hc08 test
6808         * support/regression/tests/zeropad.c: define idata as data for hc08
6809
6810 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6811
6812         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
6813         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
6814         labels are referenced at least once (even if a reference is not found)
6815         * src/hc08/gen.c (emitcode): set isComment flag for comments
6816         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
6817         loads), rules 6a..6b (optimize jumps to return)
6818
6819 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6820
6821         * device/lib/acosf.c (acosf),
6822         * device/lib/asinf.c (asinf),
6823         * device/lib/atanf.c (atanf),
6824         * device/lib/ceilf.c (ceilf),
6825         * device/lib/cosf.c (cosf),
6826         * device/lib/coshf.c (coshf),
6827         * device/lib/cotf.c (cotf),
6828         * device/lib/fabsf.c (fabsf),
6829         * device/lib/floorf.c (floorf),
6830         * device/lib/log10f.c (log10f),
6831         * device/lib/logf.c (logf),
6832         * device/lib/sinf.c (sinf),
6833         * device/lib/sinhf.c (sinhf),
6834         * device/lib/sqrtf.c (sqrtf),
6835         * device/lib/tanf.c (tanf),
6836         * device/lib/tanhf.c (tanhf),
6837         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
6838         replaced all instances of "reentrant" in the library functions
6839         defined in math.h with this macro.
6840         * support/regression/tests/float_trans.c: reenabled test for hc08
6841
6842 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
6843
6844         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
6845         erroneously deleted
6846
6847 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6848
6849         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
6850         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
6851         multi-byte volatile operands are used
6852         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
6853         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
6854         initialization to area GSINIT0 so that it would always precede
6855         any static initializers in GSINIT
6856         * support/regression/tests/zeropad.c: fixed idata define for hc08
6857         * support/regression/tests/bug-927659.c,
6858         * support/regression/tests/float_trans.c: disabled tests for hc08
6859         pending missing library routines
6860         * .version: increased version number to 2.4.4 - hc08 port now passes
6861         regression tests
6862
6863
6864 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
6865
6866         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
6867         * Makefile.common.in,
6868         * as/Makefile,
6869         * as/hc08/Makefile.in,
6870         * as/mcs51/Makefile.in,
6871         * as/z80/Makefile.in,
6872         * debugger/mcs51/Makefile.in,
6873         * device/include/Makefile.in,
6874         * device/lib/Makefile.in,
6875         * doc/Makefile,
6876         * link/Makefile,
6877         * link/z80/Makefile.in,
6878         * packihx/Makefile.in,
6879         * sim/ucsim/main_in.mk,
6880         * sim/ucsim/avr.src/Makefile.in,
6881         * sim/ucsim/doc/Makefile.in,
6882         * sim/ucsim/gui.src/serio.src/Makefile.in,
6883         * sim/ucsim/hc08.src/Makefile.in,
6884         * sim/ucsim/s51.src/Makefile.in,
6885         * sim/ucsim/xa.src/Makefile.in,
6886         * sim/ucsim/z80.src/Makefile.in,
6887         * src/Makefile.in,
6888         * support/cpp2/Makefile.in,
6889         * support/librarian/Makefile,
6890         * support/makebin/Makefile: added DESTDIR to the install path proposed
6891         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
6892         * doc/sdccman.lyx: added DESTDIR documentation
6893
6894 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
6895
6896         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
6897         instruction for interrupt handlers, use fast returns when returning
6898         from high priority interrupts
6899
6900 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6901
6902         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
6903         code generation
6904         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
6905         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
6906         bugs, ported much of Bernhard's code from mcs51
6907         * src/mcs51/gen.c (genSend),
6908         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
6909         than one when calling a reentrant function
6910         * device/lib/_mullong.c: defined an alternate struct layout for big
6911         endian ports (hc08)
6912
6913 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6914
6915         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
6916         test
6917
6918 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6919
6920         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
6921         are sane and complete before asking the port its prefered parameter
6922         passing method (fixes bug #1017633)
6923         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
6924         and _ret3
6925
6926 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6927
6928         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
6929         problem in bitfields >= 8 bits.
6930
6931 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
6932
6933         * src/SDCCsymt.c: undid changes that were not meant to be committed
6934
6935 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
6936
6937         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
6938
6939 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
6940
6941         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
6942           copied and wrong bit got inverted
6943
6944 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6945
6946         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
6947         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
6948         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
6949         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
6950         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
6951         assignments to bitfields at known addresses
6952         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
6953         reads from bitfields at known addresses
6954         * src/hc08/ralloc.c (packRegisters),
6955         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
6956         genhc08Code): optimize pointer get values used as conditionals
6957         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
6958         and branch
6959
6960 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6961
6962         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
6963         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
6964         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
6965         as conditionals
6966
6967 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6968
6969         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
6970
6971 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6972
6973         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
6974         related problems
6975
6976 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
6977
6978         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
6979
6980 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6981
6982         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
6983         mcs51 port
6984
6985 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
6986
6987         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
6988
6989 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6990
6991         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
6992         cases use more compact code.
6993
6994 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
6995
6996         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
6997
6998 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6999
7000         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
7001
7002 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7003
7004         * src/SDCCsymt.h,
7005         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
7006         parameter of changePointer() from symbol* to sym_link*
7007         * src/SDCCast.c (decorateType): call changePointer() for CAST op
7008         * src/SDCCsymt.c (compareType): void* type is castable to other
7009         pointers, but not necesarily an exact match.
7010         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
7011         is no longer blindly treated as an exact match.
7012         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
7013
7014 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
7015
7016         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
7017
7018 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
7019
7020         * src/pic/gen.c,
7021         * src/pic/pcode.c,
7022         * src/pic/ralloc.h,
7023         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
7024
7025 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
7026
7027         * src/pic/device.c,
7028         * src/pic/device.h,
7029         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
7030
7031 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7032
7033         * src/mcs51/gen.c (emitcode): fixed bug #992819
7034
7035 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
7036
7037         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
7038           there's no need to make it worse
7039
7040 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7041
7042         * src/mcs51/ralloc.c (deassignLR),
7043         * src/ds390/ralloc.c (deassignLR),
7044         * src/hc08/ralloc.c (deassignLR),
7045         * src/z80/ralloc.c (deassignLR),
7046         * src/pic/ralloc.c (deassignLR),
7047         * src/pic16/ralloc.c (deassignLR),
7048         * src/avr/ralloc.c (deassignLR),
7049         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
7050         rlivePoint): fixed another part of bug #971834
7051
7052 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7053
7054         * src/z80/main.c: enabled "critical" keyword
7055         * src/z80/mappings.i,
7056         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
7057         functions (fixes bug #979646)
7058         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
7059
7060 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7061
7062         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
7063           such as c:\mydir.
7064
7065 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
7066
7067         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
7068           doesn't disable too much optimizations
7069
7070 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
7071
7072         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
7073
7074 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
7075
7076         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
7077
7078 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
7079
7080         * src/pic/gen.c tidied up tabs
7081         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
7082         * src/pic/main.c tidied up tabs
7083         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
7084         * src/pic/pcoderegs.c tidied up tabs
7085         * src/pic/ralloc.c tidied up tabs
7086
7087 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
7088
7089         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
7090         to S_FIXED for pic16 port and when symbol is not in level 0,
7091         allocate for S_REGISTER storage class and pic16 port, too,
7092         * src/pic16/device.h: prototype for checkSym,
7093         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
7094         * (pic16_assignConfigWordValue): test the value and the mask to
7095         validate that the value is suitable for the configuration word,
7096         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
7097         collect extern declared symbols, don't emit symbol twice, check
7098         first if symbol is in publics set first,
7099         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
7100         * added command line '--fstack' which enables an experimental
7101         feature for stack access, too buggy to be used yet...
7102         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
7103         * (pic16_allocDirReg): when register has storage class S_REGISTER
7104         allocate in pic16_dynAccessRegs,
7105         * device/include/pic16/pic18f????.h: modified configuration word
7106         naming convention, words started as CONFIG0H but should be CONFIG1H
7107
7108 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
7109
7110         * device/include/mcs51reg.h: fixed bug 970993
7111
7112 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
7113
7114         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
7115         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
7116         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
7117         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
7118         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
7119         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
7120           error/warning numbers,
7121           added function setWarningDisabled()
7122         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
7123         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
7124           _memcmp.c _memmove.c calloc.c realloc.c free.c
7125         * support/regression/tests/malloc.c: added tests for new functionality
7126         * support/regression/tests/zeropad.c: added tests for truncated initializers
7127           and initialized char arrays starting with '\x0'
7128         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
7129
7130 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
7131
7132         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
7133
7134 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7135
7136         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
7137         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
7138         peephole 177.e. Thanks to anonymous
7139
7140 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
7141
7142         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
7143         function isn't used in the source but referenced as a
7144         variable initializer then declare it as extern in .asm file
7145
7146 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
7147
7148         * .version: increased version number to 2.4.3
7149
7150         Adding version extension according to ChangeLog CVS revision
7151         * src/Makefile.in (target all): added dependency 'version.h'
7152         * (rule version.h): added rule to create version.h from ChangeLog,
7153         * (rule dep): added dependency version.h,
7154         * src/version.awk: AWK script to create version.h
7155         * src/SDCCdwarf2.c (dwWriteModule),
7156         * src/SDCCglue.c (initialComments),
7157         * src/SDCCmain.c (printVersionInfo): modified to write after
7158         version string the version extension number,
7159         * src/SDCCutil.c: included "version.h"
7160         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
7161         number,
7162         * src/SDCCutil.h: added prototype for getBuildNumber
7163
7164         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
7165         includeDirsSet, too,
7166         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
7167         const char [] is found in function prototype...
7168
7169         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
7170         moving to WREG with source is already in WREG,
7171         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
7172         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
7173         * (aopForSym): stack'ed symbols are partially supported, added
7174         if-clause to support symbols in FARSPACE,
7175         * (sameRegs): added test for AOP_ACC to see if registers are same,
7176         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
7177         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
7178         * (pic16_popRegFromString): will not allocate a new register if it
7179         doesn't find one by name, bug may have introduced...
7180         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
7181         * (genIpush): revived to use pic16 port's stack,
7182         * (genAddrOf): added incomplete case for stack'ed operand,
7183         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
7184         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
7185         can handle multibyte operands,
7186         * src/pic16/glue.c (pic16_printIval*): some debug info added,
7187         * (pic16initialComments): added message for MPLAB compatibility
7188         mode enabled,
7189         * src/pic16/main.h: prototype for pic16_mplab_comp,
7190         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
7191         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
7192         * (_pic16_linkEdit): NEW, handles link stage, transferred here
7193         because of increased complexity of procedure,
7194         * (_process_pragma): stack pragma changed to format 'stack pos len',
7195         emit symbol '_stack_end' to conform with gplink,
7196         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
7197         to search for register,
7198         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
7199         PO_GPR_REGISTER,
7200         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
7201         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
7202         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
7203         case for PO_GPR_REGISTER,
7204         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
7205         dies, the new era is ahead !...
7206         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
7207         pic16_dynInternalRegs,
7208         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
7209         * (pic16_allocDirReg): minor optimizations and bug fixes,
7210         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
7211
7212         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
7213         load stack and frame pointer with address of 'stack_end' symbol
7214
7215 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
7216
7217         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
7218         without source code but only variable initializers
7219
7220 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
7221
7222         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
7223         external are not declared as extern to reduce overhead while linking
7224
7225 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
7226
7227         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
7228
7229 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
7230
7231         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
7232           Yee Keat for the patch
7233         * src/SDCCast.c (decorateType): fixed bug #979599
7234         * src/ds390/gen.h: removed local fReturnSizeDS390
7235         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
7236         * src/ds390/gen.c (genAnd, genOr, genXor),
7237         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
7238
7239 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
7240
7241         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
7242         add relFilesSet to $3, manipulate $2 to handle linking of object
7243         files without source files in command line,
7244         * device/include/pic16 (all headers): added ID location macros,
7245         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
7246         entries for ID location bytes,
7247         * (pic16_assignIdByteValue): NEW,
7248         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
7249         added field dumpcalltree to pic16_options_t,
7250         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
7251         is used instead of pic16_Gstack_base_addr, check if (ifx) before
7252         emitting rFalseIfx label after check_carry label,
7253         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
7254         pic16_emitDIRegs), NEW
7255         * (pic16glue): dump .calltree file when option --calltree found,
7256         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
7257         * (_pic16_genAssemblerPreamble): emit ID locations after
7258         configuration registers,
7259         * (pic16_linkCmd): modifications of the link command,
7260         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
7261         * (pic16_pCodeInitRegisters): don't init stack registers,
7262         * (pic16_findPrevInstruction): fixed bug,
7263         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
7264         bug with immediate registers,
7265         * (buildCallTree): traces stack push and pop,
7266         * (pct2): dump also stack usage for each function,
7267         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
7268         * (pic16_allocDirReg): various modifications,
7269         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
7270         fixed to 1,
7271
7272 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
7273
7274         * src/pic16/pcode.c: removed buggy double colon
7275
7276 2004-07-01 Borut Razem <borut.razem AT siol.net>
7277
7278         * support/scripts/sdcc.nsi: added include/pic16 to setup
7279
7280 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
7281
7282         * device/lib/Makefile.in: fixed bug in target objects-pic16,
7283         * device/lib/pic16/Makefile: prefixed with dash (-) command under
7284         target 'clean',
7285         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
7286         specific command line arguments. Also added sample lkr script
7287         for placing a variable at a specific memory bank.
7288         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
7289         at a specific memory bank,
7290         * (pic16_dump_isection): fixed bug which caused string literals to
7291         be omitted when dumping idata section,
7292         * (pic16_groupRegistersInSection): added code to handle registers
7293         in specific memory banks,
7294         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
7295         public, all references are renamed too,
7296         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
7297         AOP_DPTR2,
7298         * (pic16_storeForReturn): added case to handle when dest is WREG,
7299         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
7300         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
7301         pic16_rel_udata, check to see if that register is marked as being
7302         a member of a specific memory bank,
7303         * (pic16_printIvalCharPtr): added code to add string literals either
7304         to code or the idata sections,
7305         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
7306         also accept the 'udata' pragma,
7307         * src/pic16/main.h: new structure types sectName and sectSym
7308         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
7309         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
7310         * (pic16_findPrevInstruction): fixed, it returned nothing,
7311         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
7312         instruction combinations,
7313         * (pic16_FixRegisterBanking): heavily reorganised,
7314         * (pic16_AnalyzeBanking): if generating banksel directives is
7315         disabled, then don't call FixRegisterBanking at all,
7316         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
7317         completely removed,
7318         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
7319
7320 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
7321
7322         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
7323         Phuah Yee Keat <yk.phuah AT nestac.com>
7324
7325 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
7326
7327         * src/pic16/glue.c (pic16createInterruptVect): function now emits
7328         correctly the IVT even if it is relocated to some other location
7329
7330 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
7331
7332         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
7333         * device/include/pic16/pic18f2220.h: NEW,
7334         * device/lib/pic16/libdev/pic18f2220.c: NEW,
7335         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
7336         * src/pic16/device.c (struct Pics16): added info for 18f2220,
7337         * src/pic16/device.h (struct pic16_options): added ivt_loc and
7338         nodefaultlibs, ivt_loc is the location of the interrupt vector
7339         table, and nodefaultlibs signs that default libraries should not be
7340         linked in link stage,
7341         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
7342         according to --ivt-loc argument,
7343         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
7344         when pragma stack is found,
7345
7346 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7347
7348         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
7349         256 (range check), 257 (do while), 258.a-f (bit banging
7350         f.e. on 3-wire SPI bus)
7351
7352 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7353
7354         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
7355         variables used exclusively within a loop
7356
7357 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
7358
7359         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
7360
7361 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7362
7363         * src/SDCClrange.c (computeClash): fixed bug #971834
7364
7365 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7366
7367         * src/mcs51/gen.c (genCmp): fixed bug #975903
7368         * src/hc08/gen.c (operandsEqu),
7369         * src/ds390/gen.c (operandsEqu),
7370         * src/z80/gen.c (operandsEqu),
7371         * src/pic/gen.c (operandsEqu),
7372         * src/pic16/gen.c (operandsEqu),
7373         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
7374         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
7375
7376 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7377
7378         * src/SDCCcse.c (cseBBlock): fixed bug #966963
7379
7380 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
7381
7382         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
7383         default case in switch statement,
7384         * glue.c (pic16_initPointer): expr is initialised via decoarteType
7385         to eliminate problem with initialisation of pointers, but problem
7386         still exists,
7387         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
7388         * (emitStaticSegment): removed various lines emitting debug info,
7389         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
7390         added processor registers for utilizing EEPROM,
7391         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
7392         configurable and set 8
7393
7394 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
7395
7396         * .version: increased version number to 2.4.2,
7397
7398         Cumulative patch for pic16 port
7399         * src/pic16/device.c: changed scheme to dump initial values for
7400         variables in idata segment, all print_idata* functions were removed,
7401         now the pic16_printIval* will be called,
7402         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
7403         * _pic16_printPointerType, pic16_printPointerType,
7404         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
7405         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
7406         NEW, similar to the respective functions in SDCCglue.c,
7407         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
7408         way, emitting hex bytes,
7409         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
7410
7411 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7412
7413         * src/avr/ralloc.c (serialRegAssign),
7414         * src/xa51/ralloc.c (serialRegAssign),
7415         * src/pic/ralloc.c (serialRegAssign),
7416         * src/pic16/ralloc.c (serialRegAssign),
7417         * src/hc08/ralloc.c (serialRegAssign),
7418         * src/z80/ralloc.c (serialRegAssign),
7419         * src/ds390/ralloc.c (serialRegAssign),
7420         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
7421
7422 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7423
7424         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
7425         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
7426
7427 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
7428
7429         Cumulative patch for pic16 port:
7430         * src/pic16/device.h (typedef PIC16_device) modified fields for
7431         defining microcontrollers,
7432         * src/pic16/device.c: added new info for all devices in Pics16 array,
7433         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
7434         to be optimised out by the pCode optimiser,
7435         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
7436         specially, bug reported by G.M. Gallant,
7437         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
7438         as force'd so that cannot be optimised out by pCode optimiser,
7439         * src/pic16/pcode.c,
7440         * src/pic16/pcodepeeph.c,
7441         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
7442         they are disabled by default, but can be enabled explicit with
7443         command argument --denable-peeps, for testing,
7444         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
7445         --pomit-ivt in COMPILE_FLAGS
7446
7447 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
7448
7449         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
7450           compilation on MSVC
7451
7452 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
7453
7454         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
7455
7456 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7457
7458         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
7459         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
7460
7461 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
7462
7463         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
7464         would only assign 0x300001 register.
7465
7466 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
7467
7468         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
7469         in COMPILE_FLAGS. Thanks to G. Gallant for report.
7470
7471 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7472
7473         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
7474         for ds80c400
7475         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
7476         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
7477         added peephole 254 (left shift), 255 (jump table)
7478
7479 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
7480
7481         * device/lib/Makefile.in: removed comment line with model-pic16,
7482         * (target port-specific-objects-pic16): the libraries and objects
7483         are copied to the build directory form the device/lib/pic16/bin
7484         directory
7485
7486         Cumulative patch concerning pic16 port:
7487         * library directory has been re-organized,
7488         * added support for PIC18F1220,
7489         * added headers and library sources for chips 18f1220,18f6520,
7490         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
7491
7492         * configuration registers setting has changed, now each supported
7493         device has a complete description of the registers it uses,
7494         * all initialisations are moved to idata sections, these section
7495         can be absolute or relocatable,
7496         * fixed initialisation of codespace variables,
7497         * fixed warning about PCLATU and gpsim,
7498         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
7499         * (genAssign): use table reads when assigning from variables in codespace,
7500         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
7501         char/int variables placed in codespace,
7502         * (pic16_emitConfigRegs): NEW, emits a list with configuration
7503         registers set in .asm file, no need for --pomit-config-words anymore,
7504         * (pic16glue): some 8051 legacy segments are commented out
7505         (to be removed completely),
7506         * added support for alternative assembler and linker with --asm=
7507         and --link= command line arguments,
7508         * peepholes are disabled automatically in the port, no need to
7509         specify on command line,
7510         * port supports natively char/int/long multiplication, but converts
7511         all divisions to support functions,
7512         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
7513         to the file set in variable $2,
7514         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
7515         strings in ASCII format and not in hex,
7516         * ralloc.c (serialRegAssign): added a triplet of conditional calls
7517         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
7518         allocate proper register if iCodes aren't temporary,
7519
7520 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
7521
7522         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
7523
7524 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
7525
7526         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
7527         is commented out
7528
7529 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7530
7531         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
7532         computed address is reused
7533         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
7534         multi-byte bitfields
7535
7536 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
7537
7538         * src/z80/gen.c: (genArrayInit): must check for pointers too
7539
7540 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
7541
7542         * support/regression/tests/zeropad.c: never meant to commit the
7543           nestedstruct test: removed, added check for GCC version
7544
7545 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
7546
7547         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
7548         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
7549         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
7550           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
7551           bugs 928906 and 954082 half-empty initializers
7552         * src/SDCCsymt.h,
7553         * src/SDCCsymt.c (getAllocSize): added for above fix
7554         * src/z80/gen.c (genArrayInit): fixed bug 741044
7555         * support/regression/tests/zeropad.c: added tests
7556
7557 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
7558
7559         * src/pic16/device.c (pic16_dump_section): corrected bug which
7560         caused some symbols of the libraries to be misplaced
7561
7562 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
7563
7564         * src/pic16/glue.c,
7565         * src/pic16/ralloc.h,
7566         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
7567         to fix conflict with pic port
7568
7569 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
7570
7571         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
7572         externs configuration variables,
7573         * src/pic16/ralloc.h,
7574         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
7575         prototype in header, commented out some debug messages
7576
7577 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
7578
7579         * src/pic16/glue.c,
7580         * src/pic16/main.c,
7581         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
7582         for gpasm COFF object generation. Thanks to D. Hawkins for
7583         his patch info
7584
7585 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7586
7587         * src/ds390/main.c,
7588         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
7589         Brock for spotting this)
7590         * src/ds390/gen.c (genEndFunction),
7591         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
7592         interrupt handler and critical. Disable push/pop optimizations when
7593         peephole optimizations disabled.
7594
7595 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
7596
7597         Updated pic16 library sources and headers.
7598         * device/lib/pic16/pic18f*/ ,
7599         * device/include/pic16/*.h: modified to handle structured SFR
7600         definitions
7601
7602 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
7603
7604         * src/port.h (PORT structure): added hook initPaths, now each
7605         port can declare its own default search paths,
7606         which can been seen with the --print-search-dirs option,
7607         see pic16 port for example,
7608         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
7609         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
7610         * (doPrintSearchDirs): NEW, replaces in a central manner the
7611         printing of search dirs which was split in set*Paths functions,
7612         * (main): added call to port->initPaths and doPrintSearchDirs,
7613         * src/avr/main.c,
7614         * src/ds390/main.c,
7615         * src/hc08/main.c,
7616         * src/izt/i186.c,
7617         * src/izt/tlcs900h.c,
7618         * src/mcs51/main.c,
7619         * src/pic/main.c,
7620         * src/pic16/main.c: modified port structures to reflect addition of
7621         initPaths hook,
7622
7623         * src/pic16/device.c (regCompare): registers are finally sorted by name,
7624         * (pic16_dump_section): for registers in same address reserve memory once,
7625         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
7626         to no_banksel,
7627         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
7628         result is greater in size than right or left,
7629         * (pic16_genUMult8X8_8): there are some cases where the result can
7630         be 16 bits size, so handle these,
7631         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
7632         * (pic16_outBitC): modified to emit pcodes,
7633         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
7634         or not,
7635         * (genDivOneByte): implemented algorithm to divide 8-bits,
7636         * (genCmp): uncommented goto, but issues still exist,
7637         * (genAnd): fixed a bug with variables >8bits,
7638         * (genPackBits): optimization added that uses BCF/BSF to change a
7639         single bit,
7640         * (genAssign): fixed bug when assigning floating point literals,
7641         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
7642         __sdcc_gsinit_startup label,
7643         * src/pic16/main.c (_pic16_init): removed search directory
7644         initialisations,
7645         * (_pic16_initPaths): NEW, used to initialise search directories,
7646         * (_hasNativeMulFor): support functions for all except char/int
7647         multiplication, and char division,
7648         * (PIC16_port struct): modified entry for native mul support,
7649         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
7650         no_banksel option,
7651         * (buildCallTree): call to register_usage is ifdef'ed out,
7652
7653 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7654
7655         * device/include/string.h: applied Stas Sergeev's patch to make this
7656         header file compatible with the preprocessor -Wundef option
7657         * src/SDCCmain.c (main): abort compilation if preprocessor reports
7658         failure (fixes bug #941458)
7659
7660 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7661
7662         * src/SDCCopt.c (killDeadCode): fixed bug #907733
7663         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
7664         that the variable, not the function, should be static
7665         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
7666         to be consistent with non-literal case
7667
7668 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7669
7670         * src/SDCCast.c (isConformingBody): fixed bug #949967
7671         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
7672         convilong): fixed bug #952086
7673
7674 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7675
7676         * src/SDCCmem.c (allocVariables): fixed bug #955321
7677
7678 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7679
7680         * src/hc08/main.c (_hc08_genAssemblerEnd),
7681         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
7682         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
7683         completely eliminated the use of a temporary file
7684         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
7685         when more than one file linked
7686         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
7687
7688 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7689
7690         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
7691         which fixes bug #543481
7692         * support/regression/tests/bug-751703.c: fixed comments left from a
7693         cut and paste error
7694         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
7695         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
7696         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
7697         scopes
7698         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
7699         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
7700         are now changed to underscores in moduleName
7701
7702 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7703
7704         * as/mcs51/lkmem.c: better fix for bug #954173
7705
7706 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
7707         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7708
7709         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
7710         * device/include/c8051f000.h,
7711         * device/include/c8051f120.h,
7712         * device/include/c8051f300.h,
7713         * device/include/c8051f310.h,
7714         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
7715         PWM16) and detab'ed
7716
7717 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7718
7719         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
7720         and mailing lists, doc'ed --no-peep-comments, removed reference
7721         to knoppix (newest version has no LyX/LaTeX), other minor changes
7722         * src/SDCCglue.c (glue): save 2 bytes stack space with
7723         option --main-return. The ljmp could probably be avoided too
7724
7725 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7726
7727         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
7728
7729 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7730
7731         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
7732         * src/SDCCopt.c (isLocalWithoutDef),
7733         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
7734         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
7735         (credit to Maarten Brock for patch #949363, on which this is based)
7736         * support/regression/tests/bug-751703.c: some test cases of extern used
7737         within inner scopes.
7738
7739 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7740
7741         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
7742         SPEC_STRUCT
7743         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
7744         struct definitions
7745         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
7746         dwWriteLabel): fix to create valid debugger symbols even when
7747         the module name has non-alphanumeric symbols in it
7748         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
7749         when a variable's allocation has been optimized away
7750
7751
7752 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7753
7754         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
7755         * src/hc08/main.c,
7756         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
7757         * src/mcs51/main.c,
7758         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
7759         * src/ds390/main.c,
7760         * src/z80/gen.c (z80_emitDebuggerSymbol),
7761         * src/z80/main.c,
7762         * src/pic/gen.c (pic14_emitDebuggerSymbol),
7763         * src/pic/main.c,
7764         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
7765         * src/pic16/main.c,
7766         * src/avr/gen.c (avr_emitDebuggerSymbol),
7767         * src/avr/main.c,
7768         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
7769         * src/xa51/main.c,
7770         * src/SDCCdebug.c (emitDebuggerSymbol),
7771         * src/SDCCdebug.h,
7772         * src/port.h: added a debugger struct to the port struct. Added a
7773         callback for defining debugger symbols
7774
7775         * src/SDCCast.c (createLabel),
7776         * src/SDCC.y (labeled_statement): mark all compiler generated labels
7777         with isitmp = 1
7778         * src/SDCCicode.h,
7779         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
7780         iCode back to the ast for the function
7781
7782         * src/hc08/ralloc.c (hc08_assignRegisters),
7783         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
7784         unneeded fields from the regs struct.
7785         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
7786         pushReg() & pullReg() functions instead of emitcode()
7787
7788         * src/hc08/gen.c (genLabel, genhc08Code),
7789         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
7790
7791         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
7792         debugger hooks
7793
7794         * src/hc08/gen.c (genEndFunction, genhc08Code),
7795         * src/hc08/gen.h,
7796         * src/mcs51/gen.c (genEndFunction, gen51Code),
7797         * src/mcs51/gen.h,
7798         * src/ds390/gen.c (genEndFunction, gen390Code),
7799         * src/ds390/gen.h,
7800         * src/z80/gen.c (genEndFunction, genZ80Code),
7801         * src/z80/gen.h,
7802         * src/z80/z80.h,
7803         * src/pic/gen.c (genEndFunction, genpic14Code),
7804         * src/pic/gen.h,
7805         * src/pic16/gen.c (genEndFunction, genpic16Code),
7806         * src/pic16/gen.h,
7807         * src/avr/gen.c (genEndFunction, genAVRCode),
7808         * src/avr/gen.h,
7809         * src/xa51/gen.c (genEndFunction, genXA51Code),
7810         * src/xa51/gen.h,
7811         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
7812         specific code to cdbFile.c and out of the backend code generators
7813
7814         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
7815         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
7816         starting address is now 0
7817
7818         * as/hc08/asm.h,
7819         * as/hc08/m08pst.c,
7820         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
7821         assembler directive for DWARF support
7822         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
7823
7824         * src/src.dsp,
7825         * src/Makefile.in,
7826         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
7827
7828 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7829
7830         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
7831         and inappropriate peephole optimization in jump tables
7832
7833 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7834
7835         * as/hc08/m08pst.c,
7836         * src/SDCCglue.c: sdccopt works for the hc08 port now
7837
7838 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
7839
7840         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
7841
7842 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7843
7844         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
7845
7846 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7847
7848         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
7849         rules
7850         * src/SDCCmain.c,
7851         * src/SDCCglobl.h,
7852         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
7853         comments from the peephole optimizer replacement rules
7854         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
7855         symbols
7856         * src/SDCCcse.c (updateSpillLocation),
7857         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
7858         equivalents
7859         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
7860         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
7861         objects far pointers
7862
7863 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7864
7865         * src/SDCCsymt.h: a missing part of my last change
7866         * src/pic/ralloc.c (regTypeNum),
7867         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
7868
7869 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7870
7871         * src/SDCCicode.h,
7872         * src/SDCCicode.c (aggrToPtrDclType),
7873         * src/SDCCptropt.h,
7874         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
7875         ptrPseudoSymConvert),
7876         * src/pic/ralloc.c (regTypeNum),
7877         * src/pic16/ralloc.c (regTypeNum),
7878         * src/hc08/ralloc.c (regTypeNum),
7879         * src/ds390/ralloc.c (regTypeNum),
7880         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
7881         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
7882
7883 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7884
7885         * link/z80/lkmain.c (afile),
7886         * as/hc08/lkmain.c (afile),
7887         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
7888         prevent a pointer problem when a filename has no directory and
7889         no extension specified.
7890
7891 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7892
7893         * link/z80/lkmain.c (afile): allow periods in directory names
7894         * link/z80/lkmain.c (afile),
7895         * as/mcs51/lkmain.c (afile),
7896         * as/hc08/lkmain.c (afile): allow linker script file to have an
7897         extension other than ".lnk"
7898         * link/z80/lklex.c (getfid),
7899         * link/z80/lkmain.c (parse),
7900         * as/mcs51/lklex.c (getfid),
7901         * as/mcs51/lkmain.c (parse),
7902         * as/hc08/lklex.c (getfid),
7903         * as/hc08/lkmain.c (parse): Support comments in the linker script
7904         file on lines by themselves and after filenames
7905
7906 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7907
7908         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
7909
7910 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7911
7912         * src/z80/peeph-z80.def: removed some peephole rules that don't
7913         work with multibyte arithmetic (fixed bug #937126)
7914         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
7915         to registers and not global variables
7916         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
7917         geniCodePreInc, geniCodePostDec, geniCodePreDec,
7918         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
7919         checking for assignments not internally generated (fixed bug #931895)
7920         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
7921         structure member (fixed bug #930072)
7922
7923 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7924
7925         * src/SDCCmain.c (linkEdit),
7926         * src/hc08/main.c (_hc08_parseOptions),
7927         * as/hc08/Makefile.in,
7928         * as/hc08/aslink.h,
7929         * as/hc08/asm.h,
7930         * as/hc08/m08pst.c,
7931         * as/hc08/lkrloc.c (relr, rele),
7932         * as/hc08/lkarea.c (lnkarea)
7933         * as/hc08/lkmain.c (afile, parse),
7934         * as/hc08/lkelf.c: support for ELF output
7935         * as/hc08/lks19.c (s19),
7936         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
7937
7938 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7939
7940         * as/mcs51/lkihx.c: Fixed bug #899105.
7941
7942 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7943
7944         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
7945         .dsp files from Unix to DOS.
7946
7947 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7948
7949         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
7950         function pointers; we have been compliant for several months now.
7951         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
7952         change that was accidently commented out
7953         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
7954         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
7955         bug #922319
7956
7957 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7958
7959         * src/hc08/gen.c: output of all of the internal debugging information
7960         is now controlled by the D() macro; it is disabled by default
7961
7962 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7963
7964         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
7965         harder to keep the same registers during a CAST iCode
7966         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
7967         long via int can be done in a single cast, if the signedness is
7968         correct.
7969         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
7970         putchar() in tinibios.c in ds390's library
7971
7972 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
7973
7974         * src/SDCCast.c (decorateType): fixed bug #898889,
7975         cast result of a literal complement too
7976         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
7977         fixed check for bitfields
7978
7979 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
7980
7981         * src/SDCCicode.c (geniCodeLogic): made it static,
7982         (geniCodeLogicAndOr): added in order to fix bug #905492,
7983         (ast2iCode): fixed bug #905492
7984         * support/regression/tests/bug-905492.c: added
7985         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
7986         (processParms): fixed bug #927659: don't copy parms, this will clear
7987         decorated flag
7988         * support/regression/tests/bug-927659.c: added
7989
7990 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
7991
7992         * src/SDCCast.c (addCast): don't cast float to char
7993         * device/lib/libsdcc.lib: added _memmove
7994
7995 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
7996
7997         * device/lib/large/Makefile: fixed parallel execution by
7998         replacing `make` by `$(MAKE)`
7999
8000 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8001
8002         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
8003         offsets (fixes bug #923936)
8004
8005 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
8006
8007         * device/lib/small/Makefile: fixed parallel execution by
8008         replacing `make` by `$(MAKE)`
8009
8010 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
8011
8012         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
8013
8014 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
8015
8016         * src/pic/gen.c (genCpl): multi-byte complements were not working.
8017         * src/regression/Makefile: Regression test was not running.
8018
8019 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
8020
8021         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
8022         complement if possible
8023         * src/SDCCval.c (valComplement),
8024         * src/SDCCicode.c (operandOperation): fixed complement of literal
8025         * support/regression/tests/onebyte.c (testComplement): added
8026
8027 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
8028
8029         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
8030         return an optimized tree; actually replace actParm with the new tree
8031         * src/SDCCast.h: added some parantheses to remove side effects
8032         * support/regression/tests/bug-920866.c
8033
8034 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
8035         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
8036         Bit operands were not being handled properly in the pic14 port.
8037         (now src/regression/add.c passes again).
8038
8039 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8040
8041         * src/SDCC.y (labeled_statement): case and default no longer require
8042         a following statement (RFE #893037)
8043
8044 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8045
8046         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
8047         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
8048         disabled (fixes bug #916294)
8049         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
8050         "mov a,acc"; patch provided by Lenny Story
8051         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
8052
8053 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8054
8055         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
8056         functions
8057         * src/ds390/gen.c (genFunction, genEndFunction),
8058         * src/ds390/ralloc.c (ds390_assignRegisters),
8059         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
8060         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
8061         pushed if there are parameters passed on the stack. Also, a cleaner
8062         way to decide if r0/r1 should be pushed/popped. (Together they fix
8063         bug #918693)
8064
8065 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8066
8067         * doc/sdccman.lyx,
8068         * device/lib/mcs51/crtpagesfr.asm,
8069         * device/lib/mcs51/crtxinit.asm,
8070         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
8071         to avoid confusion with Si Lab's SFRPAGE register.
8072
8073 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8074
8075         * src/SDCCglue.c (emitMaps): allow public sfr variables
8076         * src/SDCCglue.c (initialComments): include compiler build date
8077         with compiler version and put the timestamp of the generated
8078         assembly file on a serperate line to be less confusing.
8079         * src/port.h: added genInitStartup hook
8080         * src/avr/main.c,
8081         * src/ds390/main.c,
8082         * src/hc08/main.c,
8083         * src/pic/main.c,
8084         * src/pic16/main.c,
8085         * src/xa51/main.c,
8086         * src/z80/main.c: genInitStartup initialize as NULL (default to
8087         historical behaviour)
8088         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
8089         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
8090         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
8091         library instead of hard coding it into the compiler.
8092         * support/regression/ports/mcs51-stack-auto/spec.mk,
8093         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
8094         * device/lib/mcs51/Makefile,
8095         * device/lib/small/Makefile,
8096         * device/lib/large/Makefile,
8097         * device/lib/mcs51/crtpagesfr.asm,
8098         * device/lib/mcs51/crtstart.asm,
8099         * device/lib/mcs51/crtxclear.asm,
8100         * device/lib/mcs51/crtxinit.asm,
8101         * device/lib/mcs51/crtclear.asm,
8102         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
8103         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
8104         and into user configurable files.
8105         * device/lib/clean.mk: clean mcs51 directory too
8106         * support/regression/tests/longlit.c: added static to T1 declaration
8107         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
8108         accesses in the initialization code
8109
8110 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8111
8112         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
8113         OSCTRIMVAL as noted in bug #916008
8114
8115 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8116
8117         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
8118         in loops with multiple exits (reported as incorrect registers
8119         used by Martin Helmling in Sdcc-user list)
8120
8121 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8122
8123         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
8124         made ds390 register extensions look less like error messages
8125
8126 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8127
8128         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
8129         reported by Adam Wozniak in Sdcc-user list
8130
8131 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
8132
8133         * src/SDCCast.c (decorateType): fixed with bug and promotion in
8134         arithmetic optimizations, added debug output
8135
8136 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
8137
8138         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
8139         * sdcc.spec: updated and split sdcc into 3 rpms
8140         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
8141         needed for literals of LEFT_OP and '+'
8142         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
8143         introduced RESULT_TYPE_NOPROM
8144         (geniCodeMultiply): fixed logic for decision if mul is optimized to
8145         left shift
8146         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
8147         limited promotion to int only for '*'
8148         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
8149
8150 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
8151
8152         * src/pic16/gen.c (genSkip),
8153         (genc16bit2lit), (gencjneshort): commented out
8154         (is_LitOp): new helper function, checks operand type
8155         (genCmpEq): rewritten
8156
8157 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
8158
8159         * support/regression/tests/bug-908454.c: added
8160
8161 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
8162
8163         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
8164         * src/SDCCicode.c (usualBinaryConversions): op needs int type
8165         (geniCodeCast): cosmetic, don't preserve bit storage class
8166         (geniCodeLeftShift): added promotion
8167         (geniCodeLogic): fixed regression
8168         * src/SDCCsymt.c (computeTypeOr): accept bits too
8169         (compareType): 2nd part of fix for bug #908454, needed for bitfields
8170
8171 2004-03-07  Borut Razem <borut.razem AT siol.net>
8172
8173         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
8174
8175 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
8176
8177         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
8178         version of pic16_genPackRegisters which does not check if ic is a
8179         CAST operator,
8180         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
8181         function cause string1.c regression test fails
8182
8183 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
8184
8185         * sim/ucsim/configure.in,
8186         * sim/ucsim/configure,
8187         * sim/ucsim/doc/Makefile.in: use docdir
8188         * src/SDCC.y: fixed sbit atrributes
8189         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
8190         * src/SDCCast.c (decorateType): |^& need special promotion handling
8191         * src/SDCCast.h,
8192         * src/SDCCsymt.h: moved definition of RESULT_TYPE
8193         * src/SDCCsymt.h (computeType),
8194         * src/SDCCicode.c: computeType() needs op
8195         * src/SDCCsymt.c (checkTypeSanity),
8196         * doc/sddman.lyx: "plain" bitfields are unsigned
8197         * src/SDCCsymt.c (computeTypeOr): added
8198         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
8199         |^& ops
8200         * src/SDCCval.c (val*): computeType() needs op
8201         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
8202         * support/regression/tests/onebyte.c: added tests for |^&
8203
8204 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
8205
8206         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
8207         for writing icode into asm output.
8208
8209 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
8210
8211         * src/pic16/device.c: added some debug lines enabled
8212         with macro DEBUG_CHECK,
8213         * src/pic16/genarith.c: more debug in genPlus,
8214         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
8215         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
8216         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
8217         * (aopForSym): onStack symbols are re-placed in data memspace,
8218         and onStack flag is cleared,
8219         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
8220         copy temporary pcodeop,
8221         * (genPcall): added warning for not updating PCLATU,
8222         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
8223         always true for pic16 port,
8224         * (genMultOneWord): NEW, supports integer multiplication,
8225         * (genMult): modified to call genMultOneWord,
8226         * (ifxForOp): added warning when return NULL,
8227         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
8228         flag is set before call to operandFromSymbol for implicit
8229         added structures,
8230         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
8231         options.intlong_rent are set by default,
8232         * (_hasNativeMulFor): modified to allow port generation of integer
8233         multiplication,
8234         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
8235         set regtype to REG_SFR for all registers, restricting seting the
8236         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
8237
8238 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8239
8240         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
8241         more than 500 times in the regression tests
8242
8243 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8244
8245         * support/Util/SDCCerr.h,
8246         * support/Util/SDCCerr.c,
8247         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
8248         enumerator_list),
8249         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
8250         for symbol conflicts.
8251         * support/valdiags/tests/enum.c,
8252         * support/valdiags/tests/tentdecl.c,
8253         * support/valdiags/tests/struct.c: expect possible error messages
8254         referring to original symbol definitions.
8255         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
8256         * src/SDCCsymt.h,
8257         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
8258
8259 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
8260
8261         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
8262
8263 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
8264
8265         * src/pic16/ralloc.c (newReg): fixed bug #908929
8266
8267 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8268
8269         * src/ds390/gen.c: added missing #include "main.h"
8270
8271 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
8272
8273         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
8274         checking if symbol is already in set,
8275         * src/pic16/device.h: prototype for checkAddSym,
8276         * src/pic16/gen.c: (_G): added entry interruptvector,
8277         * (assignResultValue): removed some commented out lines,
8278         * (genFunction): check for ISR via sym->type, absolute section for
8279         interrupt code is created via a new pBlock, the goto instruction is
8280         placed now correctly at the interrupt vector position, changed all
8281         references from ivec to _G.interruptvector,
8282         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
8283         is the interrupt is a high priority one, same for return from ISR,
8284         * src/pic16/glue.c: changed all calls of addSetHead for publics and
8285         externs to calls of checkAddSym,
8286         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
8287         pic16_pcode_verbose flag is set,
8288         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
8289         * src/pic16/pcoderegs.c: message about how many registers are saved
8290         will only be emitted if pic16_pcode_verbose flag is set,
8291
8292 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8293
8294         * src/ds390/ralloc.h,
8295         * src/ds390/ralloc.c (ds390_regWithIdx),
8296         * src/ds390/gen.c (emitcode),
8297         * src/ds390/main.h,
8298         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
8299         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
8300         ds390operandCompare, getRegsRead, getRegsWritten,
8301         initializeAsmLineNode): customized instruction size calculation for
8302         ds390, started basis for some register optimizations
8303         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
8304         corresponding assembly output
8305         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
8306         missing push/pop of r0/r1. Optimized push/pops
8307
8308 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8309
8310         * src/mcs51/main.c (instructionSize): fixed ACALL size
8311         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
8312
8313 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
8314
8315         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
8316         the sorting of rlist with NULL elements
8317         * (print_idataType, print_idata): NEW to create idata sections
8318         * src/pic16/device.h: idataSymSet new variable
8319         * src/pic16/gen.c (genFunction): fixed some bugs in string
8320         comparing, improved the absolute section creation for ISRs,
8321         added FSR0L/FSR0H in registers that are saved in an ISR,
8322         * (genInline): fixed the processing of inline snippets,
8323         now they undergo no process by the peephole optimizer
8324         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
8325         are placed in idataSymSet,
8326         * (pic16emitStaticSeg): extern symbols are added in externs,
8327         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
8328         switching when aboslute variables are placed in access bank memory
8329         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
8330         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
8331         commented out with #if,
8332         * (pic16_packRegisters): reintroduce the check for CAST because some
8333         symbols are not correctly handled,
8334         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
8335         pCodeInstruction instead of pCode,
8336         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
8337         pCodeAsmDir definition,
8338         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
8339         directive, then the argument directive is emitted without the leading
8340         tab, hack for inline labels which must be in the first column,
8341         * (compareLabel,pic16_findNextInstruction),
8342         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
8343         * (insertBankSwitch): modified for the new pCodeAsmDir,
8344
8345 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8346         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
8347
8348         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
8349         instance,
8350         * (pushSide): commented out with #if,
8351         * (assignResultValue): fixed some typos in saving
8352         registers,
8353         * (genPcall): FIXED and sync'ed with genCall,
8354         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
8355         * (genNearPointerGet): fixed to handle some more cases,
8356         implementation scheme via table reads,
8357         * (genConstPointerGet): modified to access code memory correct,
8358         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
8359         and improved to handle some cases
8360         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
8361         instead of "RETLW" for init data
8362         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
8363         not IN_DIRSPACE, work around to reduce bank switching when aboslute
8364         variables are placed in access bank memory (<0x80 and >=0xf80),
8365         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
8366         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
8367         TBLWT_POSTDEC,TBLWT_PREINC
8368         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
8369         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
8370         directives
8371         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
8372         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
8373         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
8374         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
8375
8376 2004-02-29  Borut Razem <borut.razem AT siol.net>
8377
8378         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
8379         support/Util/findme.h, support/Util/system.h: enhance binary relative
8380         search for lib and include by using findProgramPath()
8381
8382 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8383
8384         * src/SDCCpeeph.h,
8385         * src/SDCCpeeph.c (pcDistance),
8386         * src/port.h,
8387         * src/mcs51/ralloc.h,
8388         * src/mcs51/ralloc.c (mcs51_regWithIdx),
8389         * src/mcs51/main.h,
8390         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
8391         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
8392         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
8393         size calculation port specific, started basis for some register
8394         optimizations
8395         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
8396         missing push/pop of r0/r1. Optimized push/pops
8397         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
8398         * device/lib/_modsint.c (_modsint),
8399         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
8400         and stack version so regression tests pass
8401
8402 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
8403
8404         * src/Makefile.in (dep): include SLIBOBJS in dependency check
8405         * src/SDCCast.c (decorateType): catch another small optimization
8406         with '?' operator
8407         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
8408         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
8409         modified to finally use computeType() all over SDCC,
8410         see Feature Request #877103
8411         * src/SDCCval.h: cosmetic
8412         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
8413         valCompare(); regression tested in muldiv.c
8414         * support/regression/tests/muldiv.c (testMod): mod sign follows
8415         dividend only
8416
8417 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
8418
8419         * src/SDCCast.c (decorateType): fixed bug #902362
8420         * doc/INSTALL.txt: fixed install instructions for win32
8421
8422 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
8423
8424         * device/include/Makefile.in (install): fixed by replacing spaces
8425         by tabs
8426         * doc/README.txt,
8427         * doc/INSTALL.txt: updated for release
8428         * doc/sdccman.lyx: added warning for --xstack being buggy
8429
8430 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
8431
8432         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
8433         to eliminate build warnings.
8434         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
8435
8436 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
8437            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8438
8439         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
8440         removed -penable-stack, added comment for stack pragma, added
8441         warning for not initializing the stack/frame registers, removed
8442         comment at interrupts section
8443
8444         Stack is made permanent, there is no ability to disable stack usage.
8445         * src/pic16/device.h,
8446         * src/pic16/device.c: removed all references to USE_STACK macro,
8447         * src/pic16/device.c (pic16_dump_section): when no elements in
8448         rlist, free rlist before return,
8449         * (pic16_dump_int_registers): NEW, internal registers are a new set
8450         of general purpose registers reused by each function,
8451         * (checkAddReg): returns 1 if registers is added to set,
8452         * (pic16_groupRegistersInSection): when a registers is of type
8453         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
8454         * src/pic16/device.h: memRange and Assigned Memory are deleted,
8455         SRCASECMP macro is moved here from device.c
8456         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
8457         PO_PCLATU, PO_PRODL, PO_PRODH,
8458         * (pic16_pCodeOpType, genMinus,
8459         changed compares to "a" register, with AOP_ACC,
8460         * (pic16_genPlus): fixed some bugs and indented properly,
8461         * (pic16_addSign): changed size to size+offset in the MOVWF
8462         instruction,
8463         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
8464         multiply 8-bit operand by literal, result is 8-bit,
8465         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
8466         multiply 2 8-bit operand, result is 8-bit,
8467         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
8468         genUMult8X*_16,
8469         * src/pic16/gen.c: changed accUse to contain WREG only,
8470         * (pic16_emitcomment): renamed to pic16_emitpcomment,
8471         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
8472         true, do not use immediate addressing any more unless sym is a
8473         pointer in codespace,
8474         * (aopForRemat): do not use immediate addressing when symbol not in
8475         codespace and when symbol's address is requested,
8476         * (aopOp): for-loop in if(sym->accUse) is modified for the new
8477         accUse size (= 1),
8478         * (aopGet): added case for AOP_ACC and don't return "accumulator
8479         bug" but WREG instead,
8480         * (popGetTempReg): pushes contents of temporary register in stack,
8481         * (popReleaseTempReg): pops contents of temporary register from
8482         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
8483         * (pic16_popGet): separated case AOP_ACC to return register WREG
8484         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
8485         or PO_IMMEDIATE and initializes their instance/offset appropriately,
8486         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
8487         the use of immediate pointers to certain cases only.
8488
8489         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
8490         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
8491         * (assignResultValue, genCall, genRet): modified to use the new
8492         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
8493         genPcall is still broken,
8494         * (genFunction): added code to create 'A' type pBlocks when
8495         interrupt functions are generated, code not extensively tested yet,
8496         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
8497         * (genEndFunction): modified so ISRs pop stored registers from stack,
8498         * (genMultOneByte): cleanup,
8499         * (AccRsh): added flag andmask, to and result with appropriate mask,
8500         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
8501         * (genDataPointerGet): fixed and reenabled its use,
8502         * (genNearDataPointerGet): bugs fixed,
8503         * (genDataPointerSet): bugs fixed,
8504         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
8505         pic16_DumpSymbol, pic16_DumpOp,
8506         * src/pic16/genutils.h: function prototypes for the above functions,
8507         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
8508         pointers,
8509         * (pic16emitRegularMap): many many many improvements, but needs a
8510         major cleanup,
8511         * src/pic16/main.c: enable_stack in pic16_options is removed,
8512         * (_pic16_parseOptions): removed command line options -penable-stack,
8513         * (_process_pragma): emit stack symbol only when stack pragma is
8514         processed,
8515         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
8516         redirected to FSR0L/FSR0H pair,
8517         * (pic16_get_op, pic16_get_op2): modifications and improvements,
8518         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
8519         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
8520         for immediates,
8521         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
8522         * (dumpPicOptype): NEW,
8523         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
8524         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
8525         with movff instruction,
8526         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
8527         added pic16_int_regs, some packRegsFor* functions are commented out,
8528         because produce errors,
8529         * src/pic16/NOTES: minor modifications
8530
8531 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8532
8533         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
8534         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
8535         --pack-iram.
8536         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
8537         * as/mcs51/lkaomf51.c: fixed bug #895763
8538
8539 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
8540
8541         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
8542
8543 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8544
8545         * doc/sdccman.lyx: added details about the HC08 storage classes and
8546         interrupts, fixed the register usage info for z80 & gbz80
8547
8548 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
8549
8550         * doc/sdccman.lyx: added more pic16 port documentation
8551         * device/include/pic16/: added header pic18fregs.h
8552
8553 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
8554
8555         * doc/sdccman.lyx: added Vangelis' contribution
8556
8557 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8558
8559         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
8560         extend to the next CALL or PCALL, not just to the next CALL.
8561
8562 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
8563
8564         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
8565
8566 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8567
8568         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
8569         bug #895752 and a better fix for bug #716790
8570
8571 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8572
8573         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
8574
8575 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8576
8577         * doc/sdccman.lyx: minor changes, minor changed
8578
8579 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
8580
8581         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
8582         which can't handle SDCC_NEWONEBYTEOPS,
8583         (geniCodeMultiply): removed conversion from mult to shift for pic14
8584         and pic16
8585
8586 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8587
8588         * src/hc08/gen.h,
8589         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
8590         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
8591         thus fixing bug #895406
8592
8593 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
8594
8595         * device/lib/_modsint.c,
8596         * device/lib/_modslong.c: sign follows divisor only
8597         * src/hc08/gen.c (genMultOneByte): if result size is 1,
8598         signs or signedness can be ignored
8599         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
8600         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
8601         added optimization for IFX,
8602         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
8603         arguments;
8604         reenabled optimization for IFX, which was removed on 2004-01-11
8605         * src/SDCCast.h: added return type IFX
8606         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
8607         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
8608         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
8609         SDCC_OLDONEBYTEOPS selects the old behaviour
8610         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
8611         changed again and commented promotion rule
8612         * src/SDCCval.c (valDiv): promotion no longer necessary
8613         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
8614         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
8615         rewritten
8616         * support/regression/tests/onebyte.c: added
8617
8618 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
8619
8620         * gen.c (genInline): reverted to old code for assemnling inline
8621         code because of bug reported James Chadd
8622
8623 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
8624
8625         * ralloc.h: missing declarations from previous patch,
8626         seems that patch for ralloc.h was never applied, fixed
8627
8628 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8629            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
8630
8631         * pcode.c,
8632         * pcode.h,
8633         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
8634         indirect addressing. Marked FSR0 as deprecated
8635         * gen.c (pointerCode): commented out, not needed now
8636         (pic16_popGet2p): new MOVFF helper function
8637         (genGenPointerGet),
8638         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
8639         (shiftRLong): removed duplicate debugging info
8640
8641 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8642
8643         * src/ds390/gen.c (genNearPointerGet),
8644         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
8645         optimization with bits, but not bitfields.
8646         * src/ds390/ralloc.c (packRegisters),
8647         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
8648
8649 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
8650
8651         * src/SDCCcse.c (algebraicOpts): copy operands before modification
8652
8653 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8654
8655         * src/SDCCsymt.h,
8656         * src/SDCCicode.c (operandFromSymbol),
8657         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
8658         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
8659         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
8660         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
8661         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
8662         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
8663         bug #892038
8664         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
8665         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
8666         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
8667         * src/SDCCsymt.c (newSymbol),
8668         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
8669         enumerator_list),
8670         * src/SDCCval.h,
8671         * src/SDCCval.c (newiList): fixed bug #885705
8672
8673 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8674
8675         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
8676         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
8677
8678 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8679
8680         * device/include/c8051f120.h,
8681         * device/include/c8051f300.h,
8682         * device/include/c8051f310.h: added/updated header files for Silicon
8683         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
8684         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
8685         in new section Submitting patches
8686
8687 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8688
8689         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
8690         genFarPointerGet, genCodePointerGet, genGenPointerGet,
8691         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
8692         genGenPointerSet),
8693         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
8694         genFarPointerGet, genCodePointerGet, genGenPointerGet,
8695         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
8696         genGenPointerSet),
8697         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
8698         genFarPointerGet, genCodePointerGet, genGenPointerGet,
8699         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
8700         genGenPointerSet),
8701         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
8702         genFarPointerGet, genCodePointerGet, genGenPointerGet,
8703         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
8704         genGenPointerSet): fixed bug #892400
8705         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
8706         to eliminate build warnings.
8707         * src/SDCCast.c (processParms),
8708         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
8709         fixed bug 751859
8710         * support/valdiag/valdiag.py: added GCC to the list of defines active
8711         when compiling with gcc
8712
8713 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8714
8715         * support/Util/SDCCerr.h,
8716         * support/Util/SDCCerr.c,
8717         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
8718         with an incomplete type (fixed bug #883734)
8719         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
8720
8721 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8722
8723         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
8724
8725 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8726
8727         * src/SDCCast.c (decorateType),
8728         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
8729         function pointer implementation
8730         * support/regression/tests/funptrs.c: added tests to verify both forms
8731         of function pointers work correctly. Added tests to verify parameters
8732         are passed in the correct order.
8733
8734 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
8735
8736         * device.c (regCompare): registers are sorted by ascending
8737         address and increasing size,
8738         * main.c (_pic16_finaliseOptions): removed the declaration
8739         of compiler macro MCU. Now a macro of the format pic18fxxxx
8740         will be defined from the command line
8741
8742 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
8743             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
8744
8745         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
8746         PCOP_RLCF was overwritten!
8747         * gen.c (genSkip): commented out calls to pic16_emitcode,
8748         * (genCmpEQ): fixed "long" compares, only high word did get compared,
8749         * (genlshTwo),
8750         * (genRRC): added debugging info,
8751         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
8752         overwritten while shifting,
8753         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
8754         overwritten while shifting,
8755         * (AccLsh),
8756         * (AccRsh),
8757         * (shiftLLeftOrResult),
8758         * (shiftRLeftOrResult),
8759         * (shiftRLong),
8760         * (shiftLLong): Implemented with pic16_emitpcode
8761         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
8762         * (genLeftShift): Fixed bug, operand for shift by variable always
8763         was "and"ed with 0x0f,
8764         * (genLeftShiftLiteral),
8765         * (genrshTwo),
8766         * (genRightShiftLiteral): added debugging info,
8767         * (genrshFour): added comment,
8768         * (genRightShift): determined signedness from operand "left"
8769         instead of "result"
8770
8771 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8772
8773         * src/SDCCicode.c (geniCodeParms),
8774         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
8775         function pointers, fixed function pointer bugs #861242 and #861896
8776
8777 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8778
8779         * device/include/c8051f000.h,
8780         * device/include/c8051f120.h,
8781         * device/include/c8051f300.h: added header files for Silicon
8782         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
8783
8784 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
8785
8786         * src/SDCCast.c (processParams): added new type flow and restructured
8787         (gatherAutoInit): added new type flow
8788         (addCast): cosmetic changes
8789         (getLeftResultType): added new type flow for array indices, patch
8790         provided by Stas, see FR #877103
8791         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
8792         array index patch by Stas
8793         * src/SDCCast.h: added prototype getResultTypeFromType()
8794         * src/SDCCval.h,
8795         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
8796         * src/pic/glue.c (pic14emitStaticSeg),
8797         * src/pic16/glue.c (pic16emitStaticSeg),
8798         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
8799         for initialization of symbols
8800         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
8801         * support/Util/SDCCerr.h:
8802         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
8803         * .version: bumped version number to 2.3.8
8804         * device/include/Makefile.in (install),
8805         * doc/Makefile (install): changed to 'rm `find ...`' construct to
8806         avoid warnings
8807
8808 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
8809
8810         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
8811         Slade Rich fixed an optimization bug
8812         * src/pic/pcodepeep.c,
8813         * src/pic/pcoderegs.c
8814         * doc/Makefile (install): added test for directory
8815
8816 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8817
8818         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
8819         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
8820         * src/pic/ralloc.c (getRegPtr, getRegGpr),
8821         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
8822         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
8823         * as/mcs51/asexpr.c (term),
8824         * as/hc08/asexpr.c (term): fixed bug #887146
8825
8826 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8827
8828         * src/z80/gen.c (genMult): handle single byte result product
8829         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
8830         DUMMY_READ_VOLATILE (fixed bug #886367)
8831
8832 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
8833
8834         * support/regression/tests/libmullong.c: fixed logic, on little endian
8835         hosts we ended without a mullong_wrapper()
8836
8837 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8838
8839         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
8840         virus/worm forged address usage.
8841
8842 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
8843
8844         Fixed promotion, it should be done on AST level:
8845         * src/SDCCast.c (addCast): added promotion to int
8846         (decorateType): updated call to upCast()
8847         * src/SDCCicode.c (geniCodeLeftShift): removed call to
8848         usualUnaryConversions()
8849
8850 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
8851
8852         * support/regression/tests/literalop.c (mulWrapper): Added a
8853         wrapper to remove integer overflow warnings.
8854
8855         * support/regression/tests/float_trans.c: Made work on host.
8856
8857         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
8858         location of sz80.
8859
8860         * support/regression/generate-cases.py (main): Changed from inline
8861         to a main method.
8862
8863         * doc/Makefile (install): Changed to depth first to get rid of
8864         missing directory install warning.
8865
8866         * as/Makefile (install-doc): Made work on Mac.
8867
8868 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
8869
8870         * src/SDCCast.c: added an additional type flow in decorateType() of
8871         opposite direction, see feature request #860006; it's enabled at runtime
8872         by setting the environment variable SDCC_NEWTYPEFLOW
8873         * src/SDCCast.h: changed prototype of decorateType()
8874         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
8875         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
8876         'char' to 'int' can be omitted, if both operands are 'unsigned char';
8877         see feature request #877103
8878         * src/SDCCval.c: updated call of decorateType()
8879         (valBitwise): fixed bug #882876
8880         (valMinus): added promotion
8881         (valLogicAndOr): result is unsigned
8882         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
8883         * src/SDCCsymt.c (computeType),
8884         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
8885         must not cause an unsigned operation
8886         * src/pic/glue (pic14emitRegularMap),
8887         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
8888
8889 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
8890
8891         * src/pic/pcode.c (PCodeID): commented out left over debug code
8892
8893 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
8894
8895         * support/valdiag/tests/overflow.c: added shift tests
8896         * src/pic/device.c,
8897         * src/pic/gen.c,
8898         * src/pic/gen.h,
8899         * src/pic/glue.c,
8900         * src/pic/main.c,
8901         * src/pic/pcode.c,
8902         * src/pic/pcode.h,
8903         * src/pic/pcodepeep.c,
8904         * src/pic/pcoderegs.c,
8905         * src/pic/ralloc.c,
8906         * src/pic/ralloc.h: applied patch from Slade Rich;
8907         added support for multiple code pages and multiple RAM banks on the
8908         PIC 14 port. The ASM files now no longer simply assume all the
8909         code / RAM are in the same page / bank. This means the linker can
8910         safely allocate code/RAM of separate ASM files to different pages/banks.
8911         * doc/sdccman.lyx: added Slade's tips
8912         * src/mcs51/peeph.def: fixed bug #880768
8913
8914 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8915
8916         * src/hc08/ralloc.c (rematStr): fixed bug #879282
8917         * src/SDCCast.c (decorateType): fixed bug #880197
8918
8919 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
8920
8921         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
8922         getopt.h.
8923
8924         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
8925         strtof is not part of C89 and isn't included with Mac OS X.
8926
8927 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8928
8929         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
8930         shiftL2Left2Result): fixed bug #879326
8931         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
8932         (genMultOneByte): fixed bug in signed vs unsigned multiplication
8933         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
8934         address fetch for clr instruction
8935         * device/lib/hc08/_mulint.c: created optimized assembly version
8936         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
8937
8938 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
8939
8940         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
8941         proposed in FR #877103
8942
8943 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
8944
8945         * src/SDCCval.c (cheapestVal): added missing checks
8946         * src/SDCCicode.c (usualBinaryConversions): fixed condition
8947         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
8948
8949 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
8950
8951         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
8952         equal operands
8953
8954 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
8955
8956         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
8957         loaded with the linker search paths (-L arguments) and the libraries
8958         to be linked with the current source (-l arguments). Changes
8959         currently will affect only the pic16 port.
8960         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
8961         include path the port specific paths and port specific libraries,
8962         * gplink command now contains the $3 argument,
8963         * src/pic16/device.h,
8964         * src/pic16/device.c,: structure PIC_device is made public and
8965         renamed to PIC16_device, the same for variable Pics which is renamed
8966         to Pics16. Updated all references to them.
8967         * src/pic16/glue.c (pic16glue): corrected bug with code
8968         initialization which bypassed the variable initializations block.
8969
8970         * device/lib/pic16/Makefile.rules: removed --penable-stack from
8971         COMPILE_FLAGS and added the --nostdinc option
8972
8973 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8974
8975         * device/include/mc68hc908jb8.h: Register defs for another member
8976         of the hc08 family. Contributed by Bjorn Bringert - thanks!
8977
8978 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
8979
8980         Documenting changes from previous commits.
8981         * configure.in (version 1.56),
8982         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
8983         when generating output files to configure the pic16 library,
8984         but now I've commented it out, since gputils aren't installed in the
8985         SF compile farm, so library won't compile
8986
8987         * device/lib/Makefile.in (version 1.56): initially I've added in
8988         target 'all' the prerequestive 'model-pic16' so it compiled the
8989         pic16 library, but now I've commented it out for the same reasons
8990         above,
8991         * added targets 'model-pic16' and 'objects-pic16' to compile the
8992         library
8993         * added target 'port-specific-objects-pic16' to handle the
8994         generated libraries and copy them into the build/ directory
8995         * added target 'clean-intermediate-pic16' to clean intermediate
8996         files into pic16 directory
8997         * in target 'installdirs' added line to create directory pic16 in
8998         the installation path
8999
9000         * device/include/Makefile.in (version 1.11): in target 'install'
9001         added lines to copy all header files to installation path,
9002         * in target 'installdirs' added line create directory for pic16
9003         headers in the installation path
9004
9005 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
9006
9007         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
9008          a function call
9009
9010 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
9011
9012         * configure,
9013         * device/lib/configure.in,
9014         * device/lib/configure: fixed for autoconf 2.57
9015
9016 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9017
9018         * src/z80/main.c (_parseOptions): fixed the portmode= command line
9019         option so that it actually works. Made it specific to the z80, since
9020         the gbz80 doesn't have these kinds of I/O ports.
9021
9022 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9023
9024         * device/include/z180.h,
9025         * device/lib/_memcpy.c,
9026         * device/lib/_memmove.c,
9027         * device/lib/_mulint.c,
9028         * device/lib/ser_ir.c,
9029         * device/lib/ser_ir_cts_rts.c,
9030         * device/lib/_strcmp.c,
9031         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
9032         * src/z80/main.c (_process_pragma): add support for pragmas bank and
9033         portmode; added deprecation warning for bank= and protmode= forms.
9034         Also, guard against buffer overflow.
9035         * src/z80/gen.c (aopGet): generate better code for sfr banked read
9036
9037 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9038
9039         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
9040         changed interrupt vector table generation to only emit declared vectors.
9041         * device/include/Makefile.in: added missing backslash
9042         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
9043
9044 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
9045
9046         Mainly changes to support compilation of the device libraries
9047         * src/pic16/device.c: stack is allocated via symbol and not
9048         via literal number. The symbol is placed in the corresponding
9049         position of the data ram
9050         * (pic16_dump_section): relocatable and absolute uninitialized
9051         data are now emitted in sorted order to reduce section naming,
9052         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
9053         weren't marked as being in the access bank,
9054
9055 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
9056
9057         Added portion of GNU PIC Library under the directory
9058         device/include/pic16 and device/lib/pic16. These files
9059         contain the declarations of SFRs for the PIC18Fxx2 devices.
9060         The directory is initialized via configure from toplevel.
9061
9062 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
9063
9064         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
9065         the spilllocations to be compared correctly
9066
9067 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
9068
9069         * src/SDCCast.c (decorateType): fixed bug introduced today
9070
9071 2004-01-12  Borut Razem <borut.razem AT siol.net>
9072
9073         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
9074         doc/sdccman.lyx: upper case pragmas are deprecated
9075
9076 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
9077
9078         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
9079         in simpler and even better code
9080
9081 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
9082
9083         * src/SDCCicode.c (operandOperation): fixed bug #874819
9084         * src/SDCCast.c (decorateType): fixed
9085         char foo (unsigned long ul) { return ul > 0; }
9086
9087 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9088
9089         * doc/sdccman.lyx: Moved and added some sections, small changes
9090         all over. Telling LaTeX to be less strict with word spacing
9091         to better keep the right margin. Changed some notes about
9092         maintainance of the ports in section 3.2.1 - is it OK like this?
9093
9094 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
9095
9096         SDCC source changes:
9097         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
9098         convilong): modified to inform the pic16 port that builtin functions
9099         are external
9100
9101         PIC16 PORT specific changes:
9102         * src/pic16/device.c pic16_dump_equates() added,
9103         processor registers declared internally by the port are emitted in
9104         the translation as equates,
9105         * src/pic16/gen.c: inline code is passed unprocessed to the
9106         translation,
9107         * (pic16_popGetLit2): fnuction modified to take second operand as
9108         pCodeOp pointer and not as literal,
9109         * (popRegFromIdx): prefixed with pic16_,
9110         * (pic16_popCombine2): modified to receive already allocated pCode
9111         operands,
9112         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
9113         * (genFunction): initializes local stack frame and pushes on stack
9114         all the registers used by this function,
9115         * (genEndFunction): restores all registers from stack and restores
9116         stack frame,
9117         * src/pic16/glue.c (pic16emitRegularMap): various changes and
9118         improvements,
9119         * (pic16glue): changed the program startup sequence,
9120         * added new dbName code 'A' for functions placed in absolute section
9121         * src/pic16/main.c: added function attribute _naked,
9122         * added pragma 'code' to place a fnuction at an absolute address,
9123         * added command line arguments --debug-ralloc and --pcode-verbose,
9124         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
9125         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
9126         * (pic16_newpCodeOpLit2): modified to take the second operand as
9127         pCodeOp pointer,
9128         * (pic16_printpBlock): modified to emit each function in a separate
9129         section,
9130         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
9131         UPPER for immediate operands,
9132         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
9133         instruction,
9134         * src/pic16/peeph.def: all peepholes with movff are commented out,
9135         because there is a problem in the pcode peep optimizer,
9136         * src/pic16/ralloc.c: the register allocator can now reuse local
9137         function symbols for another function. This saves register usage.
9138         * src/pic16/ralloc.h: added flag isLocal in structure regs,
9139
9140         Added file src/pic16/NOTES with information about program writing on
9141         the current port version.
9142
9143 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9144
9145         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
9146         and peephole 252 (array access)
9147
9148 2004-01-09  Borut Razem <borut.razem AT siol.net>
9149
9150         * src/SDCCmain.c : fixed #872250: -l command line defined library
9151           files are scanned before standard library files
9152
9153 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9154
9155         * src/SDCCast.c (decorateType): fixed bug #874046
9156
9157 2004-01-09  Borut Razem <borut.razem AT siol.net>
9158
9159         * support/scripts/sdcc.nsi: remove previous installation
9160
9161 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9162
9163         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
9164         bytes for last interrupt vector (mcs51)
9165         * sdcc.spec: fixed typo
9166
9167 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9168
9169         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
9170         gen51Code): more efficient parameter receive for --model-large
9171         ("bug" #845294)
9172
9173 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9174
9175         * src/ds390/main.c,
9176         * src/z80/main.c: added missed needLinkerScript flags (more than
9177         one port structure defined in these file)
9178         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
9179         bug #795325
9180
9181 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
9182
9183         * src/SDCCmain.c: removed various references to DEFAULT_PORT
9184         * src/port.h: added flag needLinkerScript in port->linker
9185         structure to inform whether to create a .lnk file or not,
9186         * src/avr/main.c,
9187         * src/ds390/main.c,
9188         * src/hc08/main.c,
9189         * src/mcs51/main.c,
9190         * src/pic/main.c,
9191         * src/pic16/main.c,
9192         * src/xa51/main.c,
9193         * src/z80/main.c: changed appropriately to configure
9194         needLinkerScript flag
9195         * src/pic/gen.c,
9196         * src/pic16/gen.c (genAddrOf): fixed bug #863624
9197         * src/pic/glue.c: added variable udata_section_name to
9198         override default uninitialized data segment definition for
9199         devices only with SHAREBANK memory (reported from Erik Epetrich)
9200         * (pic14emitOverlay): modified to emit a commented overlay segment
9201         directive when no overlay data exist
9202         * (picglue): modified to emit uninitialized data segment
9203         according to udata_section_name
9204         * src/pic/main.c (_pic14_parseOptions): added command line
9205         options --udata-section-name=[name] to override default
9206         udata definition name
9207         * modified _linkCmd and _asmCmd to include compiler passed
9208         arguments via -W option
9209         * src/pic16/main.c: added $l in _asmCmd, changed extension for
9210         object file from '.rel' to '.o' in port->linker structure,
9211         changed size of fptr from 2 to 3 in port structure
9212
9213 2004-01-07  Borut Razem <borut.razem AT siol.net>
9214
9215         * support/scripts/sdcc.nsi: update PATH
9216         * support/scripts/sdcc.ico: craeted
9217
9218 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
9219
9220         * device/include/Makefile.in: fix install
9221         * doc/Makefile: fix install
9222
9223 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9224
9225         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
9226         in bug #860505
9227         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
9228         how the function variable allocation summary is displayed; also
9229         include information about variables allocated to the overlay
9230         segment
9231
9232 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9233
9234         * as/mcs51/lkmain.c: Help about -Y option
9235         * as/mcs51/lkarea.c: Fixed gcc warnings
9236
9237 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
9238
9239         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
9240         fixed warning
9241         * support/valdiag/tests/overflow.c: added
9242         * src/SDCCast.c (decorateType),
9243         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
9244         LEFT_OP (left shift)
9245
9246 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9247
9248         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
9249         (default behaviour).
9250
9251 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9252
9253         A python script to validate compiler diagnostic messages. It can be
9254         used to verify that sdcc complains about bad c source code and
9255         gives a good location of the error.
9256         * support/valdiag/Makefile,
9257         * support/valdiag/valdiag.py,
9258         * support/valdiag/tests/*
9259
9260 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9261
9262         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
9263         * src/SDCCsymt.c (newEnumType),
9264         * src/SDCCsymt.h
9265         * support/Util/SDCCerr.c,
9266         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
9267         enum related bugs.
9268         * support/regression/tests/enum.c: added test for enum values that
9269         require at least 2 bytes of storage.
9270
9271 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
9272
9273         * src/common.h: added ifndef/define/endif macros
9274         around the header file.
9275         Bug reported from Jesus Calvino-Fraga
9276
9277 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
9278
9279         * sdcc.spec: updated
9280         * device/include/Makefile.in: don't install CVS directories
9281         * device/lib/Makefile.in: added removal of CVS directories after install
9282         * doc/Makefile: fixed install, added local_icons
9283         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
9284         * src/mcs51/gen.c (genRightShift): fixed bug #870788
9285         * src/ds390/gen.c (genRightShift): fixed bug #870788
9286         * src/SDCCast.c (decorateType): fixed bug #870781
9287
9288 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
9289
9290         PIC16 port related changes:
9291         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
9292         added variable stackPos,
9293
9294         * gen.c: genCall, assignResultValue: added support for
9295         pushing/retrieving function parameters to/from stack,
9296         genFunction,genEndFunction: setup stack frame for the
9297         generated function,
9298         genAddrOf: will be changed according to bug 863624
9299
9300         * added files genutils.c and genutils.h which contain gen*
9301         debugged and optimised functions extracted from gen.c
9302
9303         * glue.c: added variable 'externs' which holds extern symbols,
9304         pic16emitRegularMap: is modified to properly handle relocatable
9305          symbols under the new scheme,
9306         pic16createInterruptVect: is modified
9307         pic16printPublics: is modified to emit 'global' assembler directives,
9308         added pic16_printExterns to print extern symbols,
9309         pic16glue: initializes stack/frame pointer in the beginning of
9310         the assembly output. Temporary hack, will be corrected later,
9311         because gplink yet does not support stack and SDCC does not
9312         yet support a type of crt0.o object to create the final binary.
9313
9314         * Removed many lines that contain 8051 legacy code.
9315         * The code is finally placed under a 'code' directive.
9316         * Added port specific options.
9317
9318         * _process_pragma: simplified since now we do not need *special*
9319         include file to define SFR registers. But a separate header
9320         will be needed. This will be developed later.
9321         * _pic16_parseOptions: added, parses port specific options:
9322         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
9323         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
9324         --preplace-udata-with=
9325
9326         * _pic16_setDefaultOptions: modified to initialize section names,
9327         but hack is temporarly out of order since it needs improvement.
9328         * _pic16_genAssemblerPreamble: configuration words are emitted by
9329         their address instead of their name. This part is incomplete and
9330         supports only the 18Fxx2 devices. Other devices will emit an error
9331         during assembly since they do not contain the same set of config
9332         registers
9333         * _pic16_genIVT: is modified,
9334
9335         * pcode.c: added definitions for some hardware registers that are needed
9336         for stack support
9337         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
9338         All PCI entries are updated. Now LFSR is supported.
9339         * Removed pic16_pciTRIS is mentioned by mdubuc in source
9340         * added pic16_newpCodeOpLit2 to support instructions with
9341         two literal arguments
9342         * pic16_pCode2str: corrected code that emits assembler instructions
9343         with two literal operands and those that have an access bit modifier
9344         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
9345         this fixes a bug which caused some labels to be lost, when an
9346         assembler directive was added, i.e. banksel,
9347         * pic16_FixRegisterBanking: improved logic that causes the insertion
9348         of bank switching,
9349         * InlineFunction: functions that are called once, are not any more
9350         inlined. This can be a port option in the future,
9351
9352         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
9353
9354         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
9355         hold the corresponding uninitialized symbols,
9356         * pic16_allocProcessorRegister: registers have explicit marked the
9357         accessBank field,
9358         * pic16_allocInternalRegister: registers are explicit marked as
9359         not used,
9360         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
9361         processing list, so bit registers were lost,
9362         *
9363
9364         * ralloc.h: added field 'accessBank' and original symbol operand
9365         in register definition,
9366         * removed the field isMapped from register definition,
9367
9368         ** Several functions have been removed from various sources:
9369         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
9370         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
9371         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
9372         pic16_assignRelocatableRegisters
9373
9374         ** others have been introduced:
9375         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
9376         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
9377
9378 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
9379
9380         * support/scripts/inc2h.pl: changed definition of BIT_AT
9381         to emit 'sbit at' instead of 'bit at'. This was a request.
9382
9383         PIC16 port related preliminary changes:
9384         * gen.c: prefixed function popRegFromString with
9385         pic16_ and all references to it corrected
9386         * pcode.c: all pic16_pc_* hardware registers prefixed
9387         with underscore (_),
9388         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
9389         * ralloc.c: newReg(): when register is REG_SFR then
9390         set address to rIdx,
9391         pic16_allocProcessorRegister(): marks register wasUsed=0
9392         pic16_writeUsedRegs(): added a call to assign processor
9393         registers via pic16_assignFixedRegisters
9394
9395 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9396
9397         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
9398         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
9399         variables in unused register banks.  Also the SSEG is placed
9400         wherever there is enough space for it, and IDATA can be anywhere
9401         in internal RAM.  For now compile using -Wl-Y[stack_size].
9402         The mem file is different for this option as well, since it
9403         makes no sense of talking about DSEG lenght.
9404
9405 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
9406
9407         * src/SDCClrange.c: fixed bug 869095 that caused segfault
9408         in certain cases, e.g. when ROM assignment, patch provided
9409         from Albert den Haan.
9410
9411 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
9412
9413         Many signedness and type propagation fixes:
9414         * src/SDCCicode.c: made geniCodeCast() static
9415         replaced SPEC_ by IS_ (cosmetic)
9416         (operandOperation): fixed div and mod operation
9417         (usualBinaryConversions): added support for promotion of char
9418         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
9419         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
9420         (geniCodeAdd): an array index will stay unsigned, even if promoted
9421         from char to int
9422         (geniCodeArray): ditto
9423         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
9424         * src/SDCCsymt.c (computeType): added more support for char;
9425         promotion of char is selectable by promoteCharToInt, fixed signedness
9426         for all cases
9427         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
9428         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
9429         * src/SDCCval (val*): replaced signedness calculation by
9430         computeType()
9431         rearranged if-branches (cosmetic)
9432         (valShift): added warning W_SHIFT_CHANGED
9433         (valCompare): fixed problem with different types
9434         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
9435         * support/regression/tests/literalop.c: added many cases
9436         * support/regression/tests/ast_constant_folding.c: changed finally to
9437         'unsigned int'
9438         * .version: new year, new version: 2.3.7
9439         * src/SDCCmain.c (main): applied patch #866468
9440         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
9441         provided by Scott Bronson
9442         * doc/sdccman.lyx: updated documentation for sdcdb
9443         updated and added chapter tips
9444
9445 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9446
9447         * src/SDCCsymt.h: missing from yesterday's commits
9448
9449 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9450
9451         * src/SDCC.y (struct_or_union_specifier),
9452         * support/Util/SDCCerr.c,
9453         * support/Util/SDCCerr.h: verify that struct & union tags are used
9454         as declared.
9455
9456 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9457
9458         * src/SDCCglobl.h: missing from yesterday's commits
9459
9460 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9461
9462         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
9463         sft_attributes, struct_declaration, parameter_declaration,
9464         type_name, start_block, declaration_list),
9465         * src/SDCC.lex (check_type): support redefinition of typedef names
9466
9467 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9468
9469         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
9470         aligned xdata arrays. Erik helped me with the if clause.
9471
9472 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9473
9474         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
9475         warning
9476
9477 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9478
9479         * src/SDCCast.h,
9480         * src/SDCCast.c (newAst_),
9481         * src/SDCCicode.h,
9482         * src/SDCCicode.c (ast2iCode, newiCode),
9483         * src/SDCCglobl.h,
9484         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
9485         expr, statement, expression_statement, selection_statement,
9486         iteration_statement, expr_opt, jump_statement): foundation for tracking
9487         sequence points
9488         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
9489         point code too)
9490
9491 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9492
9493         * support/Util/SDCCerr.c,
9494         * src/SDCCast.h,
9495         * src/SDCCast.c (createCase, createDefault, decorateType),
9496         * src/SDCClabel.c (labelUnreach),
9497         * src/SDCC.y (labeled_statement, jump_statement): More improvements
9498         to error messages.
9499         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
9500         (with thanks to Stas Sergeev)
9501         * device/include/time.h,
9502         * device/lib/time.c (CheckTime): suppress unreachable code warning
9503
9504 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9505
9506         * src/SDCCast.c (createIvalCharPtr),
9507         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
9508         bug #753752)
9509         * support/regression/tests/nullstring.c: tests for these two bugs
9510
9511 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9512
9513         * support/Util/SDCCerr.h,
9514         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
9515         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
9516         about storage class and 'at' used inside struct or union
9517         * src/SDCCBBlock.c (iCodeFromeBBlock),
9518         * src/SDCCcse.c (ifxOptimize),
9519         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
9520         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
9521         printIval, emitStaticSeg, emitOverlay),
9522         * src/SDCClabel.c (deleteIfx),
9523         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
9524         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
9525         gatherAutoInit, processParms),
9526         * support/Util/SDCCerr.h,
9527         * support/Util/SDCCerr.c (werrorfl): Support for better error location
9528         reporting for post-parse errors.
9529
9530 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9531
9532         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
9533         implicit casts via union; they don't work on big endian systems
9534         (possible fix for bug #861138)
9535
9536 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9537
9538         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
9539         * src/mcs51/main.c: fixed the fix for bug #737001
9540
9541 2003-12-15  Borut Razem <borut.razem AT siol.net>
9542
9543         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
9544
9545 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9546
9547         * support/makebin/makebin.c: put output in binary mode
9548
9549 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9550
9551         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
9552         xdata and data memory on startup. Set the environment variable
9553         SDCC_NOGENRAMCLEAR to disable this.
9554         * src/mcs51/peephole.def,
9555         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
9556         (allows non-interrupt and interrupt code to safely compete for a resource
9557         without the non-interrupt code having to disable interrupts)
9558
9559 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9560
9561         * src/SDCCicode.c (geniCodeAdd),
9562         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
9563         with valFromType if type might be a pointer and host is big endian).
9564         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
9565         types, not just integer types.
9566         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
9567         multiply defined with mismatching "at" address.
9568
9569 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9570
9571         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
9572         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
9573         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
9574         with embedded nulls (fixed bug #753752)
9575
9576 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9577
9578         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
9579         Apparently this did not see much testing (endless loop)
9580
9581 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9582
9583         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
9584
9585 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9586
9587         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
9588         gracefully handle NULL memmap pointers
9589
9590 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9591
9592         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
9593         instead of deleting the iCode when an operand is volatile
9594         * src/z80/gen.c (genDummyRead),
9595         * src/mcs51/gen.c (genDummyRead),
9596         * src/ds390/gen.c (genDummyRead),
9597         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
9598         not just IC_RIGHT
9599         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
9600         * src/SDCC.y: fixed bug #850420
9601
9602 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9603
9604         Applied z80 i/o port patch from Peter Townson and fixed some operators
9605         to better handle operands in A register.
9606         * device/include/z180.h
9607         * src/SDCC.y
9608         * src/SDCCglue.c
9609         * src/z80/gen.c
9610         * src/z80/gen.h
9611         * src/z80/main.c
9612         * src/z80/peeph-z80.def
9613         * src/z80/peeph.def
9614         * src/z80/z80.h
9615
9616 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9617
9618         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
9619
9620 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9621
9622         * device/lib/hc08/_mullong.c: Removed extra #endif
9623
9624 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9625
9626         * sim/ucsim/hc08.src/inst.cc,
9627         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
9628         carries from x to h
9629         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
9630         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
9631         * device/include/stdarg.h: fixed varargs for hc08
9632         * device/lib/Makefile.in,
9633         * device/lib/hc08/Makefile,
9634         * device/lib/hc08/_mulint.c,
9635         * device/lib/hc08/_mullong.c: fixed some endian problems
9636
9637 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9638
9639         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
9640         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
9641         * device/lib/_gptrget.c,
9642         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
9643
9644 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9645
9646         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
9647         * src/SDCCast.c (astErrors): fixed bug #846007
9648         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
9649
9650 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9651
9652         * src/SDCCast.c (decorateType): disabled a transformation I added in
9653         revision 1.188 (access to fields of a structure at an absolute address);
9654         it breaks with bitfields, extern declarations, and gcse analysis.
9655         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
9656         could be assigned through a pointer, so don't complain.
9657         * src/SDCCast.c (astErrors),
9658         * src/SDCCast.h,
9659         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
9660
9661 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
9662
9663         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
9664         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
9665         output of __config directives, since gpasm now supports them
9666         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
9667         pre-processor macro, i.e. -DMCU=p18f452
9668         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
9669         and modified to handle 'cast' icode similarly to '=' icode
9670         * src/pic16/device.h (typedef struct PIC_device): added field
9671         'extMIface' to indicate that chip has external memory interface
9672         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
9673         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
9674         18F8720
9675
9676 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9677
9678         * src/SDCC.y (pointer): fixed bug #846006
9679         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
9680         * src/SDCCast.c (decorateType): fixed bug #846009
9681         * src/ds390/peeph.def,
9682         * src/ds390/gen.c (genAnd, genOr),
9683         * src/mcs51/peeph.def,
9684         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
9685
9686 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9687
9688         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
9689         * src/SDCCdflow.c
9690         * src/SDCCcse.c
9691         * src/SDCCcse.h
9692         * src/SDCCBBlock.h
9693         * src/SDCCBBlock.c
9694
9695 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
9696
9697         fixed bug #845089
9698         * src/SDCCbitv.h,
9699         * src/SDCCbitv.c: added function to free a bitvector
9700         * src/SDCClrange.h,
9701         * src/SDCClrange.c: added function to recompute the liveranges
9702         * src/avr/ralloc.c,
9703         * src/ds390/ralloc.c,
9704         * src/hc08/ralloc.c,
9705         * src/mcs51/ralloc.c,
9706         * src/pic/ralloc.c,
9707         * src/pic16/ralloc.c,
9708         * src/xa51/ralloc.c,
9709         * src/z80/ralloc.c: recompute the liveranges after register packing
9710
9711 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
9712
9713         * src/SDCCloop.c (newInduction): fixed bug #845630
9714
9715 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9716
9717         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
9718         inadvertantly left behind from my 2003-11-12 change
9719
9720 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9721
9722         Updated headers I neglected to commit yesterday.
9723         * src/SDCClrange.h,
9724         * src/SDCCicode.h
9725
9726 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9727
9728         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
9729         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
9730         * src/SDCCopt.c (eBBlockFromiCode),
9731         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
9732         the creation of the key hash table from the sequencing so it can be used
9733         earlier (for some GCSE bug fixes still pending)
9734
9735 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9736
9737         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
9738         * support/regression/tests/addsub.c: testing genPlus shortcut
9739
9740 2003-11-15  Borut Razem <borut.razem AT siol.net>
9741
9742         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
9743
9744 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9745
9746         * src/SDCCcse.c (cseBBlock): fixed bug #527779
9747         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
9748         ordering is immaterial.
9749         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
9750
9751 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9752
9753         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
9754         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
9755         (SIGSEV) of bug #840381
9756         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
9757         unlink new file before rename if new and old filenames are the same)
9758
9759 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9760
9761         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
9762         uninitialized variables) for the mcs51. Set environment variable
9763         SDCC_GENRAMCLEAR to test.
9764         xdata initialization slightly shorter
9765
9766 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9767
9768         * src/SDCCsymt.h,
9769         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
9770         #838241 & 780691 (basicly the same bug)
9771         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
9772         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
9773
9774 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
9775
9776         * src/SDCCmain.c (linkEdit): "fix" #834252
9777
9778 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9779
9780         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
9781         * src/SDCCast.h,
9782         * src/SDCC.y: fixed bug #819403
9783
9784 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9785
9786         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
9787         the reentrant attribute.
9788         * src/hc08/gen.c (genPackBits): added missing stack readjustment
9789         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
9790         simulation
9791         * src/SDCCast.c (decorateType): fixed bug with storage class not being
9792         updated during pointer dereference; f.e. ~(((char *)1)*) was being
9793         erroneously reduced to a literal.
9794         * src/hc08/ralloc.c (packRegisters, rematStr),
9795         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
9796         some cases
9797
9798 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9799
9800         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
9801         * doc/sdccman.lyx: changed from 'article' to 'book'
9802         * doc/Makefile: readded test_suite_spec and cdbfileformat
9803
9804 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
9805
9806         * device/include/stdlib.h: include malloc.h to comply with ANSI
9807         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
9808
9809 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9810
9811         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
9812         * doc/clean.mk: also remove *.out files
9813         * doc/sdccman.lyx: some additions, larger top/bottom margins
9814
9815 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9816
9817         * src/SDCC.y: fixed bug #837365
9818         * support/regression/tests/bitopcse.c
9819         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
9820         a symbol (might be valop instead)
9821         * device/lib/Makefile.in: added errno.c to HC08SOURCES
9822         * device/lib/clean.mk: added hc08 to the cleaning list
9823
9824 2003-11-04  Borut Razem <borut.razem AT siol.net>
9825
9826         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
9827           made 2003-11-04
9828         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
9829           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
9830           malloc is declared in standard stdlib.h
9831
9832 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9833
9834         * device/lib/hc08/Makefile: need to clean .rel not .o files
9835         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
9836
9837 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9838
9839         * src/port.h,
9840         * src/hc08/main.c,
9841         * src/mcs51/main.c,
9842         * src/ds390/main.c,
9843         * src/z80/main.c,
9844         * src/avr/main.c,
9845         * src/pic/main.c,
9846         * src/pic16/main.c,
9847         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
9848         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
9849         tests (which uses the port's oclsExpense function)
9850         * src/SDCC.y,
9851         * src/SDCCast.c,
9852         * src/SDCCicode.c,
9853         * src/hc08/gen.c,
9854         * src/ds390/gen.c,
9855         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
9856
9857 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9858
9859         * src/SDCCcse.c (ifxOptimize),
9860         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
9861         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
9862         deleting the IFX iCode.
9863         * src/hc08/ralloc.c: reduced unneeded slocs
9864         * src/hc08/gen.c: fixed bug in asmopToBoolean
9865
9866 2003-11-04  Borut Razem <borut.razem AT siol.net>
9867
9868         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
9869           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
9870           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
9871           transferred to configure
9872
9873 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
9874
9875         Use headers defined in the C[++] standards:
9876         * sim/ucsim/gui.src/serio.src/fileio.cc
9877         * sim/ucsim/gui.src/serio.src/frontend.cc
9878         * sim/ucsim/gui.src/serio.src/main.cc
9879         * sim/ucsim/gui.src/serio.src/posix_signal.cc
9880         * support/Util/NewAlloc.c
9881         * as/hc08/lklibr.c
9882         * as/mcs51/lklibr.c
9883         * as/z80/aslist.c
9884         * as/z80/assym.c
9885
9886 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9887
9888         * Added MSVC projects for hc08 assembler and linker:
9889         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
9890         /as/hc08/link_hc08.dsp
9891
9892 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
9893
9894         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
9895
9896 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
9897
9898         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
9899
9900 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9901
9902         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
9903
9904 2003-10-31  Borut Razem <borut.razem AT siol.net>
9905
9906         * support/cpp2/cpplib.h,
9907           support/cpp2/cpplib.c,
9908           support/cpp2/cpplex.c,
9909           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
9910           to switch _asm block preprocessing on / off. Default is
9911           #pragma preproc_asm +
9912
9913 2003-10-31  Borut Razem <borut.razem AT siol.net>
9914
9915         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
9916           when outputting comment blocks (when executed with -C option) and
9917           _asm (SDCPP specific) blocks
9918
9919 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9920
9921         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
9922
9923 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
9924
9925         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
9926
9927 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
9928
9929         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
9930         * src/SDCCast.c (decorateType): fixed bug #832664
9931
9932 2003-10-31  Borut Razem <borut.razem AT siol.net>
9933
9934         * support/cpp2/cpplex.c: fixed for SDCPP:
9935           comments(when executed with -C option) and _asm blocks
9936           were included even if they where in skipped #if block.
9937           Applied solution from GCC cpp 3.3.2
9938
9939 2003-10-31  Borut Razem <borut.razem AT siol.net>
9940
9941         * src/SDCC.lex: sdcc now understands both formats:
9942           '# <line_number> <file_name>' and
9943           '#line <line_number> <file_name>'
9944         * support/cpp2/cppmain.c: sdcpp now generates the standard
9945           '# <line_number> <file_name>' instead of former
9946           '#line <line_number> <file_name>'
9947
9948 2003-10-30  Borut Razem <borut.razem AT siol.net>
9949
9950         * support/cpp2/cpphash.h,
9951         * support/cpp2/cpplib.h
9952         * support/cpp2/cpplex.c,
9953         * support/cpp2/cppmain.c,
9954         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
9955
9956 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9957
9958         Fixed a number of problems revealed by bug #827883.
9959         * src/SDCCloop.c (loopInvariants): Spill location of the
9960         result operand should be recomputed if extracted from
9961         a loop. Also, don't extract assignments of an iTemp
9962         from a literal.
9963         * src/SDCCast.c (isConformingBody): loop reversal should
9964         not occur if the control variable is involved with a
9965         relational operator.
9966
9967 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
9968
9969         * .version: bumped to 2.3.6 to reflect the big improvements
9970         made by Erik and Klaus. Thanks!
9971
9972 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
9973
9974         Replaced the livrange code.
9975         * src/SDCClrange.c: added new LR code
9976         * src/SDCCloop.c,
9977         * src/SDCCBBlock.h: removed remainig parts from old LR code
9978         * src/ds390/ralloc.c,
9979         * src/ds390/gen.c: minor fixes to make it work with new code
9980
9981 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9982
9983         * as/hc08/asm.h,
9984         * as/hc08/lkrloc.c,
9985         * src/hc08/gen.c,
9986         * src/hc08/ralloc.c: Fix various warnings related to the hc08
9987         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
9988         (tweaked fix for bug #818696)
9989
9990 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9991
9992         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
9993
9994 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9995
9996         * src/SDCCmain.c,
9997         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
9998         * src/mcs51/gen.c (gencjneshort),
9999         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
10000         more efficient (per Scott Bronson's suggestion)
10001
10002 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10003
10004         Extended the semantics of the critical keyword to include
10005         individual statements. See RFE #827755 and #799831
10006         * src/SDCC.y
10007         * src/SDCCicode.c
10008         * src/SDCCopt.c
10009         * src/SDCCast.c
10010         * support/Util/SDCCerr.c
10011         * support/Util/SDCCerr.h
10012         * src/mcs51/gen.c
10013         * src/ds390/gen.c
10014         * src/hc08/gen.c
10015
10016 2003-10-19  Borut Razem <borut.razem AT siol.net>
10017
10018         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
10019
10020 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10021
10022         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
10023         Fixed bug #818696
10024         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
10025         and predecrement operand is displayed
10026
10027 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
10028
10029         * src/SDCCval.c (valMinus): fixed bug #826041
10030
10031 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10032
10033         Some hc08 related updates that I missed earlier
10034         * sim/ucsim/stypes.h
10035         * support/regression/ports/hc08/spec.mk
10036
10037 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10038
10039         New target "hc08" for the Motorola 68hc08 family of micros
10040
10041         * configure
10042         * configure.in
10043         * Makefile
10044         * src/hc08/*
10045         * src/SDCCmain.c
10046         * src/port.h
10047         * sim/ucsim/hc08.src/*
10048         * sim/ucsim/configure.in
10049         * src/ucsim/configure
10050         * sim/ucsim/packages_in.mk
10051         * as/hc08/*
10052         * as/Makefile
10053         * device/include/mc68hc908qy.h
10054         * device/lib/hc08/*
10055         * device/lib/Makefile.in
10056         * support/regression/ports/hc08/*
10057         * support/regression/Makefile
10058
10059 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10060
10061         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
10062         regression test
10063         * src/ds390/gen.c (genCast): fixed bug #821957
10064
10065 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
10066
10067         * device/lib/logf.c: "fixed" overlay bug
10068         * support/regression/ports/host/spec.mk: added m library
10069         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
10070         * support/regression/tests/float_trans: added (for Eric)
10071
10072 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
10073
10074         * src/mcs51/gen.c (genCpl): fixed bug
10075         http://sf.net/mailarchive/message.php?msg_id=6263915
10076
10077 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
10078
10079         * src/SDCCast.c (decorateType): added extended constant folding
10080         * src/SDCCsymt.c (computeType): cleanup
10081         * src/SDCCval.c (valShift): minor optimization
10082         * support/regression/tests/ast_constant_folding.c: added
10083
10084 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10085
10086         * src/SDCCmain.c: removed some unintended changes
10087
10088 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10089
10090         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
10091         * src/z80/gen.c: fixed part of bug #817589
10092         * src/SDCCsymt.c (checkFunction): fixed bug #817895
10093
10094 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
10095
10096         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
10097         * src/SDCCcflow.c
10098         * src/SDCCcse.c
10099         * src/SDCCdflow.c
10100         * src/SDCClabel.c
10101         * src/SDCClrange.c
10102         * src/SDCCmem.c
10103         * src/SDCCopt.c
10104         * src/SDCCpeeph.c
10105         * src/SDCCset.c
10106         * src/avr/ralloc.c
10107         * src/ds390/ralloc.c
10108         * src/izt/ralloc.c
10109         * src/mcs51/ralloc.c
10110         * src/pic/ralloc.c
10111         * src/pic16/ralloc.c
10112         * src/xa51/ralloc.c
10113         * src/z80/ralloc.c
10114         * src/z80/gen.c: removed unused label "release:"
10115
10116 2003-10-06  Borut Razem <borut.razem AT siol.net>
10117
10118         * src/SDCC.lex: removed definition of unused variables
10119           save_optimize and save_options
10120
10121 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
10122
10123         * clean.mk: removed '=' in "-maxdepth=1"
10124         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
10125         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
10126
10127 2003-10-06  Borut Razem <borut.razem AT siol.net>
10128
10129         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
10130           my_unput() replaced by unput()
10131
10132 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
10133
10134         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
10135         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
10136         type-punned pointer will break strict-aliasing rules"
10137         Old LR behaviour is again default; Klaus' LR can be choosen by
10138         defining the environment variable LRKLAUS
10139         * src/SDCCBBlock.h
10140         * src/SDCCloop.c
10141         * src/SDCClrange.c
10142         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
10143         * clean.mk: fixed removal of files in bin/CVS/
10144         * device/lib/clean.mk: fixed removal of directories small and large
10145         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
10146         * src/SDCCicode.c,
10147         * src/SDCCval.c: removed superflous test for pedantic
10148
10149 2003-10-05  Borut Razem <borut.razem AT siol.net>
10150
10151         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
10152           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
10153           message "unmatched #pragma SAVE and #pragma RESTORE"
10154
10155 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10156
10157         * doc/sdccman.lyx: various additions and updates (interrupts, inline
10158           assembly, critical functions, atomic, nojtbound)
10159
10160 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
10161
10162         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
10163         * src/SDCCBBlock.h
10164         * src/SDCCloop.c
10165         * src/SDCCloop.h
10166         * src/SDCClrange.c
10167
10168 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10169
10170         * src/z80/gen.h,
10171         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10172         * src/mcs51/gen.h
10173         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10174         * src/ds390/gen.h
10175         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
10176         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
10177         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
10178
10179 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10180
10181         * src/z80/gen.c (genRet): fixed bug #524753
10182         * src/z80/gen.c (genCast): fixed internal error on cast from
10183         pointer to long
10184         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
10185         fix for bug #477835 to the z80
10186         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
10187         for tracking iCodes in the peephole optimizer for z80
10188
10189 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10190
10191         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
10192         the other part of bug #814548
10193         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
10194
10195 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
10196
10197         * src/SDCCcse.c: fixed part of bug #814548
10198
10199 2003-09-28  Borut Razem <borut.razem AT siol.net>
10200
10201         * src/asm.c: rewrite of printILine() to use temporary file instead
10202           a pipe
10203         * src/xa51/main.c: commented out declaration of int rewinds
10204
10205 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10206
10207         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
10208
10209 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10210
10211         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
10212         * src/asm.c (printILine): Fixed bug #811015
10213
10214 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10215
10216         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
10217         freeing.
10218
10219 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10220
10221         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
10222         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
10223         to correctly handle general case of AOP_PAIRPTR
10224         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
10225
10226 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10227
10228         * src/mcs51/ralloc.c (fillGaps),
10229         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
10230         register positioning bug)
10231
10232 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
10233
10234         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
10235
10236 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10237
10238         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
10239         genCodePointerGet, genGenPointerGet, genFarPointerSet,
10240         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
10241         (ralloc doesn't intentionally do this now, but perhaps later)
10242         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
10243         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
10244         register positioning bugs (Fixed bug #762602 and #795325)
10245         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
10246         (Fixed bug #808779)
10247         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
10248         lines that --i-code-in-asm generates
10249
10250 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10251
10252         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
10253         trying to fclose a FILE* that was already closed.
10254
10255 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10256
10257         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
10258         of const struct should be treated as if const themselves)
10259
10260 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
10261
10262         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
10263
10264 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10265
10266         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
10267         Unix (/n) and DOS (/r/n) line terminations.
10268
10269 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10270
10271         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
10272         bug #613775
10273
10274 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10275
10276         * src/mcs51/gen.c (genFunction, genEndFunction),
10277         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
10278         and restore of EA so that stack offsets to parameters are
10279         correct when using both critical and reentrant/stack-auto.
10280         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
10281         size (can be triggered in error if sloc is shared between
10282         different sized objects)
10283         * device/include/float.h: fixed macros to explicitly use
10284         unsigned long where needed
10285
10286 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
10287
10288         Feature req. 799831: added code to allow nesting of critical functions
10289         * src/mcs51/gen.c (genFunction, genEndFunction)
10290         * src/ds390/gen.c (genFunction, genEndFunction)
10291
10292 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10293
10294         * src/SDCCsymt.c (sclsFromPtr),
10295         * src/SDCCsymt.h,
10296         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
10297         support for standard C idiom of memory mapped variables; for
10298         example, *((xdata int*)0x1234) = 1 is now internally equivalent
10299         to xdata int at 0x1234 tempvar = 1.
10300         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
10301         provided by Akiya ISHIDA
10302
10303 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
10304
10305         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
10306         * src/SDCCval.c (constVal): added reduction from int to char
10307         * src/SDCCval.c (valMult, valDiv): fixed sign handling
10308         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
10309         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
10310         to ignore the sign
10311         * support/regression/tests/shifts.c: fixed
10312
10313 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10314
10315         * src/z80/gen.c (genXor): Fixed bug #805445
10316
10317 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10318
10319         Fixed bug #621531 (const & volatile confusion in the type chain).
10320         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
10321         refer to the const or volatile state of the pointer itself.
10322
10323         * src/SDCCast.c
10324         * src/SDCCglue.c
10325         * src/SDCCicode.c
10326         * src/SDCCsymt.c
10327         * src/SDCCval.c
10328         * src/SDCC.y
10329         * src/SDCCsymt.h
10330         * src/pic/gen.c
10331         * src/pic/ralloc.c
10332         * src/pic16/gen.c
10333         * src/pic16/ralloc.c
10334         * support/regression/tests/const.c
10335
10336 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10337
10338         When checking for duplicated modules, use absolute paths
10339         instead of relative paths.  Files changed:
10340
10341         * as/mcs51/lklib.c
10342         * link/z80/lklib.c
10343
10344 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10345
10346         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
10347
10348 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10349
10350         * device/include/string.h: added size_t typedef, changed
10351         prototypes to use size_t, eliminated separate reentrant and
10352         non-reentrant declarations, added _memmove declaration
10353         * device/lib/_memcpy.c: changed to use size_t instead of int,
10354         changed /4 to >>2 to avoid division library call
10355         * device/lib/_memcmp.c,
10356         * device/lib/_memset.c,
10357         * device/lib/_strncat.c,
10358         * device/lib/_strncpy.c,
10359         * device/lib/_strncmp.c: changed to use size_t instead of int
10360         * device/lib/_memmove.c: new file (fixed bug #772294)
10361         * device/lib/Makefile.in: added _memmove.c
10362         * device/lib/z80/asm_strings.s: fixed bug #772290
10363         * support/regression/tests/bitfields.c: attempt to fix host assertion
10364         failure on amd64-unknown-linux2.2
10365
10366 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10367
10368         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
10369         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
10370         * as/z80/asmain.c (main): fixed bug #801766
10371
10372 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
10373
10374         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
10375         compilers
10376
10377 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10378
10379         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
10380         reported in bug #800609
10381
10382 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
10383
10384         * Top header beautifications in src/pic16 directory:
10385           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
10386           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
10387           pcoderegs.h, ralloc.c, ralloc.h
10388         * main.c: added top header and GPL license notice
10389         * pcode.c: fixed the if-conditional warning
10390
10391 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
10392
10393         * device/lib/_mullong.c: replaced int by short for gcc
10394
10395 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10396
10397         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
10398         and JUMPTABLE iCodes properly now (worked by accident before)
10399         * src/mcs51/gen.c (leftRightUseAcc),
10400         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
10401         iCode properly now. Use getSize instead of nRegs since a & b
10402         aren't part of the nRegs tally.
10403
10404 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
10405
10406         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
10407         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
10408           before instructions that use the _STATUS register
10409
10410 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
10411
10412         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
10413         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
10414         fetching of the pointer
10415         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
10416         copied from genNearPointerSet()
10417         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
10418         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
10419         If they pop r0/r1 they must be called in the opposite order than aopOp().
10420         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
10421         (resp. --stack-auto), prepared for --xstack
10422
10423 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10424
10425         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
10426
10427 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10428
10429         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
10430         these ports have their own __sdcc_external_start()
10431
10432 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
10433
10434         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
10435         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
10436         type for bits was changed. It resulted in bit variables becoming
10437         global, which is not permitted in PIC 14 assembly output.
10438
10439 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10440
10441         * doc/sdccman.lyx: various additions and updates. Rearranged sections
10442
10443 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10444
10445         Z80 and MCS51 linkers complaint if a public symbol is defined
10446         in more than one library module:
10447
10448         * as/mcs51/lklib.c
10449         * link/z80/lklib.c
10450         * as/mcs51/Makefile.in
10451
10452 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10453
10454         A few small changes that speed up the peephole optimizer.
10455
10456         * src/SDCCpeeph.c
10457
10458 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10459
10460         Try to make the peephole optimizer smarter by maintaining
10461         an association between the assembly source code and the
10462         iCodes that originated them. Put this information to use
10463         with a new peephole rule condition "notVolatile" so that
10464         the rules can be aggressive yet still safe.
10465
10466         * src/SDCCpeeph.c
10467         * src/SDCCpeeph.h
10468         * src/mcs51/gen.c
10469         * src/mcs51/peeph.def
10470
10471 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10472
10473         Fixed bug #741761
10474
10475         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
10476         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
10477         if the left or right operand symbols have the accuse flag set.
10478
10479 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10480
10481         Changed the type of the result of the ! (NOT) operator to char;
10482         previously it returned the same type as the source. This allows
10483         us to eliminate all the genFloatNot functions (all of its target
10484         implementations were very buggy) since !float can use the same
10485         code as !long now.
10486
10487         * src/SDCCicode.c (ast2iCode): ! returns char
10488         * src/mcs51/gen.c (genNot, genNotFloat),
10489         * src/ds390/gen.c (genNot, genNotFloat),
10490         * src/z80/gen.c (genNot, genNotFloat),
10491         * src/pic/gen.c (genNot, genNotFloat),
10492         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
10493
10494 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
10495
10496         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
10497         1. Interrupt would not compile properly. Ensure PCLATH register is saved
10498            during interrupts. Ensure WSAVE is located at a shared bank address.
10499         2. Fixed page selection in some places
10500         3. Fixed BTFSS/C to where necessary use registers directly and not simply
10501            the registers name strings.
10502         4. Fixed "signed / unsigned compare" compiler warnings.
10503         5. The PIC port manages its own allocation of the general purpose
10504            registers, but makes no attempt to reuse them. As a result when
10505            compiling it soon runs out of general purpose registers. Some
10506            additional code was added to the files pcode.c and device.c to walk
10507            through the function call tree and rename the registers so that they
10508            get reused.
10509
10510         * src/pic/device.c
10511         * src/pic/gen.c
10512         * src/pic/glue.c
10513         * src/pic/pcode.c
10514         * src/pic/pcode.h
10515         * src/pic/ralloc.c
10516         * src/pic/ralloc.h
10517         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
10518         genPlus() & genMinus() when the result is the same as left or right
10519
10520 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10521
10522         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
10523
10524 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10525
10526         Made bitfield a distinct type from bit so that bitfields
10527         convert as per ANSI C and bits retain their traditional
10528         boolean style behaviour. Implemented bitfield support in
10529         the z80 port.
10530
10531         * src/SDCCsymt.h,
10532         * src/SDCCsymt.c,
10533         * src/SDCCast.c,
10534         * src/cdbFile.c,
10535         * src/mcs51/gen.c,
10536         * src/ds390/gen.c: bit v bitfield split
10537         * src/z80/gen.c: New support for bitfields
10538         * support/regression/tests/bitfields.c: reenabled z80,
10539         added more tests
10540
10541 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10542
10543         Rules 246.x, 247.x relate to bitfields, the others speed up
10544         access to xdata mapped I/O devices.
10545
10546         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
10547
10548 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10549
10550         Cleaned up genPackBits and genUnpackBits and added two helper
10551         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
10552         for literal assignments in genPackBits (thanks to Frieder for
10553         reminding me).
10554
10555         * src/mcs51/gen.c
10556         * src/ds390/gen.c
10557
10558 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10559
10560         Fixed bug #748310 (pointer to function type mishandled when the
10561         function name is omitted). Also fixed a SIGSEGV when a function
10562         attribute (reentrant, etc) is used on a non-function or on a
10563         function but misplaced before the parameter list.
10564
10565         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
10566         bug #748310
10567         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
10568         * support/Util/SDCCerr.h,
10569         * support/Util/SDCCerr.c: Added func attr misuse error msg
10570
10571 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
10572
10573         Fixed bug #787649 by anonymous
10574         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
10575         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
10576
10577 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10578
10579         Fixed numerous bitfield problems.
10580
10581         * src/SDCC.y: More bitfield related error checking
10582         * src/SDCCsymt.h,
10583         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
10584         * support/Util/SDCCerr.h,
10585         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
10586         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
10587         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
10588         * support/regression/tests/bitfields.c: tests added
10589
10590 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10591
10592         Made the constant following the "interrupt" keyword optional. If
10593         omitted, the function will not automatically be given an entry
10594         in the interrupt vector table (similar to #pragma NOIV, but
10595         less syntacticly kludgy). The interrupt number is also now
10596         range checked. Also fixed a bug in the high order bit example
10597         in the manual.
10598
10599         * src/SDCC.y
10600         * src/SDCCmem.c
10601         * src/SDCCglue.c
10602         * src/SDCCsymt.h
10603         * support/Util/SDCCerr.c
10604         * support/Util/SDCCerr.h
10605         * doc/sdccman.lyx
10606
10607 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
10608
10609         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
10610         * src/SDCCicode.c (operandOperation): rewritten some ops
10611         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
10612         * src/SDCCsymt.c (computeType): literals are handled the same way as any
10613         other type
10614         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
10615         be re-activated by defining REDUCE_LITERALS)
10616         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
10617         unsigned, but are signed by default
10618         * src/SDCCval.c (constVal): rearranged
10619         * src/SDCCval.c (valMod): preliminary fix
10620         * src/SDCCval.c (valCastLiteral): use TYPE_* types
10621         * support/regression/literalop.c: added, work in progress
10622
10623 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10624
10625         Generate warnings for useless declarations like "char data;"
10626         that don't do what new users expect.
10627
10628         * src/SDCC.y
10629         * support/Util/SDCCerr.h
10630         * support/Util/SDCCerr.c
10631
10632 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
10633
10634         * src/SDCCval.c (valMult): fix overflow detection of negative int
10635
10636 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10637
10638         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
10639
10640         Changes to support big endian targets:
10641
10642         * src/ports.h
10643         * src/SDCCglue.c
10644         * src/avr/main.c
10645         * src/ds390/main.c
10646         * src/izt/i186.c
10647         * src/mcs51/main.c
10648         * src/pic/main.c
10649         * src/pic16/main.c
10650         * src/xa51/main.c
10651         * src/z80/main.c
10652
10653 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
10654
10655         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
10656         * device/lib/time.c: fixed warning "integer overflow in expression"
10657
10658 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
10659
10660         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
10661         * src/SDCCval.c (constVal): changed default to signed; hex and octal
10662         constants are unsigned; added recognition of "u" flag for unsigned
10663         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
10664         * src/SDCCval.c (valDiv, valMod): fixed signdness
10665         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
10666         signedness of modulo, left and right shift
10667         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
10668         * support/Util/SDCCerr.h: added warning W_INT_OVL
10669         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
10670         * src/SDCCast.c (ast_print): improved output of constants
10671
10672 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10673
10674         Fixed some warnings when building with MSVC:
10675
10676         * as/mcs51/asdata.c
10677         * as/z80/asdata.c
10678         * as/mcs51/asm.h
10679         * as/z80/asm.h
10680         * link/z80/aslink.h
10681         * link/z80/lkdata.c
10682         * link/z80/lkeval.c
10683         * link/z80/lkgb.c
10684         * link/z80/lkihx.c
10685         * link/z80/lks19.c
10686         * link/z80/lksym.c
10687         * support/cpp2/cpplib.c
10688         * src/ds390/gen.c
10689         * src/mcs51/gen.c
10690
10691 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
10692
10693         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
10694
10695 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10696
10697         * support/librarian/clean.mk: Do not remove Makefile.
10698         * support/librarian/Makefile: added.
10699
10700 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10701
10702         Added librarian to MSVC build:
10703         * all.dsp
10704         * sdcc.dsw
10705         * support/librarian/librarian.dsp
10706
10707         'configure' not needed for librarian, removed:
10708         * support/librarian/configure
10709         * support/librarian/configure.in
10710         * support/librarian/config_in.h
10711         * support/librarian/Makefile.in
10712
10713         Hopefully these ones built the librarian and the rest of sdcc properly:
10714         * Makefile
10715         * Makefile.common.in
10716
10717         Messed up 'configure', so revert to previous version:
10718         * configure
10719         * configure.in
10720
10721 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
10722
10723         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
10724         there, while the mantissa of a double is "only" 53 bits wide.
10725
10726 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10727
10728         Adding sdcclib to the build.  MSVC project coming soon.
10729         Files added/changed:
10730
10731         * support/librarian/clean.mk
10732         * support/librarian/configure
10733         * support/librarian/configure.in
10734         * support/librarian/config_in.h
10735         * support/librarian/Makefile.bcc
10736         * support/librarian/Makefile.in
10737         * support/librarian/sdcclib.c
10738         * Makefile.bcc
10739         * Makefile
10740         * Makefile.common.in
10741         * configure
10742         * configure.in
10743
10744 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10745
10746         Linker now complaints if linked modules have conflicting options, for
10747         example, one compiled using --model-large and another one compiled with
10748         --model-small.  The following files were modified:
10749
10750         * as/mcs51/asdata.c
10751         * as/mcs51/aslink.h
10752         * as/mcs51/asm.h
10753         * as/mcs51/asmain.c
10754         * as/mcs51/asout.c
10755         * as/mcs51/i51pst.c
10756         * as/mcs51/lkdata.c
10757         * as/mcs51/lklibr.c
10758         * as/mcs51/lkmain.c
10759         * as/z80/asdata.c
10760         * as/z80/asm.h
10761         * as/z80/asmain.c
10762         * as/z80/asout.c
10763         * as/z80/z80pst.c
10764         * link/z80/aslink.h
10765         * link/z80/lkdata.c
10766         * link/z80/lklibr.c
10767         * link/z80/lkmain.c
10768         * src/SDCCglue.c
10769
10770 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10771
10772         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
10773         as/mcs51/lklibr.c: Generate a warning when a library is not found.
10774
10775 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
10776
10777         * src/z80/mappings.i: fix _mul[us][int,long] entries
10778
10779 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10780
10781         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
10782
10783 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
10784
10785         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
10786         * support/regression/tests/bitopcse.c: added
10787         fixed warning:
10788         * src/avr/gen.c:
10789         * src/pic/gen.c:
10790         * src/pic16/gen.c:
10791         * src/z80/gen.c:
10792         * src/xa51/gen.c:
10793
10794 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10795
10796         added support for new library format to z80, gbz80 linkers:
10797         *link/z80/aslink.h
10798         *link/z80/lklex.c
10799         *link/z80/lklib.c
10800         *link/z80/lklist.c
10801
10802 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
10803
10804         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
10805         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
10806
10807 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
10808
10809         added DUMMY_READ_VOLATILE:
10810         * src/SDCC.y:
10811         * src/avr/gen.c:
10812         * src/xa51/gen.c:
10813         * src/z80/gen.c:
10814         * src/pic/gen.c:
10815         * src/pic16/gen.c:
10816         * src/mcs51/gen.c:
10817         * src/ds390/gen.c:
10818         * src/SDCCcse.c (algebraicOpts): many improvements
10819         * src/SDCCcse.h: removed algebraicOpts()
10820         * src/SDCCicode.c (picDummyRead): added
10821
10822 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10823
10824         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
10825         "Insufficient space in data memory".
10826
10827 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10828
10829         * src/mcs51/gen.c: fixed bug #771358
10830         * src/z80/gen.c: fixed bug #759087
10831
10832 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
10833
10834         * src/pic16/glue.c: minor cleanup by Vangelis
10835
10836 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10837
10838         * device/include/regc515c.h: fixed #758477
10839         * device/lib/_gptrget.c: saving some cycles in generic pointer get
10840         * device/lib/_gptrput.c: saved a few bytes
10841         * my tab spacing is 8, yours too?)
10842         * device/lib/_ser.c: process RX bytes earlier than TX bytes
10843         * device/lib/serial.c: process RX bytes earlier than TX bytes
10844         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
10845
10846 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10847
10848         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
10849
10850 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10851
10852     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
10853
10854 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
10855
10856         * device/lib/Makefile.in: bad fix, reverted to 1.43
10857
10858 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
10859
10860         * device/lib/Makefile.in: added missing z80 object files
10861
10862 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
10863
10864         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
10865         pic16 progress by Vangelis:
10866         * src/SDCCglobl.h:
10867         * src/SDCCmain.c:
10868         * src/pic/Makefile:
10869         * src/pic:
10870         * pic/Makefile:
10871         * pic16/device.c:
10872         * pic16/device.h:
10873         * pic16/gen.c:
10874         * pic16/gen.h:
10875         * pic16/genarith.c:
10876         * pic16/glue.c:
10877         * pic16/main.c:
10878         * pic16/pcode.c:
10879         * pic16/pcode.h:
10880         * pic16/pcodepeep.c:
10881         * pic16/peeph.def:
10882
10883 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10884
10885     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
10886
10887 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10888
10889     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
10890     added gbz80 build to MSVC project.
10891     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
10892     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
10893     from 8051 stuff and setup so it links using a .lnk file.
10894
10895 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10896
10897     * support/librarian/sdcclib.c: sdcc librarian.
10898     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
10899     with sdcclib.
10900
10901 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10902
10903     * as/mcs51/lkmain.c: properly handle extensions in function afile.
10904
10905 2003-07-02  Borut Razem <borut.razem AT siol.net>
10906
10907         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
10908         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
10909         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
10910         src/xa51/main.c, src/z80/main.c:
10911         virtualization of glue() function: each port has it's own glue function,
10912         which is accessed by do_glue function pointer in PORT.general structure
10913
10914 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
10915
10916         * DS800C400 fun, improved ROM interface and tinibios.
10917
10918 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
10919
10920         * More support for DS80C400. Now includes beginning of interface to ROM.
10921
10922 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
10923
10924         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
10925
10926 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10927
10928         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
10929
10930 2003-06-19  Borut Razem <borut.razem AT siol.net>
10931
10932         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
10933
10934 2003-06-19  Borut Razem <borut.razem AT siol.net>
10935
10936         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
10937         fixed Z80 port - crt0.o: cannot open.
10938
10939 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
10940
10941         * support/Util/MySystem.c (merge_command): revert bad fix
10942
10943 2003-06-18  Borut Razem <borut.razem AT siol.net>
10944
10945         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
10946
10947 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10948
10949         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
10950         option --use-stdout sends errors to stdout instead of stderr.
10951
10952 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
10953
10954         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
10955
10956 2003-06-15  Borut Razem <borut.razem AT siol.net>
10957
10958         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
10959         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
10960         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
10961         fixed width array of pointers replaced with sets;
10962         multiple include and lib paths ared transferred to preprocessor and linker
10963         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
10964         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
10965         fixed width array of pointers
10966         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
10967         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
10968         fixupPath(), getPathDifference()
10969         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
10970         fixed width array of pointers
10971
10972 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
10973
10974         * src/pic16/ralloc.c: fix warnings
10975         * src/pic16/pcode.c: fix warning
10976
10977 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
10978
10979          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
10980         know all the details, but essentially this set of changes enable
10981         the pic16 port to generate movff instructions and generate assembler
10982         directives,
10983         * src/SDCCmain.c:
10984         * src/pic16/gen.c:
10985         * src/pic16/glue.c:
10986         * src/pic16/pcode.c:
10987         * src/pic16/device.c:
10988         * src/pic16/main.c:
10989         * src/pic16/pcode.h:
10990         * src/pic16/pcoderegs.c:
10991         * src/pic16/ralloc.c:
10992         * src/pic16/ralloc.h:
10993
10994 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10995
10996         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
10997         added option --vc, so sdcc errors and warnings are compatible with
10998         Microsoft Visual Studio.
10999
11000 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11001
11002         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
11003           device/lib/libfloat.lib: added atof function.
11004
11005 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
11006
11007         * doc/sdccman.lyx: updated to Lyx 1.3
11008         * doc/cdbfileformat.lyx: updated to Lyx 1.3
11009         * doc/test_suite_spec.lyx: updated to Lyx 1.3
11010         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
11011
11012 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
11013
11014         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
11015
11016 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11017
11018         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
11019           additions to the "related tools/documentation" section
11020
11021 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
11022
11023         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
11024
11025 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
11026
11027         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
11028         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
11029
11030 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
11031
11032         * doc/sdccman.lyx: fix double dash and other minor things
11033         * doc/Makefile: fix double dash
11034
11035 2003-05-28  Karl Bongers(patches from Martin Helmling)
11036         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
11037           condition and ignore commands.
11038
11039 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11040
11041         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
11042           is in parts still quite out of date, I did changes as far as I felt makes sense
11043           for a non-native english speaker.
11044           Please feel free to add to the manual or to correct my changes.
11045         * doc/Makefile: undid touching the date of intermediate tex files.
11046
11047 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11048
11049         * doc/sdccman.lyx: Manual has an index now
11050
11051 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
11052
11053         Finalize muluint/mulsint and mululong/mulslong merging:
11054         * device/lib/_mulint.c
11055         * device/lib/_mullong.c
11056         * device/lib/gbz80/mul.s
11057         * device/lib/gbz80/stubs.s
11058         * device/lib/z80/mul.s
11059         * device/lib/z80/stubs.s
11060         * src/SDCCsymt.c (initCSupport)
11061
11062 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11063
11064         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
11065         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
11066           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
11067           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
11068           instead of /Zm500.
11069
11070 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11071
11072         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
11073           the regression tests I'm not brave enough to enable 245.b, 245.c
11074         * doc/sdccman.lyx: added latex preamble for hyperref package.
11075           Using pdflatex this will give you a hyperlinked pdf file with
11076           bookmarks. (prepend '%' before /usepackage if this breaks something)
11077
11078 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11079
11080          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
11081
11082 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
11083
11084         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
11085
11086 2003-05-21    <johan AT balder>
11087
11088         * src/SDCCglue.c (printIval): fixed bug #739934
11089
11090 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
11091
11092         Applied patch from bug 737905 (renamed yylineo to mylineno):
11093         * src/altlex.c
11094         * src/SDCCast.c
11095         * src/SDCglobl.h
11096         * src/SDCC.lex
11097         * src/SDCCsymt.c
11098         * src/SDCCval.c
11099         * src/pic16/pcode.c: Cleaned warnings
11100         * src/pic16/pcodeflow.c: Cleaned warnings
11101         * src/pic16/pcoderegs.c: Cleaned warnings
11102
11103 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
11104
11105         * src/pic16/pcode.c: Cleaned warnings
11106         * src/pic16/pcodepeep.c: Cleaned warnings
11107         * src/pic16/ralloc.c: Cleaned warnings
11108
11109 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
11110
11111         * doc/sdccman.lyx: fixed bug 739745
11112         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
11113
11114 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
11115
11116         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
11117         it can be defined with CFLAGS when running configure
11118         * src/SDCCmain.c: fixed compiling + linking with object files
11119
11120 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
11121
11122         * configure.in: configure for pic16 port,
11123             added --disable-pic16-port
11124         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
11125         * src/SDCCmain.c: linkOptions is changed to set *,
11126             added if/endif conditional macros to remove options help
11127             messages from optionsTable when a port is not configured, added
11128             support for the PIc16 port in the ports table, when executing
11129             the compiler with no port specified on command line, a default
11130             port is selected with the new macro DEFAULT_PORT which is
11131             defined in port.h, in setDefaultOptions() linkOptions is removed
11132             from initialization assignment, since now it is a set,
11133             parseCmdLine uses setParseWithComma for linkOptions, in
11134             linkEdit() linkOptions are accessed with new function indexSet()
11135             which returns the i'th item of a set variable. See SDCCset.c, in
11136             linkEdit() when calling buildCmdLine(), added linkOptions as
11137             last argument. Now users can pass arguments to gplink via the
11138             -Wl option, main() uses pic16glue() to glue up pic16 programs
11139         * src/SDCCpeeph.c: various changes to support pic16
11140         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
11141             return the i'th item of the set
11142         * src/SDCCset.h: added function prototype for indexSet()
11143         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
11144         * src/clean.mk: added pic16 in CLEANALLPORTS variable
11145         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
11146             added macro DEFAULT_PORT
11147         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
11148         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
11149             generated
11150         * src/pic16/glue.c: commented out some error producing lines
11151         * src/pic16/main.c: __config directives are commented out to stop
11152             gpasm complaining and test the linkage with gplink, _linkCmd and
11153             _asmCmd changed to be more gplink and gpasm friendly
11154         * src/pic16/peeph.def: peep rule 3 is commented out, since it
11155             produced an error when parsed, peep rule 12 is added to utilize
11156             movff, but it is commented out since the pCode does not support
11157             yet a command with 2 address arguments
11158
11159 2003-05-18    <johan AT balder>
11160
11161         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
11162         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
11163 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
11164
11165         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
11166   Added feature to script commands from file.
11167
11168 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
11169
11170         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
11171         * src/SDCCutil.c: include ctype.h for win32
11172
11173 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
11174
11175         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
11176
11177 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
11178
11179         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
11180   Fixed so you can set breakpoints prior to run, run does not stop
11181   on entry now.  Add tbreak.  Other enhancements and fixes for use
11182   with ddd.
11183
11184 2003-05-12  Borut Razem <borut.razem AT siol.net>
11185
11186         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
11187
11188 2003-05-11  Borut Razem <borut.razem AT siol.net>
11189
11190         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
11191         the path of bin directory, so that PATH is the only env. variable, which has to be set
11192         in case of standard installation.
11193         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
11194         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
11195         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
11196
11197 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
11198
11199         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
11200         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
11201         temp files are in the port dir; clean the gen/test directory when
11202         generating new test.c
11203         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
11204         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
11205         * support/regression/tests/zeropad.c: added
11206
11207 2003-05-09    <johan AT balder>
11208
11209         * src/SDCCglue.c: fixed bug #597940
11210
11211 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
11212
11213         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
11214   cache sfr, optimize next,step, fix off by one sourceline,
11215   support ddd list function.
11216         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
11217
11218 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
11219
11220         * support/regression/HTMLgen.py: added compare_s2f()
11221         * support/regression/Makefile: redo 1.27
11222         * support/regression/generate-cases.py: redo 1.5
11223
11224 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
11225
11226         * support/regression/tests/float.c: workaround 33 bit hex constant
11227         * support/regression/tests/simplefloat.c: fix division for host
11228
11229 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
11230
11231         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
11232         that tame's the PIC's over-aggressive optimizer.
11233
11234 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11235
11236          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
11237          support for MSVC.
11238
11239 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
11240
11241         Initial support for DS80C400. "Hello world" runs on TINIm400
11242         (with polled I/O).
11243
11244 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
11245
11246          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
11247          * Some notes on ddd usage added in debugger/README
11248          Martin Helmling adding more features and fixes for ddd GUI debugger.
11249          Code added for nexti, stepi, up, down, and other adjustments.
11250
11251 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
11252
11253         * src/pic/pCodepeep.c non-wildcard asmops are now handled
11254         * src/pic/peeph.def Added two rules to optimize carry manipulation
11255         * src/pic/* removed debug printfs
11256
11257 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
11258
11259         * debugger/mcs51/cmd.c: added header newalloc.h
11260
11261 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
11262
11263         * as/Makefile: new EXEEXT
11264         * as/z80/Makefile: remove trailing slash of BUILDIR
11265         * as/z80/clean.mk: new EXEEXT
11266         * Makefile.common.in: add to CFLAGS (and others), don't replace it
11267         * support/cpp2/Makefile.in: new EXEEXT
11268         * src/pic/glue.c (pic14emitRegularMap): fixed warning
11269
11270 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
11271
11272         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
11273         EXEEXT was introduced to fix all related problems with targets
11274         "clean", "install" and "uninstall"; a couple of further flaws
11275         especially with "clean" have been fixed too
11276         * as/mcs51/Makefile.in
11277         * as/mcs51/clean.mk
11278         * as/z80/Makefile
11279         * Makefile
11280         * clean.mk
11281         * debugger/mcs51/Makefile.in
11282         * debugger/mcs51/clean.mk
11283         * link/z80/Makefile
11284         * link/z80/Makefile.in
11285         * link/z80/clean.mk
11286         * link/Makefile
11287         * packihx/Makefile.in
11288         * packihx/clean.mk
11289         * sim/ucsim/Makefile
11290         * sim/ucsim/clean.mk
11291         * sim/ucsim/avr.src/Makefile.in
11292         * sim/ucsim/avr.src/clean.mk
11293         * sim/ucsim/s51.src/Makefile.in
11294         * sim/ucsim/s51.src/clean.mk
11295         * sim/ucsim/xa.src/Makefile.in
11296         * sim/ucsim/xa.src/clean.mk
11297         * sim/ucsim/z80.src/Makefile.in
11298         * sim/ucsim/z80.src/clean.mk
11299         * sim/ucsim/main_in.mk
11300         * sim/ucsim/packages_in.mk
11301         * sim/ucsim/gui.src/Makefile.in
11302         * sim/ucsim/gui.src/serio.src/Makefile.in
11303         * sim/ucsim/gui.src/serio.src/clean.mk
11304         * src/Makefile.in
11305         * src/clean.mk
11306         * support/cpp2/Makefile.in
11307         * support/cpp2/clean.mk
11308         * support/makebin/Makefile
11309         * support/makebin/clean.mk
11310         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
11311         * doc/sdccman.lyx: --program-suffix no longer needed
11312
11313 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
11314
11315          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
11316          Martin Helmling added support for ddd GUI debugger.
11317          Code added to display assembly, set variables, and other commands
11318          to interface to ddd.
11319
11320 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
11321
11322         * as/Makefile: fix target clean
11323         * as/clean.mk: fix target clean
11324         * as/z80/clean.mk: fix target clean
11325
11326 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
11327
11328         * Makefile.common.in: added  AT EXEEXT AT
11329         * configure.in: removed all mingw32 stuff
11330         * configure: rebuilt from configure.in
11331         * doc/sdccman.lyx: updated section "installation"
11332         * support/scripts/sdcc_mingw32: adapted to configure
11333         * support/scripts/sdcc_cygwin_mingw32: added
11334
11335 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
11336
11337         * src/pic Added object file support for the PIC port
11338         * src/pic Applied patch from Craig Franklin (this started the object file support)
11339         * src/regression Updated the PIC regression tests for object files
11340
11341 2003-04-20  Borut Razem <borut.razem AT siol.net>
11342
11343         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
11344           lklex.c: In function `getfid':
11345           lklex.c:203: warning: array subscript has type `char'
11346         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
11347           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
11348         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
11349           stack handling macros
11350
11351 2003-04-19  Borut Razem <borut.razem AT siol.net>
11352
11353         * "handling space characters in file path" task:
11354         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
11355         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
11356         * support/Util/MySystem.h: make it self-sufficient
11357         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
11358           src/z80/main.c, sdcc/as/mcs51/lklex.c:
11359           handling space characters in file path
11360         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
11361           (it will be used by assemblers, which have their own includes, e.g. gpasm)
11362         * support/Util/MySystem.c: handling space characters in executable's path
11363
11364 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
11365
11366         * as/z80/Makefile: fix permanent rebuild of z80
11367         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
11368         * support/regression/tests/bitfields.c: added Johan's bitfields.c
11369
11370 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
11371
11372         * src/SDCCopt.c: add special case optimization to replace modulo by
11373           a power of two with a bitwise AND.
11374
11375 2003-04-18    <johan AT balder>
11376
11377         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
11378
11379 2003-04-17    <johan AT balder>
11380
11381         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
11382         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
11383
11384 2003-04-13  Borut Razem <borut.razem AT siol.net>
11385
11386         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
11387         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
11388           fixed mingw problem in adl_NORMALIZE_PATH
11389
11390 2003-04-12  Borut Razem <borut.razem AT siol.net>
11391
11392         * fixed "#pragma SAVE/RESTORE can not be nested":
11393         * src/SDCC.lex: reworked pragma handling functions
11394         * sdcc/src/SDCCglobl.h: reworked stack handling macros
11395         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
11396
11397 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
11398
11399         * src/SDCCutil.c (pathEquivalent): defined but not used
11400         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
11401         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
11402         * configure: rebuilt from configure.in
11403         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
11404         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
11405         * device/include/Makefile.in: replace sdcc_datadir
11406         * device/lib/Makefile.in: replace sdcc_datadir
11407         * Makefile.common.in: add LDFLAGS from configure
11408         * packihx/Makefile.in: use LDFLAGS
11409         * src/Makefile.in: use LDFLAGS
11410         * support/cpp2/Makefile.in: add LDFLAGS from configure
11411         * support/makebin/Makefile: use LDFLAGS
11412         * .version: bumped version number to 2.3.5
11413
11414 2003-04-12  Borut Razem <borut.razem AT siol.net>
11415
11416         * completed "different paths" task:
11417         * src/SDCCmacro.c: fixed bug in handling quotes
11418         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
11419         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
11420
11421 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
11422
11423         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
11424
11425 2003-04-11 kevin Vigor <kevin AT vigor.nu>
11426
11427         * ds390/gen.c ds390/peeph.def: fix bug 706781
11428
11429 2003-04-11  Borut Razem <borut.razem AT siol.net>
11430
11431         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
11432
11433 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
11434
11435         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
11436         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
11437          set - this bit used to not be set...).
11438         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
11439           bad code in PIC Port
11440         * src/regression/and2.c added to test bug 609268
11441         * src/regression/Makefile added and2.c to regression test
11442
11443
11444 2003-04-08    <johan AT CP255758-A>
11445
11446         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
11447         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
11448         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
11449
11450 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
11451
11452         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
11453         fix bug #487815
11454         * support/cpp2/Makefile.in: fix bug #487815
11455         * configure: rebuilt from configure.in
11456         * Makefile.common.in: docdir changed, new path suffixes
11457         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
11458         * sdcc_vc_in.h: reflect changes from sdccconf.h
11459         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
11460         * src/SDCCutil.h: remove BINDIR hack
11461         * doc/sdccman.lyx: update new path hierarchy
11462
11463 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11464
11465         * src/SDCCpeeph.c: added okToRemoveSLOC test
11466
11467 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11468
11469         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
11470
11471 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
11472
11473         * src/SDCCpeeph.c: added labelIsReturnOnly test
11474         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
11475
11476 2003-04-05    <johan AT balder>
11477
11478         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
11479         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
11480         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
11481         * src/SDCCast.c: fixed a warning
11482         * src/SDCCast.h: fixed a warning
11483         * src/SDCCicode.c (operandFromAst): fixed a warning
11484
11485 2003-04-04    <johan AT balder>
11486
11487         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
11488         * src/SDCCast.c (decorateType): fixed bug #715076
11489         * src/SDCC.y: fixed bug #702907
11490
11491 2003-04-03    <johan AT balder>
11492
11493         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
11494         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
11495         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
11496         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
11497         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
11498
11499 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
11500
11501         * _decdptr.c: fix return values
11502         * _gptrget.c: fix return values
11503         * _gptrgetc.c: fix return values
11504         * _gptrput.c: fix return values
11505         * _mulint.c: fix return values
11506         * as/z80/Makefile: fix 'make -j' problem
11507
11508 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
11509
11510         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
11511         * configure.in: big cleanup, updated to autoconf 2.5x
11512         * configure: rebuilt from configure.in
11513         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
11514         * sdcc_vc_in.h: reflect changes from sdccconf.h
11515         * doc/Makefile: fixed a flaw in "make install"
11516
11517 2003-04-02    <johan AT balder>
11518
11519         * src/ds390/gen.c (genCmp): no comments
11520         * src/mcs51/gen.c (genCmp): no comments
11521         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
11522         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
11523
11524 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
11525
11526         * support/regression/generate-cases.py: place generated file in given sub directory
11527         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
11528         * support/regression/Makefile: improvements for 'make -j';
11529         side effect: it's simpler and faster now
11530
11531 2003-03-31  Borut Razem <borut.razem AT siol.net>
11532
11533         * src/z80/main.c: link-{port} and as-{port} defined without path
11534         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
11535
11536 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
11537
11538         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
11539
11540 2003-03-30  Borut Razem <borut.razem AT siol.net>
11541
11542         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
11543           changed type of list parameter to set
11544         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
11545         * src/port.h: changed type of do_assemble() parameter to set
11546         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
11547           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
11548           definition of "cppoutfilename" macro with NULL value in preProcess()
11549         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
11550         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
11551         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
11552           replaced with set *binPathSet
11553         * shash_add() deallocates the item, if allready exsists, before adding the new one
11554         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
11555
11556 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
11557
11558         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
11559           a nested for loop bug in the PIC port
11560         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
11561           for loops
11562
11563 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
11564
11565         * support/Util/dbuf.h: remove C++ stuff to make it portable
11566
11567 2003-03-28  Borut Razem <borut.razem AT siol.net>
11568
11569         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
11570           literal strings in stringLiteral()
11571         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
11572         * src/Makefile.bcc, src/Makefile.in, src/src.dsp: added support/Util/dbuf.c
11573           to the project
11574
11575 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
11576
11577         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
11578
11579 2003-03-26    <johan AT balder>
11580
11581         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
11582         * src/ds390/gen.c (saveRegisters): catched symbol abuse
11583         * src/SDCCast.c (decorateType): fixed " -v < 3"
11584
11585 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
11586
11587         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
11588         Added Lenny Story's debug infrastructure changes:
11589         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
11590         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
11591         * src/cdbFile.c: added
11592         * src/SDCCdebug.c: added
11593         * src/SDCCdebug.h: added
11594         * src/SDCCast.c (createFunction)
11595         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
11596         * src/SDCCmain.c (parseCmdLine, main)
11597         * src/SDCCmem.c (redoStackOffsets)
11598         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
11599         * src/SDCCsymt.h
11600         * src/common.h
11601         * src/avr/gen.c (genAVRCode)
11602         * src/ds390/gen.c (gen390Code)
11603         * src/mcs51/gen.c (gen51Code)
11604         * src/pic/gen.c (genpic14Code)
11605         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
11606         * src/xa51/gen.c (genXA51Code)
11607         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
11608
11609 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11610
11611         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
11612         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
11613
11614 2003-03-22    <johan AT balder>
11615
11616         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
11617
11618 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
11619
11620         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
11621         * doc/cdbfileformat.lyx: added, written by Lenny Story
11622         * doc/Makefile: added cdbfileformat.lyx
11623         * doc/clean.mk: added cdbfileformat.lyx
11624
11625 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
11626
11627         * src/mcs51/peeph.def: fix bug #705773
11628
11629 2003-03-20    <johan AT balder>
11630
11631         An sfr/sbit can have an "at #" AND an initializer
11632         * src/SDCCsymt.c (checkSClass):
11633         * src/SDCCmem.c (allocGlobal):
11634         * src/SDCCmem.c (allocLocal):
11635         * src/SDCCast.c (createBlock):
11636
11637 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
11638
11639         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
11640
11641 2003-03-16    <johan AT balder>
11642
11643         Undid the hackup of const and volatile, the problem is much bigger
11644         * src/SDCC.y:1.65
11645         * src/SDCCast.c:1.171
11646         * src/SDCCglue.c:1.138
11647         * src/SDCCicode.c:1.146
11648         * src/SDCCsymt.c:1.150
11649         * src/SDCCval.c:1.65
11650
11651 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
11652
11653         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
11654         * src/ds390/gen.c (genAddrOf): fixed bug #704087
11655
11656 2003-03-13    <johan AT balder>
11657
11658         Hackup const and volatile modifiers in type chains a bit:
11659         * src/SDCC.y:1.63
11660         * src/SDCCast.c:1.169
11661         * src/SDCCglue.c:1.136
11662         * src/SDCCicode.c:1.143
11663         * src/SDCCsymt.c1.146
11664         * src/SDCCsymt.h1.59
11665         * src/SDCCval.c:1.63
11666
11667 2003-03-12    <johan AT balder>
11668
11669         * src/SDCCBBlock.h: more LRH debugging junk
11670         * src/SDCCcflow.h: more LRH debugging junk
11671         * src/SDCCloop.c: more LRH debugging junk
11672         * src/SDCC.y (struct_declaration): fixed bug #697590
11673         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
11674         * src/ds390/gen.c (aopForRemat): fixed bug #700031
11675         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
11676
11677 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
11678         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
11679         test function names must now match exactly).
11680         * src/SDCCcse.c: added special case in findCheaperOp to allow
11681         extending a short integer. Makes less awful code for bug 700121 test case.
11682
11683 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11684
11685         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
11686         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
11687
11688 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
11689
11690         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
11691         actually called (operandsNotEqual() was called for all
11692         operandsNotEqualX tests).
11693
11694 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
11695
11696         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
11697         with shorter literals. Fixes bug 700121.
11698
11699 2003-03-11    <johan AT balder>
11700
11701         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
11702
11703 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
11704
11705         * src/SDCCloop.c (mergeRegions): an evil beast is dead
11706         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
11707
11708 2003-03-10  Borut Razem <borut.razem AT siol.net>
11709
11710         * src/SDCCmain.c: pipe preprocessor's output
11711         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
11712         * sdcc_vc_in.h: define pclose as _pclose for WIN32
11713         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
11714         which closes all pipes in pipeSet set
11715         * src/SDCCset.c: free deleted item in function deleteSetItem()
11716         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
11717         moved from z80 to src subproject
11718         * .version: increased version number to 2.3.4
11719
11720 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
11721
11722         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
11723         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
11724         * support/regression/ports/xa51/spec.mk: fix typo
11725
11726 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
11727
11728         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
11729
11730 2003-03-09  Borut Razem <borut.razem AT siol.net>
11731
11732         * src/SDCCmain.c: pipe preprocessor's output
11733         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
11734         * sdcc_vc_in.h: define pclose as _pclose for WIN32
11735         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
11736         which closes all pipes in pipeSet set
11737         * src/SDCCset.c: free deleted item in function deleteSetItem()
11738         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
11739         moved from z80 to src subproject
11740
11741 2003-03-09  Borut Razem <borut.razem AT siol.net>
11742
11743         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
11744         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
11745         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
11746         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
11747         * src/SDCCglobl.h: unification of WIN32 native definitions
11748
11749 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11750
11751         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
11752
11753 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
11754
11755         * src/configure.in:   check for endianess (even while cross-compiling)
11756         * src/configure:      check for endianess (even while cross-compiling)
11757         * src/configure_in.h: check for endianess (even while cross-compiling)
11758         * src/avr/gen.c:        remove old endianess stuff
11759         * src/mcs51/gen.c:      remove old endianess stuff
11760         * src/ds390/gen.c:      remove old endianess stuff
11761         * src/pic/gen.c:        remove old endianess stuff
11762         * src/pic/genarith.c:   remove old endianess stuff
11763         * src/pic/glue.c:       fix endianess check
11764         * src/pic16/gen.c:      remove old endianess stuff
11765         * src/pic16/genarith.c: remove old endianess stuff
11766         * src/pic16/glue.c:     fix endianess check
11767         * src/xa51/gen.c:       remove old endianess stuff
11768         * src/z80/gen.c:        fix endianess check
11769         * src/SDCCglue.c:       fix endianess check
11770         * src/ds390/peeph.def: fix bug 700036
11771
11772 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
11773
11774         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
11775         * src/configure: find appropriate data-types on host for SDCC's int and long
11776         * src/configure.in: find appropriate data-types on host for SDCC's int and long
11777         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
11778         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
11779
11780 2003-03-07    <johan AT balder>
11781
11782         Just a big NOOP:
11783                 some minor cleanups before the big shot
11784                 OP_DEFS and OP_USES now use Kevin's protection
11785                 new option --nolabelopt
11786
11787         * src/SDCCBBlock.c:
11788         * src/SDCCast.c,:
11789         * src/SDCCcflow.c:
11790         * src/SDCCcse.c:
11791         * src/SDCCicode.c:
11792         * src/SDCCicode.h:
11793         * src/SDCClabel.c:
11794         * src/SDCCloop.c:
11795         * src/SDCCmain.c:
11796         * src/ds390/ralloc.c:
11797         * src/mcs51/ralloc.c:
11798         * src/pic/ralloc.c:
11799         * src/xa51/ralloc.c:
11800         * src/z80/ralloc.c:
11801
11802 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
11803
11804         * src/pic/pcode.c (get_op): fix 64 bit warnings
11805         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
11806         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
11807         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
11808         * support/regression/tests/malloc.c: fix 64 bit warnings
11809
11810 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
11811
11812         * src/mcs51/gen.c (genMinus): fixed bug 696436
11813
11814 2003-03-02  Borut Razem <borut.razem AT siol.net>
11815
11816         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
11817
11818 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
11819
11820         * configure.in: test for mkstemp
11821         * sdccconf_in.h: add HAVE_MKSTEMP
11822
11823 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
11824
11825         * device/include/ctype.h: removed warning while using --stack-auto
11826         * device/include/malloc.h: removed warning while using --stack-auto
11827         * device/include/string.h: removed warning while using --stack-auto
11828
11829 2003-02-23  Borut Razem <borut.razem AT siol.net>
11830
11831         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
11832         because NDEBUG is defined (see man assert)
11833         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
11834
11835 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11836
11837         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
11838         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
11839
11840 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11841
11842         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
11843         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
11844
11845 2003-02-18    <johan AT balder>
11846
11847         * as/mcs51/asmain.c (asmbl): module can start with a digit
11848         * as/z80/asmain.c (asmbl): module can start with a digit
11849
11850 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
11851
11852         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
11853         * src/asm.c: fix pipe() for Mingw32
11854
11855 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
11856
11857         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
11858         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
11859         make -V work again; --c1mode reads now from stdin
11860         * doc/sdccman.lyx: added --c1mode
11861         * support/Util/SDCCerr.c: new messages for c1 mode
11862         * support/Util/SDCCerr.h: new messages for c1 mode
11863         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
11864
11865 2003-02-15    <johan AT balder>
11866
11867         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
11868
11869 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
11870
11871         * doc/sdccman.lyx: Environment variables, -o and other minor things
11872
11873 2003-02-14    <johan AT balder>
11874
11875         * src/xa51/main.c: before anyone really tries to use it :)
11876
11877         * Install doc's in share/sdcc/doc
11878         * removed some obsolete files
11879         * Do a proper make distclean and uninstall
11880         M Makefile.common.in
11881         R sdccbuild.sh
11882         M as/Makefile
11883         M device/include/Makefile.in
11884         M device/lib/Makefile.in
11885         M doc/sdccman.lyx
11886         M link/Makefile
11887         M sim/ucsim/doc/Makefile.in
11888         M src/clean.mk
11889         R src/avr/peeph.rul
11890         R src/xa51/peeph.rul
11891         M support/cpp2/Makefile.in
11892         M support/makebin/Makefile
11893
11894
11895 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
11896
11897         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
11898
11899 2003-02-10  Borut Razem <borut.razem AT siol.net>
11900
11901         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
11902         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
11903         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
11904         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
11905         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
11906         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
11907         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
11908         src/z80/Makefile.bcc: Borland Makefile cleanup
11909         * as/z80/Makefile.bcc: Added Borland Makefile
11910         * support/cpp2/borland.h: Removed
11911
11912 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
11913
11914         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
11915         * src/SDCC.lex: new pragma NOIV
11916         * src/SDCCglobl.h: new pragma NOIV
11917         * src/SDCCmem.c: new pragma NOIV
11918
11919 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
11920
11921         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
11922
11923 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
11924
11925         * src/SDCCmain.c: signal handling is switched off by --debug
11926         * doc/Makefile: small fix for install; use clean.mk again
11927         * doc/clean.mk: clean *.pdf and *.html too
11928
11929 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
11930
11931         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
11932         * device/lib/printfl.c: fix a ds390 bug by making it portable
11933         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
11934         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
11935         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
11936         * debugger/mcs51/cmd.c: converted multi-line string literals
11937         * sim/ucsim/globals.cc: converted multi-line string literals
11938         * src/SDCCmain.c: introduced signal handler to remove temp files
11939         * doc/Makefile: small tweaks, implement clean
11940         * doc: removed generated files
11941
11942 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11943
11944         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
11945         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
11946         Address Record is not correctly generated for DS390."
11947
11948 2003-02-02  Borut Razem <borut.razem AT siol.net>
11949
11950         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
11951         * as/mcs51/asm.h: fixed compilation with Borland C
11952         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
11953         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
11954         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
11955         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
11956         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
11957         src/z80/Makefile.bcc: delete $(LIB) only if exist
11958         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
11959
11960 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
11961
11962         * device/include/malloc.h: introduced NULL
11963         * device/include/string.h: introduced NULL
11964         * device/include/stdlib.h: introduced NULL
11965         * device/lib/_memcpy.c: removed NULL
11966         * device/lib/_strcat.c: removed NULL
11967         * device/lib/_strchr.c: removed NULL
11968         * device/lib/_strcmp.c: removed NULL
11969         * device/lib/_strcpy.c: removed NULL
11970         * device/lib/_strcspn.c: removed NULL
11971         * device/lib/_strlen.c: removed NULL
11972         * device/lib/_strncat.c: removed NULL
11973         * device/lib/_strncmp.c: removed NULL
11974         * device/lib/_strncpy.c: removed NULL
11975         * device/lib/_strpbrk.c: removed NULL
11976         * device/lib/_strrchr.c: removed NULL
11977         * device/lib/_strspn.c: removed NULL
11978         * device/lib/_strstr.c: removed NULL
11979         * device/lib/_strtok.c: removed NULL
11980         * device/lib/malloc.c: removed NULL, include own header
11981
11982 2003-02-02    <johan AT balder>
11983
11984         * 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
11985         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
11986         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
11987         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
11988         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
11989         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
11990
11991 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11992
11993         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
11994         area 'DATA'"
11995
11996 2003-02-01    <johan AT balder>
11997
11998         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
11999
12000 2003-01-31    <johan AT CP255758-A>
12001
12002         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
12003
12004 2003-01-30    <johan AT balder>
12005
12006         * src/SDCCBBlock.c: automatic bug detection
12007         * src/SDCCicode.c: automatic bug detection
12008
12009 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12010
12011         * src/SDCCglobl.h:   now --xram-size 0 works
12012         * src/SDCCmain.c:    now --xram-size 0 works
12013
12014 2003-01-29    <johan AT balder>
12015
12016         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
12017
12018 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12019
12020         * as/mcs51/aslink.h: Added options --xram-size and --code-size
12021         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
12022         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
12023         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
12024         * src/SDCCglobl.h:   Added options --xram-size and --code-size
12025         * src/SDCCmain.c:    Added options --xram-size and --code-size
12026
12027 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
12028
12029         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
12030         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
12031
12032 2003-01-27    <johan AT balder>
12033
12034         * src/SDCC.y: fixed bug #613764
12035
12036 2003-01-26    <johan AT balder>
12037
12038         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
12039         * src/SDCCsymt.h: fixed bug #673374
12040         * src/SDCCglue.c: fixed bug #661910
12041         * src/SDCCast.c: fixed bug #458099 and 673374
12042
12043 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
12044
12045         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
12046         * as/mcs51/strcmpi.h: added
12047         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
12048         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
12049         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
12050         * as/mcs51/assym.c: strcmpi -> as_strcmpi
12051         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
12052         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
12053         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
12054         * as/mcs51/Makefile.aslink: new module strcmpi
12055         * as/mcs51/Makefile.asx8051: new module strcmpi
12056         * as/mcs51/Makefil.bcc: new module strcmpi
12057         * as/mcs51/Makefile.in: new module strcmpi
12058         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
12059
12060 2003-01-26    <johan AT balder>
12061
12062         * src/SDCCglue.c: reverted back to 1.124
12063         * src/SDCCast.c: reverted back to 1.156
12064         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
12065
12066 2003-01-25    <johan AT balder>
12067
12068         * src/SDCCglue.c: A better fix for bug #661910
12069         * src/SDCCast.c: A better fix for bug #661910
12070         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
12071
12072 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
12073
12074         * src/Makefile.in: remove spawn.o
12075         * src/SDCCmain.c: remove spawn.h
12076         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
12077         * src/spawn.c: removed
12078         * src/spawn.h: removed
12079         * support/regression/ports/ds390/spec.mk: link with -r
12080
12081 2003-01-24    <johan AT CP255758-A>
12082
12083         * src/ds390/gen.c (aopOp): fixed bug #667458
12084         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
12085         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
12086         (createIvalCharPtr): an ival doesn't always have a storage class anymore
12087
12088 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
12089
12090         * src/mcs51/peeph.def: better assembler identation by Frieder
12091         * src/mcs51/gen.c: better assembler identation by Frieder
12092
12093 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
12094
12095         * as/z80/string.h: removed for gcc 3.2
12096         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
12097         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
12098
12099 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
12100
12101         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
12102         * src/SDCCpeeph.c (replaceRule): fix bug #663503
12103         * support/regression/Makefile: separate temp files for ports
12104         * support/regression/generate-cases.py: separate temp files for ports
12105         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
12106         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
12107
12108 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
12109
12110         * moved tinitalk to device/examples/ds390
12111
12112 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
12113
12114         * as/mcs51/lkmem.c: rflag is for DS390
12115         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
12116         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
12117                          (linkEdit): move mem- and map-files the same way as ihx-files
12118         * src/z80/main.c (_setDefaultOptions): removed --generic
12119         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
12120         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
12121         * src/pic/glue.c (picglue): --c1mode works again
12122         * src/pic16/glue.c (pic16glue): --c1mode works again
12123         * src/asm.c (printCLine): fix #660034
12124
12125 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
12126
12127         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
12128         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
12129         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
12130         * as/mcs51/lkmem (summary): better fix for sp problem
12131         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
12132         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
12133         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
12134                                               remove --stack-after-data
12135
12136 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
12137
12138         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
12139         * src/SDCCutil.c (join): ugly bug: missing '\0'
12140         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
12141
12142 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
12143
12144         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
12145         * src/port.h: typo
12146         * src/pic/main.c (_asmCmd): gpasm supports -o
12147         * src/z80/main.c: more general macros
12148         * device/lib/Makefile.in: remove intermediate files
12149
12150 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
12151
12152         * .version: Bumped version number to 2.3.3
12153         * src/SDCCBBlock.c: new option -o
12154         * src/SDCCglobl.h: new option -o
12155         * src/SDCCglue.c: new option -o
12156         * src/SDCCmain.c: new option -o
12157         * src/asm.c: new option -o
12158         * src/ds390/main.c: new option -o
12159         * src/pic/glue.c: new option -o
12160         * src/pic/pcode.c: new option -o
12161         * src/pic/ralloc.c: new option -o
12162         * src/pic16/glue.c: new option -o
12163         * src/pic16/pcode.c: new option -o
12164         * src/pic16/ralloc.c: new option -o
12165         * src/z80/main.c: new option -o
12166         * device/lib/Makefile.in: use -o
12167         * support/regression/ports/ds390/spec.mk: use -o
12168         * support/regression/ports/gbz80/spec.mk: use -o
12169         * support/regression/ports/mcs51/spec.mk: use -o
12170         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
12171         * support/regression/ports/z80/spec.mk: use -o
12172         * support/regression/ports/ucz80/spec.mk: use -o
12173         * support/regression/ports/xa51/spec.mk: use -o
12174         * support/regression/fwk/lib/timeout.c: fix usage string
12175
12176 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
12177         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
12178
12179 2003-01-07    <johan AT balder>
12180
12181         * src/SDCCast.c (decorateType): fixed bug #600035
12182
12183 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
12184         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
12185         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
12186         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
12187         * src/pic/pcode.c: outcommented unused variable to remove warnings
12188         * src/pic/ralloc.c: outcommented unused variable to remove warnings
12189
12190 2003-01-06    <karl AT turbobit.com>
12191         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
12192    regression tests.
12193
12194 2003-01-06    <johan AT balder>
12195
12196         * src/SDCCicode.c: fixed array add
12197
12198 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
12199         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
12200         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
12201
12202 2003-01-04    <johan AT balder>
12203
12204         * src/SDCCval.c (getNelements): fixed the initialized array of structures
12205
12206 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12207         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
12208
12209 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
12210         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
12211         * support/regression/tests/bug-524697.c: fit mem usage into 8032
12212
12213 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
12214         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
12215
12216 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
12217         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
12218
12219 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
12220         * src/mcs51/main.c: removed {bindir}{sep} from aslink
12221
12222 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12223
12224     * in /sdcc/as/mcs51/ changed these files in order to create an
12225     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
12226     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
12227     following files to include the previous two files: aslink.dsp,
12228     Makefile.aslink, Makefile.bcc, and Makefile.in.
12229
12230     * Changed /sdcc/src/SDCCmain.c so it creates files with extension
12231     .adb instead of .cdb
12232
12233 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12234
12235         * /sdcc/as/mcs51/lklist.c: Now reports memory usage using the
12236         value from option --iram-size.
12237
12238 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12239
12240         * /sdcc/as/mcs51/lklist.c: added boundary check before using
12241         dram[] array.
12242
12243 2002-09-18    <wiml AT hhhh.org>
12244
12245         * SDCClrange.h: exposed setFromRange() and setToRange()
12246         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
12247           packRegsForAccUse() (bug 542397)
12248         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
12249           multiple times and emitting the fetch operations more than once
12250           added aopGetUsesAcc() function to allow binary operators to
12251           fetch their operands in the correct order; made genMinus() emit
12252           compact code for X = LITERAL - Y
12253
12254 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12255         * /sdcc/as/mcs51/lklist.c: Fixed incorrect number of parameters to
12256         sprintf() in line 1267.
12257
12258 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12259         * /sdcc/src/SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
12260         like ports.
12261
12262 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12263         Changes to aslink (All the changes are marked with 'JCF'):
12264
12265         * /sdcc/as/mcs51/aslink.h: External definition of sflag and
12266         summary().
12267
12268         * /sdcc/as/mcs51/lkarea.c: Computes the size of area BSEG_BYTES from
12269         area BSEG.  Also moves, if possible, the DATA area down into the internal
12270         ram so more space is available.
12271
12272         * /sdcc/as/mcs51/lkdata.c: Definition of memory summary output flag
12273         sflag.
12274
12275         * /sdcc/as/mcs51/lklist.c: For the BSEG area report the size in bits,
12276         not bytes.  Function summary() which creates a memory usage summary
12277         file with extension .mem.  Reports of overlaping stack and small stack
12278         size.  If the space for the stack is less than 16 bytes aslink trows a
12279         warning.
12280
12281         * /sdcc/as/mcs51/lkmain.c: Creation of some of the default areas for
12282         the 8051.  Option 'y' for memory summary output file.
12283
12284         Changes to sdcc (All the changes are marked with 'JCF'):
12285
12286         * /sdcc/src/SDCCglobl.h: External definition of RegBankUsed[4].
12287
12288         * /sdcc/src/SDCCglue.c:  If a register bank is used, creates an
12289         overlaying area for it (uses RegBankUsed[4]).
12290
12291         * /sdcc/src/SDCCmain.c: Definition RegBankUsed[4]; marks register
12292         bank zero as used by default.  By default aslink locates the stack
12293         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
12294         the creation of the .mem file.  Delegates the allocation of data area
12295         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
12296         the begining of the stack area to aslink.
12297
12298         * /sdcc/src/SDCCmem.c:  If a register bank is used, marks it so
12299         glue() in SDCCglue.c creates an area for it.
12300
12301 2002-09-03  Borut Razem <borut.razem AT siol.net>
12302         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
12303         sdcc/src/pic/glue.c:
12304         introduced atexit() handler for teporay files removal in case of
12305         errors, assertions, ...
12306
12307 2002-08-29  Borut Razem <borut.razem AT siol.net>
12308         * sdcc/support/cpp2/auto-host_vc_in.h:
12309         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
12310         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
12311         Maybe there is a similar problem with BORLANDC? It should be checked!
12312
12313         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
12314         corrected improper use of assert: the assignment to clr variable was done inside the assert.
12315         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
12316         was not executed, and the compiler (cl) launched a warning:
12317         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
12318
12319 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
12320         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
12321
12322 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
12323         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
12324
12325         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
12326           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
12327           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
12328           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
12329           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
12330           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
12331           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
12332         - added Release configuration in VS projects
12333         - review of compiler an linker options
12334         - VC .exe files are generated in bin_vc directory, not to interfere
12335           with binaries generated from other projects (cygwin, mingw, bcc ...)
12336
12337         * sdcc/src/yacc.dsp: added
12338
12339         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
12340         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
12341         and insert the version number definitions from .version
12342
12343         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
12344
12345         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
12346         added - genarate auto-host.h using auto-host_vc_in.h as template
12347
12348         * sdcc/sdcc_vc.h,
12349         removed from CVS, generated automatically
12350
12351 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
12352         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
12353
12354 2002-08-11  Borut Razem <borut.razem AT siol.net>
12355         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
12356
12357 2002-08-10  Borut Razem <borut.razem AT siol.net>
12358         * src/SDCCmain.c (main):
12359         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
12360         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
12361         The consequence was that some temporary files were not removed.
12362
12363         * src/SDCCglue.c:
12364         unification of code in functions tempfilename() and tempfile():
12365         function tempnam() is defined in Visual Studio 6.0 and .NET
12366
12367         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
12368
12369         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
12370           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
12371         - removed compiler command line option /WX: Treats all warnings as errors
12372         - update a list of source files, included into the project
12373
12374         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
12375           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
12376         changed project type to Generic Project so that can be correcly converted to VS.NET project
12377
12378         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
12379
12380         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
12381
12382         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
12383
12384         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
12385         added return 0 statements after assert() to make compiler happy
12386
12387         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
12388         added newline in the def file to keep MSC compiler satisfied
12389
12390         * sdcc/src/z80/gen.c:
12391         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
12392           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
12393         - solved MSC error in function aopDump()
12394
12395         * sdcc_vc.h: define PREFIX as "\\sdcc"
12396
12397 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
12398         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
12399
12400 2002-06-22  Scott Dattalo <scott AT dattalo.com>
12401         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
12402         - Rewrote the register banking algorithm.
12403         - Added pCode live-range analysis to registers (for now, only non-used and
12404         singly-used registers optimized away)
12405
12406         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
12407
12408         * 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.
12409
12410 2002-05-10  Scott Dattalo <scott AT dattalo.com>
12411         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
12412
12413 2002-04-22  Michael Hope  <michaelh AT vroom>
12414
12415         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
12416
12417         * configure.in (DD_COPT): Added include support required for gbdk.
12418
12419         * .version: Bumped version number just to increase it.
12420
12421         * src/SDCCmain.c: Added -nostdinc to the default options.
12422
12423 2002-04-15  Michael Hope  <michaelh AT vroom>
12424
12425         * device/lib/z80/printf.c (sprintf): Added.
12426
12427         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
12428
12429         * src/z80/peeph.def: Added transpose redundent load rule.
12430
12431         * src/z80/main.c: Added force callee saves for jaune.
12432
12433         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
12434
12435         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
12436
12437 2002-03-28  Johan Knol  <johan AT balder>
12438
12439         * src/SDCCval.c: fixed bug #532436
12440
12441 2002-03-14  Scott Dattalo <scott AT dattalo.com>
12442         * /src/port.h:
12443         Added "char *Processor" field to the port structure.
12444
12445         * /src/SDCCmain.c:
12446         Added -p option. Allows port dependent processor to be specified.
12447
12448         * all ports:
12449         Initialized the new field char *Processor field to NULL in all ports
12450
12451         * /src/pic/*:
12452         Compiler generated registers for interrupt context saving
12453         were not getting allocated.
12454
12455 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
12456
12457         * /src/SDCCast.c:
12458         Fixed left shift. Will promote the left side of a left shift
12459         if a) left shifting more than size of operand or b) when assigned
12460         to something size > size of left side
12461
12462 2002-03-14  Scott Dattalo <scott AT dattalo.com>
12463         * src/pic/*
12464         tons of changes. Register allocation has been
12465         rewritten. Added customization for the various PICs. Flow
12466         analysis is restructured. ...
12467
12468         * src/pic/device.h:
12469         Added
12470
12471         * src/pic/device.c:
12472         Added. device.c is a PIC port hack to accomodate variations
12473         in PIC devices.
12474
12475 2002-03-13  Michael Hope  <michaelh AT vroom>
12476
12477         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
12478
12479 2002-03-04  johanknol  <johanknol AT manik>
12480
12481         * /src/SDCCval.c: fixed
12482
12483         const unsigned char arr[][2] = { { 0, 1 } };
12484         t18.c:1: error: Initializer element is not constant
12485
12486 2002-03-04  bela  <bela AT manik>
12487
12488         * /device/include/mcs51reg.h:
12489         ds89c420 register definition update
12490
12491 2002-03-03    <johan AT FRIJA>
12492
12493         * support/Util/SDCCerr.c: did something, but don't no why anymore
12494
12495         * support/regression/tests/bug-524691.c: made it a little less shy
12496
12497         * src/SDCCast.c (decorateType): fixed bug #524697
12498
12499         * src/SDCCast.c: made some lineno improvements
12500
12501         * src/SDCCval.c (getNelements): changed warning to error
12502
12503         * src/SDCCglue.c (printIvalArray): changed warning to error
12504
12505         * src/SDCCicode.c: fixed a warning for mingw
12506
12507         * src/SDCCast.c (decorateType): fixed the << promotion for ops
12508
12509         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
12510
12511 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
12512
12513         * src/ds390/peeph.def:
12514         Added some more peephole rules
12515
12516         * src/ds390/gen.c: Various fixes & enhancements
12517
12518         * src/SDCClrange.c, src/SDCClrange.h:
12519         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
12520
12521         * src/ds390/ralloc.c:
12522         various fixes & enhancements (ds390) specific
12523
12524         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
12525         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
12526         from rallocs.
12527
12528         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
12529
12530 2002-03-02    <johan AT FRIJA>
12531
12532         * src/SDCCast.c (decorateType): fixed bug #524708
12533
12534         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
12535
12536         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
12537
12538 2002-03-01  Michael Hope  <michaelh AT vroom>
12539
12540         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
12541
12542         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
12543
12544 2002-03-01    <johan AT FRIJA>
12545
12546         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
12547
12548         * src/SDCCast.c (decorateType): fixed bug #524209
12549
12550         * src/SDCCval.c (valNot): fixed bug #524195
12551
12552 2002-02-26    <johan AT balder>
12553
12554         * src/xa51/gen.c: fixed a warning
12555
12556         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
12557
12558         * src/SDCCast.c (decorateType): fixed bug #522534
12559
12560 2002-02-23    <johan AT balder>
12561
12562         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
12563
12564 2002-02-22    <johan AT balder>
12565
12566         * src/SDCCast.c: fixed bug #514865
12567
12568         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
12569
12570 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
12571
12572         * sdcc/src/SDCCloop.c:
12573         Previous fix was not good. basic blocks that have "break" or "return" are
12574         not really partof a loop , but live ranges used in these blocks should
12575         be live thru the entire loop, so set partOfLoop but don't add them to
12576         loop region
12577
12578 2002-02-21    <johan AT FRIJA>
12579
12580         * src/SDCCcse.c: fixed bug #514308
12581
12582 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
12583
12584         * src/SDCCloop.c:
12585         Fixed BUG #519583. If a conditional block ended in a return/break
12586         statement inside a loop, it was not being considered part of the loop.
12587
12588         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
12589
12590 2002-02-10  Karl Bongers <karl AT turbobit.com>
12591
12592         * debugger/*:
12593         Fixed up SDCDB debugger somewhat.  Updated debugger/README
12594         with lots of comments and notes.
12595
12596         * device/examples/test2.c:
12597         Fix bug, "red" variable not being initialized(compiler complained).
12598
12599         * device/examples/Makefile, examples/test3.c:
12600         Add Makefile in device/examples folder, compiles test3.c
12601         for use as a multiple module SDCDB test case.
12602
12603         * sim/ucsim/cmd.src/cmdset.cc:
12604         Took out debug printfs in ucsim "next" command.
12605
12606         * sim/ucsim/xa.src:
12607         Karl and Johan start ucsim XA support.  Most dissassembly working,
12608         about 75% emulation done(plenty of work remaining).
12609
12610         * sim/ucsim/z80.src:
12611         Add Z80 support to ucsim, add test-ucz80 regression test,
12612         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
12613         Notice z80 compiler fails on examples/test3.c/crc code.
12614
12615 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
12616
12617         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
12618         Added support for --parms-in-bank1
12619
12620         * src/ds390/peeph.def:
12621         added a few more peephole optimzations
12622
12623         * src/ds390/main.c:
12624         1) added __builtin_inp & __builtin_outp used to read in data of given length
12625            from a memory mapped port
12626         2) added __builtin_memcmp
12627         3) added __builtin_swapw swap bytes of a short
12628
12629         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
12630         1) handle multiple send & receives from register bank1
12631         2) ralloc can now allocate DPTR1 to some liveRanges
12632
12633         * src/SDCCsymt.c, src/SDCCsymt.h:
12634         changes to handle multiple sends & receives
12635
12636         * src/SDCCptropt.h:
12637         added some pointer arithmetic optimization
12638
12639         * src/SDCCptropt.c:
12640         added some pointer arithmetic optimizations but not stable yet so not
12641         called from anywhere (will get this working shortly)
12642
12643         * src/SDCCopt.c: fixed for multiple sends & receives
12644
12645         * src/SDCCmain.c:
12646         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
12647         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
12648            set preprocessor defines (depending on options)
12649
12650         * src/SDCCicode.c, src/SDCCicode.h:
12651         changes made to handle multiple sends & receives
12652
12653         * src/SDCCglobl.h:
12654         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
12655
12656         * src/SDCCcse.c, src/SDCCcse.h:
12657         added function findbackward def (to be used in upcoming optimization)
12658
12659         * src/SDCCcflow.c, src/SDCCcflow.h:
12660         added function returnAtEnd - to determine if a basic block terminates with
12661         a RETURN iCode
12662
12663         * src/SDCCast.c, src/SDCCast.h:
12664         added option parms-in-bank1
12665
12666         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
12667         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
12668         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
12669         adjusted for --parms-in-bank1 option
12670
12671         * device/include/string.h:
12672         donot redefine "reentrant" keyword
12673
12674         * device/include/ds80c390.h: Added some more SFRs
12675
12676 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
12677
12678         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
12679
12680 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
12681
12682         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
12683
12684 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
12685
12686         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
12687
12688 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
12689
12690         * Added --xram-movc option
12691
12692 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
12693
12694         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
12695
12696 2002-01-11  Johan Knol
12697
12698         * Added math lib of Jesus Calvino-Fraga
12699
12700 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
12701
12702         * src/SDCCmain.c (processFile): fix processing of ../../src.c
12703         * support/regression/Makefile: new target test-mcs51-stack-auto
12704         * support/regression/ports/mcs51-stack-auto/spec.mk: added
12705
12706 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
12707
12708         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
12709
12710 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
12711
12712         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
12713
12714 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
12715
12716         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
12717
12718         * src/SDCCglue.h: add definition for printIvalChar()
12719
12720 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
12721
12722         * src/SDCCast.c: fix #498138 by Johan
12723
12724         * src/SDCCglue.c: fix #498138 by Johan
12725
12726 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
12727
12728         * support/regression/Makefile: fix clean
12729
12730         * support/regression/ports/ds390/support.c: fix transmission of last character
12731
12732 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
12733
12734         * /sdcc/src/ds390/gen.c:
12735         a) improved computing address of stack variable
12736         b) took out some #if 0 code
12737         c) improved parmBytes adjustment
12738         d) improved genPlusIncr & genMinusIncr
12739         e) genCmp could generate bad code (when left assigned to DPTR)
12740         f) Fixed bug in hasInc
12741
12742         * /sdcc/src/ds390/ralloc.c:
12743         a) packRegsForSupport could mess up live information (Fixed)
12744         b) packRegsDPTRuse could be incorrect for left & right shift
12745
12746         * /sdcc/src/mcs51/ralloc.c:
12747         packRegsForSupport could mess up the live information (Fixed)
12748
12749         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
12750
12751         * /sdcc/src/SDCCast.c:
12752         can reverse a loop even if function call is present as long
12753         as the loop control variable is local & is not passed as parameter
12754
12755 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
12756
12757         * /sdcc/ChangeLog: *** empty log message ***
12758
12759         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
12760         More builtin function additions for TININative
12761
12762         * /sdcc/src/ds390/ralloc.c:
12763         Had broken the regression testsuite
12764
12765         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
12766
12767         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
12768         Added funcattr hasStackParms will be set for reentrant functions when there
12769         are paramteres on the stack, this helps in minimizing frame pointer generation
12770         typeFromStr can handle function pointers now
12771
12772         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
12773         *** empty log message ***
12774
12775 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
12776
12777         * /src/ds390/gen.c, /src/ds390/main.c:
12778         More builtin function additions for TININative
12779
12780         * /src/ds390/ralloc.c:
12781         Had broken the regression testsuite
12782
12783         * /src/SDCCast.c: Fixed a bug in dumptree
12784
12785         * /src/SDCCsymt.c, /src/SDCCsymt.h:
12786         Added funcattr hasStackParms will be set for reentrant functions when there
12787         are paramteres on the stack, this helps in minimizing frame pointer generation
12788         typeFromStr can handle function pointers now
12789
12790         * /doc/builtins.txt, /doc/TININative.txt:
12791         *** empty log message ***
12792
12793
12794 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
12795
12796         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
12797         ALPHA version for -mTININative
12798
12799         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
12800         updated to reflect changes in the port structure
12801
12802         * /src/port.h:
12803         added function do_assemble (similar to do_link) if non-null this function
12804         will be called to do assembly (-mTININative) requires a multi command
12805         assembly
12806         added function genAssemblerEnd will be called to generate assembler Epilogue
12807
12808         * /src/SDCCsymt.c:
12809         added _JavaNative to debug info printing
12810
12811         * /src/SDCCmain.c: added option --tini-libid
12812         added port->do_assemble function (-mTININative) has a multi command assemble
12813
12814         * /src/SDCCglue.c: Disabled "constExpr" check
12815         added port->genAssemblerEnd function
12816
12817         * /src/SDCCglobl.h: Added option --tini-libid value
12818
12819         * /src/SDCCast.h:
12820         tookout optimizeCompare from the header (has no external references)
12821
12822         * /src/SDCCast.c: made one more function "static"
12823
12824 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
12825
12826         * src/z80/mappings.i: Added z80asm support.
12827
12828         * src/z80/main.c: Added z80asm support on --asm=z80asm
12829
12830         * src/z80/gen.c: Fixed asm portability issues.
12831
12832         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
12833
12834         * src/SDCCglue.c (printExterns): Added global/extern split.
12835
12836 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
12837
12838         * support/regression/Makefile: added test for mcs51 model large
12839
12840         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
12841
12842         * support/regression/ports/gbz80/spec.mk: added -mgbz80
12843
12844 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
12845
12846         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
12847
12848 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
12849
12850         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
12851
12852         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
12853
12854 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
12855
12856         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
12857
12858         * support/regression/tests/simplefloat.c: Port to mcs51.
12859
12860 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
12861         * support/regression/tests/bug-485362.c: Added.
12862
12863         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
12864
12865         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
12866
12867         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
12868
12869         * src/z80/gen.c (aopDump): Added a dump function.
12870
12871 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
12872         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
12873
12874         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
12875
12876         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
12877
12878         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
12879
12880         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
12881
12882         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
12883
12884         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
12885
12886         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
12887
12888         * support/regression/ports/ds390/support.c: Use tinibios.
12889
12890         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
12891
12892 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
12893
12894         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
12895         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
12896
12897         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
12898
12899         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
12900
12901 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
12902
12903         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
12904
12905         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
12906         (packRegsForIYUse): Created and optimised.
12907
12908 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
12909
12910         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
12911 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
12912
12913         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
12914
12915         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
12916
12917         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
12918
12919 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
12920
12921         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
12922
12923         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
12924
12925 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
12926
12927         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
12928
12929         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
12930
12931         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
12932
12933 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
12934
12935         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
12936         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
12937         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
12938
12939         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
12940
12941         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
12942         (genNotFloat): Added.
12943         (genUminusFloat): Added.
12944
12945         * device/lib/z80/Makefile: Added floating pt stubs.
12946
12947         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
12948
12949         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
12950
12951         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
12952
12953 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
12954
12955         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
12956
12957         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
12958
12959         * sdcc/support/regression/Makefile: Add port ds390.
12960
12961         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
12962
12963         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
12964
12965         * sdcc/support/regression/ports/ds390/spec.mk: Added.
12966
12967         * sdcc/support/regression/ports/ds390/support.c: Added.
12968
12969         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
12970
12971         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
12972
12973         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
12974
12975 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
12976
12977         * device/include/malloc.h: Added z80 and gbz80 support.
12978
12979         * device/lib/gbz80/heap.s: Added.
12980
12981         * device/lib/z80/heap.s: Added.
12982
12983         * device/lib/malloc.c: Added z80 and gbz80 support.
12984
12985         * support/regression/tests/malloc.c (testMalloc): Added.
12986
12987         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
12988
12989         * support/regression/tests/bug-478094.c: Added.
12990
12991         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
12992
12993 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
12994
12995         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
12996
12997         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
12998
12999         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
13000
13001         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
13002
13003         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
13004
13005 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
13006
13007         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
13008
13009 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
13010
13011         * support/regression/tests/bug-477927.c: Added.
13012
13013         * src/z80/peeph.def: Added minor rules.
13014
13015         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
13016
13017         * src/z80/peeph.def: Added jump optimisation modification.
13018
13019 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
13020
13021         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
13022
13023 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
13024
13025         * support/regression/tests/funptrs.c: Added.
13026
13027 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
13028
13029         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
13030
13031 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
13032
13033         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
13034
13035         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
13036
13037         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
13038         (movLeft2ResultLong): Created.
13039
13040         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
13041         (joinPushes): Added.  Joins two char pushes into a word push.
13042
13043 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
13044
13045         * support/cpp2/Makefile.in (install): Added creation of dest dir.
13046
13047         * support/makebin/Makefile (install): Added creation of dest dir.
13048
13049 2001-10-24 Karl Bongers <karl AT turbobit.com>
13050
13051         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
13052
13053 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
13054
13055         * src/z80/ralloc.c: Turned off faulty pack for one use.
13056
13057         * src/z80/peeph-gbz80.def: Removed redundent restart options.
13058
13059         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
13060
13061 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
13062
13063         * support/regression/Makefile: Improved clean
13064
13065         * support/regression/ports/gbz80/spec.mk: Added clean
13066
13067         * support/regression/ports/host/spec.mk: Added clean
13068
13069         * support/regression/ports/z80/spec.mk: Added clean
13070
13071         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
13072
13073         * support/regression/ports/mcs51/timeout.c: little improvements
13074
13075 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
13076
13077         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
13078
13079         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
13080
13081         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
13082
13083 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
13084
13085         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
13086
13087         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
13088
13089 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
13090         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
13091
13092         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
13093
13094         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
13095
13096         * src/mcs51/main.c (_linkCmd): Added bin path to command.
13097
13098         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
13099
13100         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
13101
13102         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
13103
13104         * support/regression/tests/longor.c: Added.
13105
13106 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
13107
13108         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
13109
13110         * as/mcs51/aslink.h: define PATH_MAX
13111
13112         * as/mcs51/asm.h: define PATH_MAX
13113
13114         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
13115
13116         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
13117
13118         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
13119
13120         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
13121
13122         * src/SDCCglobl.h: define PATH_MAX
13123
13124         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
13125
13126         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
13127
13128 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
13129
13130         * src/z80/gen.c (gencjneshort): Fixed
13131
13132         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
13133
13134 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
13135
13136         * support/regression/tests/bug-469671.c: Added.
13137
13138         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
13139
13140 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
13141
13142         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
13143
13144         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
13145
13146 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
13147
13148         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
13149
13150         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
13151
13152         * src/device/lib/_mullong.c : removed hint: nooverlay bug
13153
13154         * src/device/lib/_divuint.c : removed hint: nooverlay bug
13155
13156         * src/device/lib/_divulong.c: removed hint: nooverlay bug
13157
13158         * src/device/lib/_moduint.c : removed hint: nooverlay bug
13159
13160         * src/device/lib/_modulong.c: removed hint: nooverlay bug
13161
13162 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
13163
13164         * 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.
13165
13166         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
13167
13168         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
13169
13170 2001-10-07    <johan AT FRIJA>
13171
13172         * device/lib/gets.c (gets): fixed the return value.
13173
13174 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
13175         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
13176
13177         * 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.
13178
13179         * 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.
13180
13181         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
13182
13183         * src/pic/gen.c: Removed Safe_strdup.
13184
13185         * configure.in: Added option to enable libgc support.
13186
13187         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
13188         (bitVectUnion): Optimised.
13189         (bitVectIntersect): Optimised.
13190         (bitVectBitsInCommon): Optimised.
13191         (bitVectCplAnd): Optimised.
13192
13193         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
13194
13195 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13196
13197         * src/SDCCmain.c: distinguish between assembler debug and plain options
13198
13199         * src/avr/main.c:   remove standard assembler options
13200
13201         * src/ds390/main.c: remove standard assembler options
13202
13203         * src/mcs51/main.c: remove standard assembler options
13204
13205         * src/port.h: removed "PENDING" comment
13206
13207 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13208
13209         * src/device/lib/_mulint.c  : new, with assember functions
13210
13211         * src/device/lib/_mullong.c : new, with assember functions
13212
13213         * src/device/lib/_divuint.c : with assember functions
13214
13215         * src/device/lib/_divsint.c : with assember functions
13216
13217         * src/device/lib/_divulong.c: with assember functions
13218
13219         * src/device/lib/_divslong.c: with assember functions
13220
13221         * src/device/lib/_moduint.c : with assember functions
13222
13223         * src/device/lib/_modsint.c : with assember functions
13224
13225         * src/device/lib/_modulong.c: with assember functions
13226
13227         * src/device/lib/_modslong.c: with assember functions
13228
13229         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
13230
13231         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
13232
13233         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
13234                                       replaced _mululong.c and _mulslong.c by _mullong.c
13235
13236 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
13237
13238         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
13239
13240 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
13241
13242         * src/SDCCglue.c: test, if win32api is available for MINGW
13243
13244 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
13245
13246         * src/SDCCsymt.c: no more _modifier in printTypeChain()
13247         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
13248         * support/regression/ports/gbz80/spec.mk: removed GENERIC
13249         * support/regression/ports/host/spec.mk: removed GENERIC
13250         * support/regression/ports/mcs51/spec.mk: removed GENERIC
13251         * support/regression/ports/z80/spec.mk: removed GENERIC
13252
13253 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
13254
13255         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
13256
13257         * support/regression/tests/bug-467035.c: Created.
13258
13259 2001-10-01    <johan AT FRIJA>
13260
13261         * src/SDCC.y: fixed bug #466586 part 1
13262
13263 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
13264
13265         * SDCCicode.c: z80 has no generic pointers
13266         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
13267
13268 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
13269
13270         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
13271
13272 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
13273
13274         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
13275
13276         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
13277
13278 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
13279
13280         * configure.in: Fixed up so that ucsim is only configured once.
13281
13282         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
13283
13284         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
13285         (getPathDifference): As above.
13286
13287         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
13288
13289         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
13290
13291 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
13292         * .version: Updated to 2.3.1
13293
13294         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
13295         Added copyright header.
13296
13297         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
13298         (assemble): Added support for macro based assembler commands.
13299         (linkEdit): Added support for macro based linker commands.
13300         (preProcess): Changed the pre-processor to use macros.
13301         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
13302         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
13303
13304         * device/lib/z80/crt0.s: Added module name for debugging.
13305
13306 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
13307
13308         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
13309
13310         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
13311
13312         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
13313
13314         * src/Makefile.in: Added SDCCmacro and SDCCutil
13315
13316 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
13317
13318         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
13319
13320 2001-09-16    <johan AT FRIJA>
13321
13322         * 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.
13323
13324 2001-09-15    <johan AT FRIJA>
13325
13326         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
13327         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
13328
13329 2001-09-11    <johan AT FRIJA>
13330
13331         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
13332
13333 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
13334
13335         * support/regression/tests/bug-460444.c: Added test case.
13336
13337         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
13338         (genCast): Added justification for all of the asserts.
13339
13340 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
13341
13342         * support/regression/support.c: _xdata replaced by xdata
13343
13344         * support/regression/spec.mk: removed _generic
13345
13346 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
13347
13348         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
13349
13350         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
13351         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
13352
13353         * src/z80/peeph.def: Added a rule to optimise shift then compare.
13354
13355         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
13356
13357         * support/regression/tests/bug-460010.c: Added test case.
13358
13359         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
13360
13361 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
13362
13363         * support/regression/Makefile: inter-port-clean adjusted for mcs51
13364
13365         * support/regression/testfwk.c: removed workaround for bug #436344
13366
13367         * support/regression/tests/bp.c: use less memory with mcs51
13368
13369         * support/regression/tests/bug-441448.c: use less memory
13370
13371         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
13372
13373         * support/regression/collate-results.py: typo
13374
13375 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
13376
13377         * support/regression/tests/fetchoverlap.c: Added new test case.
13378
13379         * support/regression/tests/bp.c: Added new test case.
13380
13381         * support/regression/tests/bug-448984.c: Added new test case.
13382
13383         * support/regression/tests/pow2shifts.c: Added new test case.
13384
13385         * src/z80/gen.c: Turned off the noise it normally generates for the release.
13386         (genlshTwo): Fixed right shift for count > 8.
13387
13388         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
13389
13390 2001-09-08    <johan AT FRIJA>
13391
13392         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
13393
13394 2001-09-07    <johan AT FRIJA>
13395
13396         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
13397
13398         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
13399
13400 2001-09-06    <johan AT FRIJA>
13401
13402         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
13403         * bernhard noted me at this: "() equals to (void)" (1.38)
13404
13405 2001-09-05    <johan AT FRIJA>
13406
13407         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
13408
13409 2001-09-04    <johan AT FRIJA>
13410
13411         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
13412
13413
13414 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
13415
13416         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
13417
13418 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
13419
13420         * link/z80/aslink.h: Fixed path for PATH_MAX
13421
13422 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
13423
13424         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
13425
13426         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
13427
13428         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
13429
13430         * 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.
13431
13432 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
13433
13434         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
13435         (genCmp): Fixed up genCmp for the GB with longs.
13436
13437         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
13438
13439         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
13440
13441         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
13442
13443         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
13444
13445 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
13446
13447         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
13448
13449 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
13450
13451         * 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.
13452
13453         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
13454
13455 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
13456
13457         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
13458
13459         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
13460
13461 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
13462
13463   * sim/ucsim/configure:    little improvement of Cygwin-detection
13464   * sim/ucsim/configure.in: little improvement of Cygwin-detection
13465   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
13466   * support/regression/tests/bug-221100.c: small changes for mcs51
13467   * support/regression/tests/bug-221168.c: small changes for mcs51
13468   * support/regression/tests/bug-227710.c: small changes for mcs51
13469   * support/regression/tests/staticinit.c: small changes for mcs51
13470   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
13471   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
13472   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
13473
13474 $Revision$