* device/lib/printf_large.c (output_digit, calculate_digit): optimized,
[fw/sdcc] / ChangeLog
1 2006-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
4           (_print_format): fixed printing pointers
5         * src/mcs51/peeph.def: added rule 140
6         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
7           so they may get optimized into registers
8
9 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
10
11         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
12           immediately when encountered,
13           (printUsage): always use stderr even on windows
14
15 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
16
17         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
18         (processParms): fixed bug #1247551
19         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
20         parseCmdLine, main): print '--version' to stdout,
21         print 'help' to stdout if --help is given,
22         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
23         arguments are given; fixed --help
24
25 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
26
27         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
28         * support/regression/tests/bug-1493710.c: added
29
30 2006-05-27 Borut Razem <borut.razem AT siol.net>
31
32         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
33           static instead auto
34         * support/regression/ports/pic16/support.c: increase stack size
35           from default 64 bytes to 128 bytes
36         * support/regression/tests/staticinit.c,
37           support/regression/tests/float.c: regression tests fully enabled
38           for pic16 port by putting the initialized data arrays into the code
39           section
40         * support/regression/ports/pic16/spec.mk: don't link default libraries.
41           This was changed by mistake in the previous version.
42
43 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
44
45         * src/pic16/gen.c (genFunction, genEndFunction): some
46         beautifications, fixed bug with falsely restoring FSR2 in large
47         stack model, thanks to Beau E. Cox for reporting the bug
48
49 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
50
51         * debugger/mcs51/break.c,
52         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
53           use %p to print pointers, made address variables unsigned
54         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
55         * debugger/mcs51/symtab.c (parseSymbol): must return something
56         * src/mcs51/gen.c (aopForSym): small optimization,
57            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
58           (freeAsmop): added missing break,
59           (aopPut): removed parameter bvolatile, determine it inside the function,
60           (saveRegisters, unsaveRegisters): small optimization,
61           (genIpush): removed pointless check,
62           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
63           replaced sprintf with SNPRINTF,
64           replaced strcpy with strncpyz,
65           updated aopPut calls,
66           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
67         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
68
69 2006-05-24 Borut Razem <borut.razem AT siol.net>
70
71         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
72           modification of test for the pic16 port, put the array to the code
73           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
74
75 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
76
77         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
78         * support/Util/pstdint.h: added
79
80 2006-05-22 Borut Razem <borut.razem AT siol.net>
81
82         * src/regression/Makefile: removed bool2.c test, added -q linker option
83         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
84           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
85           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
86           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
87           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
88           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
89           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
90           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
91           define SUPPORT_BIT_TYPES 0, removed unused bit variables
92
93 2006-05-22 Raphael Neider <rneider AT web.de>
94
95         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
96           bug #1492360 (problematic due to generic pointers, see code)
97
98 2006-05-22 Borut Razem <borut.razem AT siol.net>
99
100         * support/regression/ports/pic16/specs.mk: removed stack size linker
101           directive
102         * support/regression/tests/array.c,
103           support/regression/tests/bitopcse.c,
104           support/regression/tests/bug-908454.c,
105           support/regression/tests/malloc.c: modified for pic16 regression test
106         * support/regression/tests/bitfields.c:
107           pic16 - excluded bitfileds of size > 8
108         * support/regression/tests/bp.c: pic16 - reduced data size
109         * support/regression/tests/bug-221100.c: pic16 - reduced data size
110         * support/regression/tests/bug-460010.c:
111           pic16 - used the absolute address the fits in memory
112         * support/regression/tests/bug-716242.c:
113           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
114         * support/regression/tests/float.c:
115           pic16 - excluded - data size too big
116         * support/regression/tests/onebyte.c:
117           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
118         * support/regression/tests/shifts.c:
119           pic16 - function names probably have to differ in first X characters
120           (gpasm limitation?)
121         * support/regression/tests/staticinit.c:
122           pic16 - excluded some tests due error: no target memory available for
123           section ".idata"
124
125 2006-05-22 Borut Razem <borut.razem AT siol.net>
126
127         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
128           second try. Thanks Stas Sergeev once more.
129
130 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
131
132         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
133           (genLeftShift, genRightShift): fixed bug 1491627
134         * src/hc08/peeph.def (rules 7, 8.x): added
135         * support/regression/tests/shifts.c (ShiftLeftByParam,
136           ShiftRightByParam, testShiftByParam): added to test variable shifting
137
138 2006-05-20 Raphael Neider <rneider AT web.de>
139
140         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
141         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
142           (allocReg): add only new registers to dynAllocRegs,
143           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
144             #1489055, #1445850, and probably #1483693
145
146 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
147
148         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
149         bug in for-loop that didn't emit the last of CONFIG and ID registers
150
151 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
152
153         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
154           with offset
155         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
156           1489016, 1434401 and 1490124
157         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
158           1489016, 1434401 and 1490124
159
160 2006-05-17 Borut Razem <borut.razem AT siol.net>
161
162         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
163           thanks Stas Sergeev
164
165 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
166
167         * device/include/mcs51/P89c51RD2.h,
168         * device/include/mcs51/P89LPC901.h,
169         * device/include/mcs51/P89LPC922.h,
170         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
171
172 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
173
174         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
175         to fix missing stack pragma in compiled binary object file,
176
177 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
178
179         * support/packihx/configure.in,
180         * support/packihx/configure: removed warning, autoconf >= 2.5x can
181         determine sizeof basic types even while cross compiling
182
183 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
184
185         * src/avr/gen.c (aopop),
186         * src/ds390/gen.c (aopOp),
187         * src/hc08/gen.c (aopOp),
188         * src/mcs51/gen.c (aopop),
189         * src/pic16/gen.c (pic16_aopOp),
190         * src/pic/gen.c (aopOp),
191         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
192         if size of operand is smaller than spill location
193
194 2006-05-12 Borut Razem <borut.razem AT siol.net>
195
196         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
197           have to have CR/LF line endings even if they are checked out on *nix
198           or on WIN32 in cygwin binmode
199
200 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
201
202         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
203         * device/include/ds80c390.h: added sfr16 definitions
204         * src/ds390/gen.c,
205         * src/ds390/gen.h,
206         * src/ds390/main.c,
207         * src/ds390/ralloc.c,
208         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
209           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
210           bit returning functions
211         * support/regression/tests/sfr16.c: enabled test on ds390
212
213 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
214
215         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
216         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
217
218 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
219
220         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
221         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
222           (cl_address_space constructor): removed expensive initialization,
223           (cl_address_space::get_cell): extended for late initialization,
224           (cl_address_space::*): use late initialization,
225           (cl_address_decoder::activate): removed expensive initialization,
226           This reduced regression test running time by 25%
227
228 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
229
230         * packihx/,
231         * configure.in,
232         * configure,
233         * sdcc.dsw,
234         * Makefile.bcc,
235         * Makefile.in,
236         * support/packihx/Makefile.in,
237         * support/packihx/clean.mk,
238         * support/packihx/Makefile.bcc,
239         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
240
241 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
242
243         * src/SDCCval.c (valNot): fix for regression test failure
244           of not.c on big endian hosts
245
246 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
247
248         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
249
250 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
251
252         * device/lib/mcs51/Makefile.in: changed string comparison operator
253           to = for POSIX compliance; == is bash extension
254
255 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
256
257         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
258           kosmonaut_pirx
259
260 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
261
262         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
263         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
264         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
265         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
266         bug report #1478657,
267
268 2006-05-05 Borut Razem <borut.razem AT siol.net>
269
270         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
271           making the html
272
273 2006-05-02 Borut Razem <borut.razem AT siol.net>
274
275         * doc/Makefile.in: removed *.ind dependency since there is no rule to
276           create *.ind, which made make to fail if invoked with -j 2
277
278 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
279
280         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
281           Hubert Sack for patch 1479782
282
283 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
284
285         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
286
287 2006-05-01 Raphael Neider <rneider AT web.de>
288
289         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
290           (create_pic): store only prefix-free device name,
291           (init_pic): check for device names with "16" prefix,
292           (list_valid_pics),
293         * src/pic/device.h (struct PIC_device),
294         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
295             stored device name,
296         * device/include/pic/pic12f{635,675,629,683}.h,
297         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
298         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
299         * device/include/pic/pic16f505.h,
300         * device/lib/pic/libdev/pic16f505.c: removed
301         * device/include/pic/pic14devices.txt: added support for pic12f
302             devices, removed unsupported non 16-bit devices
303             [above changes provided by patch from Zik Saleeba]
304         * src/pic/*, src/pic16/*, device/include/pic16/*,
305           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
306
307 2006-05-01 Borut Razem <borut.razem AT siol.net>
308
309         * configure.in, configure, doc/Makefile.in:
310           sync with nightly build makefile - latex, dvipdf and dvips
311           not needed any more
312
313 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
314
315         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
316         in the library source
317
318 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
319
320         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
321
322 2006-04-28 Raphael Neider <rneider AT web.de>
323
324         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
325         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
326           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
327         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
328
329 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
330
331         * device/lib/pic/libdev/Makefile.in,
332         * device/lib/hc08/Makefile.in,
333         * device/lib/gbz80/Makefile.in,
334         * device/lib/z80/Makefile.in,
335         * device/lib/ds390/Makefile.in,
336         * device/lib/ds400/Makefile.in: added srcdir to include search path,
337         thanks to Borut for the bug report
338         * configure.in,
339         * configure: always create doc/Makefile independent from --enable-doc
340         * Makefile.in: always install from directory doc independent from
341         --enable-doc
342         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
343         removed
344         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
345         * doc/Makefile.in: install *.txt if present
346         * device/include/Makefile.in (install): added installation of pic/*.inc
347         and pic/*.txt files again, they were erroneously removed
348
349 2006-04-28 Raphael Neider <rneider AT web.de>
350
351         * src/pic/{gen.c,main.h,pcode.c},
352         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
353             concerning signedness with casts
354
355 2006-04-28 Raphael Neider <rneider AT web.de>
356
357         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
358             definition of an interrupt handler,
359         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
360             interrupt handler stuff from picglue() to separate routine,
361           (picglue): enabled definition of intr handlers in files w/o main()
362
363 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
364
365         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
366           compilation with MSVC 2005 Express Edition (VC8)
367
368 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
369
370         * device/lib/Makefile: fixed build of gbz80 lib
371
372 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
373
374         * support/regression/tests/bug-460010.c,
375         * support/regression/tests/bug-524691.c,
376         * support/regression/tests/bug-716242.c: removed conditional defines
377           that are already in testfwk.h
378
379 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
380
381         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
382           (AccAXRsh1): added, shift right by 1,
383           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
384            AccAXLrl1
385         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
386
387 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
388
389         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
390         remove cast to same type
391         * src/SDCCast.c (decorateType): fix for RFE 1475742,
392         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
393         * as/z80/Makefile,
394         * link/z80/Makefile: removed, they have moved to
395         Makefile.in files
396         * configure,
397         * configure.in: replaced duplicate message about ucsim by missing sdcpp
398         * install-sh: fix bug #1204398 by setting umask 0022
399         * device/lib/Makefile: separate build of z80 and gbz80 lib
400
401 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
402
403         Enabled VPATH feature: changed nearly all Makefiles (149 files).
404         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
405
406         One basic decision: e.g. src/clean.mk includes further files. In order
407         to make this work there are two solutions:
408         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
409           run configure on them. This way they can use
410           'include $(srcdir)/port-clean.mk'
411         - always include clean.mk by the Makefile at the same level. To avoid
412           that `make clean` tries to include and build Makefile.dep the
413           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
414           implemented, because now even `make uninstall` doesn't create
415           Makefile.in. clean.mk could be eliminated by pasting it in
416           Makefile.in.
417
418         * debugger/mcs51/Makefile.in: build own objects from library sources
419         (SLIB, SDCC) in current directory
420
421         * configure, configure.in: renamed --disable-device-lib-build in
422         --disable-device-lib; added --enable-doc, the required tools are
423         searched by configure; added result message; the toolchain for the
424         belonging ports are now only built, if the port is enabled.
425
426         * support/regression/*: all output is written in directory gen, because
427         the fwk and ports directories don't livet in the build tree using vpath
428
429         * doc/sdccman.lyx: renamed --disable-device-lib-build to
430         --disable-device-lib, added --enable-doc, added section VPATH
431
432         * sim/ucsim/configure.in,
433         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
434         z80 are enabled by default
435
436 2006-04-24 Raphael Neider <rneider AT web.de>
437
438         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
439             to config word, "pic14_"-prefixed some extern functions
440           (pic14_emitConfigWord): emit __config directive(s) if assignment to
441             config word has been found
442         * src/pic/device.h: added prototypes
443         * src/pic/pcode.c: added "pic14_"-prefix where needed
444         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
445             fixup
446         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
447             words,
448           (pic14emitRegularMap): ignore config words,
449           (pic14createInterruptVect): moved generating __config directives away
450           (picglue): have __config directives emitted
451
452 2006-04-24 Borut Razem <borut.razem AT siol.net>
453
454         * doc/Makefile: sync with nightly build makefile
455
456 2006-04-24 Raphael Neider <rneider AT web.de>
457
458         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
459             registers that have not been assigned proper liveranges,
460             fixes #1469504 and #1474602,
461           (pCodeRegOptimizeRegUsage): fixed typo in comment
462
463 2006-04-24 Borut Razem <borut.razem AT siol.net>
464
465         * device/examples/main8051.c: deleted - it was removed from CVS
466           24.mar.2000 and after that modified 18.feb.2001, so it reappered
467           after the transition to Subversion
468         * src/SDCCalloc.h: deleted - it was removed  from CVS
469           3.feb.2001 and after that modified 18.feb.2001, so it reappered
470           after the transition to Subversion
471         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
472           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
473           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
474           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
475
476 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
477
478         * as/asx8051.dsp: added mcs51/strcmpi.h
479         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
480         * as/hc08/aslink.h: updated lnksect prototype
481         * as/hc08/asm.h,
482         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
483         * as/hc08/asmain.c,
484         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
485           (newdot): handle A_ABS
486         * as/hc08/asout.c,
487         * as/mcs51/asout.c (outarea): output address
488         * as/hc08/lkaomf51.c,
489         * as/mcs51/lkaomf51.c: disabled unused array UsageType
490         * as/hc08/m08pst.c,
491         * as/mcs51/i51pst.c,
492         * as/z80/z80pst.c: "ABS" is not A_OVR
493         * as/hc08/lkarea.c (newarea): read a_addr,
494           (lnkarea): added codemap array, sort absolute areas to the front,
495            combine all GSINITx/GSFINAL,
496           (find_empty_space, allocate_space): new functions,
497           (lnksect): return next address, handle absolute sections
498         * as/mcs51/lkarea.c (newarea): read a_addr,
499           lnksect2 prototype changed,
500           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
501           (find_empty_space, allocate_space): new, factored out of lnksect2,
502           (lnksect2): return next address, handle absolute sections
503         * as/hc08/lkhead.c,
504         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
505         * as/hc08/lklibr.c (addfile, fndsym),
506         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
507           index out of range and detect both '\' and '/'
508         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
509         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
510           regression tests (ds390 cannot return bool yet)
511         * doc/sdccman.lyx: changed version number, document changed --no-peep,
512           document critical interrupts on z80, document changed SDCC define
513         * src/asm.c (_asxxxx_mapping): fixed .org directive,
514           (_a390_mapping): added .org directive
515         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
516           (genMultOneByte): fixed warnings
517         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
518           ones
519         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
520         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
521           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
522         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
523         * src/pic16/main.c: removed newReg prototype
524         * src/pic16/pcode.c,
525         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
526           warnings
527         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
528           ones
529         * src/pic16/ralloc.c
530         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
531           to fix warnings
532         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
533           from short to PIC_OPTYPE
534         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
535         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
536           optype from short to PIC_OPTYPE
537         * src/port.h: made int_size unsigned to fix warnings
538         * src/SDCC.y: fixed warning on MSVC
539         * src/SDCCicode.c (getArraySizePtr): return unsigned int
540         * src/SDCCopt.c (convertToFcall): fixed warnings
541         * src/SDCCsymt.h: removed double prototype for genSymName
542         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
543           offset int to fix warnings
544
545 2006-04-22 Borut Razem <borut.razem AT siol.net>
546
547         * doc/sdccman.lyx, */Makefile, */Makefile.in:
548           references to CVS replaced with Subversion
549
550 2006-04-21 Borut Razem <borut.razem AT siol.net>
551
552         * doc/sdccman.lyx, */Makefile, */Makefile.in:
553           references to CVS replaced with Subversion
554
555 2006-04-19 Borut Razem <borut.razem AT siol.net>
556
557         * src/version.awk: adapted for svn
558         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
559           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
560           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
561           /binutils-avr/etc/*.vi, *.jin: removed all properties
562           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
563
564 2006-04-19 Borut Razem <borut.razem AT siol.net>
565
566         * CVS to Subversion migration completed
567
568 2006-04-18 Borut Razem <borut.razem AT siol.net>
569
570         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
571           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
572
573 2006-04-17 Borut Razem <borut.razem AT siol.net>
574
575         * device/include/Makefile.in: added pic/*.inc to the installation
576
577 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
578
579         * support/regression/collate-results.py: fixed output in case of
580         a valdiag error
581         * support/regression/generate-cases.py: fixed splitting of pathnames
582         with dots
583         * as/hc08/lklibr.c (addfile),
584         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
585
586 2006-04-11 Raphael Neider <rneider AT web.de>
587
588         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
589         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
590         * src/pic16/pcode.c (assignValnums): fixed #1460578
591
592 2006-04-11 Raphael Neider <rneider AT web.de>
593
594         * device/lib/pic/libdev/*.c,
595         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
596           fixes #1468739, enables compilation in --std-c99 mode
597         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
598
599 2006-04-11 Raphael Neider <rneider AT web.de>
600
601         * src/pic/device.c (find_device): removed debug output
602           (list_valid_pics): enabled verbose listing of supported devices
603         * device/include/stdbool.h: define bool as char for pic14/16 as well
604
605 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
606
607         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
608
609 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
610
611         * .version: bumped version to 2.5.6
612         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
613
614 2006-04-06 Raphael Neider <rneider AT web.de>
615
616         * .version: bumped version to 2.5.6 (pic14 ABI changed)
617         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
618         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
619           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
620             pic14_constructAbsMap
621           (pic14printPublics): declare absolute global symbols as global
622           (pic14createInterruptVect),
623         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
624           (newReg): assume new registers unused, use correct name in
625             hashtable (reg->name instead of name), more debugLog output
626         * src/pic/device.h (PIC_device): added fields for verbose output
627         * src/pic/device.c: moved device definition to pic14devices.txt,
628             added routines for runtime parsing of pic14devices.txt,
629             added support for second config word
630         * src/pic/main.c (_process_pragma): removed #pragma maxram,
631           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
632           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
633           (_pic14_parseOptions): moved pCodeInitRegisters here
634           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
635         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
636           (pCodeInitRegisters): rewrapped comments, perpared new approach to
637             handling the pseudo stack
638         * device/lib/Makefile.in: ignore failures in objects-pic16,
639         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
640         * device/lib/pic/NEWS: document new dependency on picXXX.lib
641         * device/lib/pic/Makefile.subdir,
642         * device/lib/pic16/Makefile.subdir: improved clean rules
643         * device/lib/pic/libdev/: NEW, pic14 device libraries
644         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
645         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
646         * device/include/Makefile.in: create subdir and install pic14 headers
647         * device/include/pic/p16f_common.inc: removed unused declarations
648         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
649             PICs from inc2h.pl v1.6,
650             replaced BIT_AT macros with struct declarations
651         * device/include/pic/pic14devices.txt: definition of supported devices,
652             all above improvements contributed by Zik Saleeba, thanks
653         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
654         * support/scripts/sdcc.nsi: also install pic14 device libraries and
655             headers
656
657 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
658
659         * device/include/mcs51/c8051f410.h: added interrupt numbers,
660         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
661           thanks to Charles Olds
662
663 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
664
665         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
666
667 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
668
669         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
670         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
671         * support/regression/bug1464657.c: added, new test
672
673 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
674
675         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
676           version number
677
678 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
679
680         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
681           --no-peep and --peep-file <file> are used don't use default rules but
682           do use the <file>
683
684 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
685
686         * src/mcs51/gen.c (genCall): fixed bug 1457608
687
688 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
689
690         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
691         changes seem to cause (trigger?) problems with the build system.
692
693 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
694
695         * src/SDCCpeeph.c (operandsLiteral): new, added,
696           (callFuncByName): inserted operandsLiteral
697         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
698
699 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
700
701         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
702         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
703
704 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
705
706         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
707           implemented patch 1120823 Thanks to Willy De la Court (normal
708           interrupts need an interrupt number now if they are made critical),
709           and enabled nesting of critical functions though not for gbz80
710           (genCritical, genEndCritical): added functions
711           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
712         * src/z80/mappings.i: added "ei" to all mappings
713
714 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
715
716         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
717         submitted by the Debian SDCC maintainer Aurelien Jarno:
718         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
719         archive with gcc 4.1 on mips and wrote the patch"
720
721 2006-03-16 Raphael Neider <rneider AT web.de>
722
723         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
724           the left operand is shorter than the result (c* = lit-c* + int),
725           fixes bug #1450796
726         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
727           OP_SYMBOL
728
729 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
730
731         * src/.version: increased version number to 2.5.5
732         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
733         linking is done manually in pic16 port's _linkEdit,
734         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
735         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
736         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
737         allocate asmop as AOP_ACC,
738         (aopForRemat): added parameter 'bool result' in function declaration,
739         (pic16_aopGet): return AOP_ACC when accessing WREG,
740         (pic16_popGetTempReg): minor modification,
741         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
742         'pic16_allocWithIdx',
743         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
744         calling function in absolute addresses,
745         (genAssign): take into account AOP_ACC asmop,
746         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
747         * src/pic16/pcoderegs.c: some debug functions and lines added,
748         * src/pic16/ralloc.c (decodeRegType): added but commented out,
749         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
750         register too,
751         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
752         call to allocReg, not by manually allocating a new one,
753         (pic16_assignRegisters): now before going through the register
754         allocating functions mark all registers as free. This eliminates some
755         side effects resulting from peephole parser done earlier in the backbone
756
757 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
758
759         * src/SDCCicode.c (geniCodeLogic),
760         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
761
762 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
763
764         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
765           (genSend): bugfix, do not allocate and free twice,
766           (shiftRLong): handle partially overlapping aops
767         * support/regression/tests/bitopcse.c: fixed warning redefined idata
768
769 2006-03-08 Borut Razem <borut.razem AT siol.net>
770
771         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
772           for pic16
773
774 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
775
776         * support/regression/tests/bug1409955.c: new, added
777         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
778         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
779           (aopForSym, aopOp): increment asmop.allocated if reused,
780           (freeAsmop): decrement asmop.allocated and check for zero instead of
781           using asmop.freed,
782           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
783           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
784            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
785            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
786            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
787            genSignedRightShift, genRightShift, genDataPointerGet,
788            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
789            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
790             in reverse order from allocation,
791           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
792             added swappedLR to keep track
793         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
794           pdata & code for GCC, z80, gbz80 & hc08
795         * support/regression/tests/zeropad.c: moved defines to testfwk.h
796
797 2006-03-08 Raphael Neider <rneider AT web.de>
798
799         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
800
801 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
802
803         * device/include/mcs51/c8051f410.h: new SiLabs mcu
804         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
805         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
806
807 2006-03-06 Borut Razem <borut.razem AT siol.net>
808
809         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
810           made the linker quiet
811
812 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
813
814         * src/pic16/gen.c (genPcall): fixed bug #1443644
815         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
816         which dumps before the function entry point a data byte which represents
817         the number of the local variables used by the specified function, added
818         'xinst' for initial support for Extended Instruction Support,
819         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
820         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
821         port->fun_prefix anymore (may change later),
822         (genFunction, genEndFunction): do not store/restore local registers for
823         _main (this should take care the --main-return command line option in
824         the future),
825         (genOr): removed some legacy pic-port instructions,
826         * src/pic16/genarith.c (genAddLit): re-enabled old code because
827         performing operations with SFR's causes data to be written more than
828         once to each SFR. Perhaps SFRs should be handled in special cases...
829         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
830         pcode.h
831         * src/pic16/main.c (_process_pragma): stack bound checking did not take
832         into account for stack starting position,
833         (struct OPTIONS pic16_optionsTable): added command line argument
834         --extended or -y for Extended Instruction Support,
835         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
836         (deassignLRs): *** perhaps the most important change, old 'for' code
837         (commented out for reference), didn't account for some registers which
838         were left marked 'not free' after a pointer operation. The change
839         reduces register usage a lot in some cases
840
841 2006-03-04 Borut Razem <borut.razem AT siol.net>
842
843         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
844           _clean
845         * support/regression/tests/bug-524697.c: decreased array size for
846           mcs51 to fit into the internal RAM
847         * support/regression/Makefile.in: a little bit more verbose
848
849 2006-03-03 Borut Razem <borut.razem AT siol.net>
850
851         * support/regression/fwk/lib/testfwk.c,
852           support/regression/fwk/include/testfwk.h: introduced function
853           _prints(), nonrecursive _printn(), call _initEmu() from main()
854         * support/regression/ports/gbz80/support.asm,
855           support/regression/ports/ucz80/support.asm,
856           support/regression/ports/z80/support.asm,
857           support/regression/ports/ds390/support.c,
858           support/regression/ports/hc08/support.c,
859           support/regression/ports/host/support.c,
860           support/regression/ports/mcs51/support.c,
861           support/regression/ports/xa51/support.c: added empty _initEmu()
862           function
863         * support/regression/ports/pic16/gpsim.cmd,
864           support/regression/ports/pic16/spec.mk,
865           support/regression/ports/pic16/support.c,
866           support/regression/Makefile.in: added pic16 regression test
867
868 2006-03-01 Raphael Neider <rneider AT web.de>
869
870         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
871           genConstPointerGet): use safe way of generating MOVFF to cover
872             literals as well as registers, fixes bug #1440527
873         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
874             dereference
875           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
876             more correctly, fixes bug #1232186
877           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
878         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
879             gplink guess the correct processor in more cases, applied patch
880             from Till Riedel attached to and fixing bug #1436552
881
882 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
883
884         * support/regression/tests/array.c: added, contains check for #1434401
885         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
886
887 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
888
889         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
890         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
891         * device/include/mcs51/c8051f326.h,
892         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
893         * device/include/mcs51/c8051f000.h,
894         * device/include/mcs51/c8051f018.h,
895         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
896           PCON_IDLE,PCON_STOP and added sfr16 definitions
897
898 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
899
900         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
901           genGetWord): fixed bug 1409955
902
903 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
904
905         * device/include/hc08/mc68hc908gp32.h,
906         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
907
908 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
909
910         * src/SDCCast.c (constExprValue): return NULL if not a value
911         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
912         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
913         * support/regression/tests/bitfields.c: enabled signed bitfield for all
914
915 2006-02-13 Borut Razem <borut.razem AT siol.net>
916
917         * src/regression/ptrarg.c: added, fails due to bug #1430967
918         * src/regression/Makefile: ptrarg.c added, ...
919
920 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
921
922         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
923         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
924
925 2006-02-11 Borut Razem <borut.razem AT siol.net>
926
927         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
928           print "Processor: xxx" message to stdout only if --verbose
929
930 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
931
932         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
933         * support/regression/tests/bug1426356.c: added
934         * support/regression/tests/bitfields.c: removed 2 tests
935
936 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
937
938         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
939         * device/include/mcs51/c8051f330.h,
940         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
941           PCON_IDLE,PCON_STOP and added sfr16 definitions
942         * device/lib/_divsint.c,
943         * device/lib/_divuint.c,
944         * device/lib/_divulong.c,
945         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
946           register bank bug for small stackauto
947
948 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
949
950         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
951
952 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
953
954         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
955         * all.dsp: corrected several bin paths
956         * device/include/mcs51/c8051f120.h,
957         * device/include/mcs51/c8051f300.h,
958         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
959           to PCON_IDLE,PCON_STOP
960         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
961         * device/lib/printf_large.c (output_float): fixed bug 1388703
962         * support/regression/tests/bug1057979.c: added test for bug 1388703
963
964 2006-02-08 Raphael Neider <rneider AT web.de>
965
966         * src/pic/pcode.c (pciTRIS): fixed typo,
967           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
968           (LinkFlow): fixed handling of flows that end in a call,
969           (ReuseReg): perform safety check earlier
970         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
971             to work with flows at the beginning of a pBlock,
972             fixes #1426557 (Symbol not previously defined),
973           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
974             usage information
975           (RemoveUnusedRegisters): update register usage info
976         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
977             created, reuse existing ones instead
978         * src/pic/gen.c (genPcall): fixed #1424719
979
980 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
981
982         * link/z80/lkmain.c,
983         * link/z80/lklex.c,
984         * link/z80/lkdata.c,
985         * link/z80/aslink.h: fixed build on current cygwin:
986         replaced getline() by lk_getline()
987
988 2006-02-01 Borut Razem <borut.razem AT siol.net>
989
990         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
991           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
992           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
993           src/regression/bool1.c, src/regression/bool2.c,
994           src/regression/bool3.c, src/regression/call1.c,
995           src/regression/compare.c, src/regression/compare10.c,
996           src/regression/compare2.c, src/regression/compare3.c,
997           src/regression/compare4.c, src/regression/compare5.c,
998           src/regression/compare6.c, src/regression/compare7.c,
999           src/regression/compare8.c, src/regression/compare9.c,
1000           src/regression/configword.c, src/regression/for.c,
1001           src/regression/inline.c, src/regression/mult1.c,
1002           src/regression/nestfor.c, src/regression/or1.c,
1003           src/regression/pointer1.c, src/regression/ptrfunc.c,
1004           src/regression/rotate1.c, src/regression/rotate2.c,
1005           src/regression/rotate3.c, src/regression/rotate4.c,
1006           src/regression/rotate5.c, src/regression/rotate6.c,
1007           src/regression/rotate7.c, src/regression/string1.c,
1008           src/regression/struct1.c, src/regression/sub.c,
1009           src/regression/sub2.c, src/regression/switch1.c,
1010           src/regression/while.c, src/regression/xor.c,
1011           src/regression/create_stc, src/regression/simulate,
1012           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1013           regression tests
1014         * src/regression/gpsim_assert.h: added
1015
1016 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1017
1018         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1019         ((void (code *) (void)) 0) ();
1020         * as/hc08/aslex.c,
1021         * as/hc08/aslink.h,
1022         * as/hc08/asm.h,
1023         * as/hc08/asmain.c,
1024         * as/hc08/lkdata.c,
1025         * as/hc08/lklex.c,
1026         * as/hc08/lkmain.c,
1027         * as/mcs51/aslex.c,
1028         * as/mcs51/aslink.h,
1029         * as/mcs51/asm.h,
1030         * as/mcs51/asmain.c,
1031         * as/mcs51/lkdata.c,
1032         * as/mcs51/lklex.c,
1033         * as/mcs51/lkmain.c,
1034         * as/z80/aslex.c,
1035         * as/z80/asm.h,
1036         * as/z80/asmain.c: fixed build on current cygwin:
1037         replaced getline() by as_getline()
1038
1039 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1040
1041         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1042         declarator in the symbol chain
1043         * src/SDCCsymt.h,
1044         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1045         parameter list for function pointers
1046         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1047         * support/regression/tests/bug-716242.c: added
1048
1049 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1050
1051         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1052         offset if possible
1053         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1054
1055 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1056
1057         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1058         inifinitely recurseable, added static
1059         * support/regression/tests/bug-1408066.c: added
1060
1061 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1062
1063         * src/SDCCicode.h,
1064         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1065         renamed, added possibility to create "postLoopLbl"-labels
1066         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1067         newiTempLoopHeaderLabel
1068         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1069         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1070         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1071         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1072         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1073         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1074         (basicInduction): fixed bug #136564, made static,
1075         (loopInduction): changed parameter of basicInduction, made static,
1076         (addPostLoopBlock): added
1077         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1078         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1079         findLoopEndSeq
1080         * support/regression/tests/bug-136564.c: added
1081         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1082         --std-sdcc99 to LIBSDCCFLAGS
1083
1084 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1085
1086         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1087         while loop
1088         * support/regression/tests/bug-1406131.c: added
1089
1090 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1091
1092         * src/SDCCast.c (decorateType): fix promotion of unary minus
1093         * src/SDCCsymt.c (computeType): beautified
1094         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1095         (valUnaryPM, valComplement): fix sign and promotion,
1096         (valNot): ANSI: result type is int (SDCC: unsigned char)
1097         * support/regression/tests/uminus.c: speedup by removing superflous
1098         test case 'int'
1099         * support/regression/tests/onebyte.c: added promotion and signedness
1100         tests for unary minus
1101         * support/regressions/tests/bug-477927.c: disable warning about
1102         uninitialized variables
1103         * support/regression/tests/not.c: added
1104
1105 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1106
1107         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1108         * src/mcs51/gen.c (gen51Code): show final register usage after
1109         fillGaps in asm with --i-code-in-asm
1110         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1111         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1112         incUsed, rliveClear, adjustIChain): made static,
1113         (setFromRange): excluded because it's unused,
1114         (findPrevUseSym, markWholeLoop): added,
1115         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1116         through all branches of predecessors enables sdcc to emit the warning
1117         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1118         (rlivePoint): made static, added parameter emitWarnings which is only
1119         true during the first run out of two,
1120         (findRecursiveSucc, findRecursivePred): removed,
1121         (computeLiveRanges): made static, added parameter emitWarnings,
1122         (dumpIcRlive): added for debugging only
1123         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1124         removed prototype of setFromRange()
1125         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1126         in call of computeLiveRanges()
1127         * support/regression/tests/bug-895992.c: added
1128         * support/regression/tests/bug-971834.c: added
1129         * support/valdiag/tests/bug-895992.c: added
1130         * support/valdiag/tests/bug-971834.c: added
1131
1132 2005-12-18 Raphael Neider <rneider AT web.de>
1133
1134         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1135           (genUnpackBits): improved code for direct operands,
1136           (genPackBits): improved code for literal assignment to bitfields
1137             and for direct destination operands (no FSR indirection),
1138             prevented redundant AND, fixes #1362800,
1139           (AccLsh): added parameter to disable masking of the result
1140         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1141           skip instructions with side-effects (like incfsz),
1142           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1143         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1144         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1145           fixes #1375263
1146
1147 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1148
1149         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1150         volatile variables as spill location
1151
1152 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1153
1154         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1155         replacing literals
1156         * support/regression/tests/bug-1376320.c: added
1157
1158 2005-12-08 Raphael Neider <rneider AT web.de>
1159
1160         * src/pic/device.c: renamed is_shared to pic14_is_shared
1161         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1162         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1163           (is_valid_identifier): added for above workaround
1164
1165 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1166
1167         * device/lib/Makefile.in: fixed to enable port-specific-objects
1168         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1169           char, thanks Hubert Sack
1170         * doc/sdccman.lyx: documented --xstack-loc,
1171           elaborated a bit more on interrupts and pitfalls,
1172           removed "setjmp/longjmp unsupported",
1173           documented some unsupported C99 features
1174         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1175         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1176           if, thanks Hubert Sack
1177         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1178         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1179           make make_library
1180         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1181           regression tests can report resource usage (rfe 700441)
1182         * support/regression/collate-results.py: report resource usage
1183         * support/regression/ports/ds390/spec.mk,
1184         * support/regression/ports/hc08/spec.mk,
1185         * support/regression/ports/mcs51/spec.mk,
1186         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1187         * support/regression/ports/ds390/uCsim.cmd,
1188         * support/regression/ports/hc08/uCsim.cmd,
1189         * support/regression/ports/mcs51/uCsim.cmd,
1190         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1191         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1192           library, use the default one
1193         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1194           building the library
1195
1196 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1197
1198         * config.dsp: added dependency on .version and configure_vc.awk
1199         * device/include/setjmp.h: updated for --stack-auto and --xstack
1200         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1201         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1202         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1203         * device/lib/libsdcc.lib: added _setjmp
1204         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1205           (decorateType): fixed bug 1372851,
1206           (optimizeGetHbit): fixed warning
1207         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1208           array initialisation
1209         * support/regression/tests/bug1057979.c: added test for bug 1358192
1210         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1211
1212 2005-12-03 Borut Razem <borut.razem AT siol.net>
1213
1214         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1215           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1216
1217 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1218
1219         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1220         createIval): implement symbol independant "flexible array member",
1221         (createIvalCharPtr): implemented flexible array initialisation with a
1222         string
1223         * src/SDCCsymt.c (copyStruct): removed,
1224         (getSize): fixed misleading comment,
1225         (getAllocSize): removed, the additional allocation size is now in
1226         sym->flexArrayLength,
1227         (checkStructFlexArray): new, syntax checks for flexible array members,
1228         (compStructSize): added syntax checks for "flexible array members"
1229         (copyStruct): removed,
1230         (copyLinkChain): removed inefficient fix for bug 770487
1231         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1232         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1233         symbol->flexArrayLength
1234         * src/SDCCerr.c,
1235         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1236         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1237         * support/regression/tests/structflexarray.c: added
1238         * support/valdiag/tests/structflexiblearray.c: added
1239
1240 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1241
1242         * src/SDCCast.c (decorateType): fixed bug 1368489
1243         * support/Util/SDCCerr.c,
1244         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1245
1246 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1247
1248         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1249           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1250
1251 2005-11-27 Borut Razem <borut.razem AT siol.net>
1252
1253         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1254           support/cpp2/mkdeps.h: added command line option
1255           -obj-ext=<extension> to SDCPP to define object file externion, used
1256           for generation of make dependencies (-M)
1257         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1258
1259 2005-11-26 Borut Razem <borut.razem AT siol.net>
1260
1261         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1262           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1263           added pic and pic16 libraries
1264
1265 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1266
1267         * device/include/float.h: Corrected typo in prototype of __fsgt
1268
1269 2005-11-25 Borut Razem <borut.razem AT siol.net>
1270
1271         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1272           added creation of model-mcs51-stack-auto libraries
1273
1274 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1275
1276         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1277         and fields-list too
1278         * src/SDCCast.c (createIvalArray): removed obsolete comment
1279
1280 2005-11-24 Borut Razem <borut.razem AT siol.net>
1281
1282         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1283           added missing device/lib/mcs51/crt*.asm sources
1284
1285 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1286
1287         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1288
1289 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1290
1291         * device/lib/_fs2schar.c,
1292         * device/lib/_fs2sint.c,
1293         * device/lib/_fs2slong.c: optimized inline asm
1294
1295 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1296
1297         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1298           Better handling of floats between -1.0 and 0.0.
1299
1300 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1301
1302         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1303           (the missing "if"s prohibited removal of redundant labels)
1304
1305 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1306
1307         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1308           Properly convert floats between -1.0 and 0.0 to long, int, and char
1309           types (max integer value of negative floats tends to zero).
1310         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1311           Removed changes made so to work properly with floats between
1312           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1313           and _fs2char.c
1314
1315 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1316
1317         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1318         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1319         (genCast) cosmetic change
1320         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1321         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1322         from mcs51
1323         * support/regression/tests/bitfields (testSignedBitfields): added
1324
1325 2005-11-18 Borut Razem <borut.razem AT siol.net>
1326
1327         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1328         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1329           introduced SILENT option to make building of pic16 libraries less
1330
1331 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1332
1333         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1334           Now they work properly with floats between -1.0 and 0.0
1335         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1336
1337 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1338
1339         * src/SDCCicode.c (printOperand): added missing else
1340
1341 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1342
1343         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1344         reformatted for better readability
1345         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1346         signed bitfields
1347
1348 2005-11-17 Borut Razem <borut.razem AT siol.net>
1349
1350         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1351           introduced SILENT option to make building of pic16 libraries less
1352           verbose - used for nightly snapshot build
1353         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1354           available on Win32 platforms.
1355         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1356           medium, large, pic and pic16
1357
1358 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1359
1360         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1361           printf("%f"...) sets fraction to zero.
1362
1363 2005-11-16 Raphael Neider <rneider AT web.de>
1364
1365         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1366           fixes #1357221
1367         * src/pic/gen.c (genIfx): implemented for CARRY bit
1368         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1369           to generic pointers, fixes #1357332,
1370           (pic16_movLit2f): NEW,
1371           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1372
1373 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1374
1375         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1376
1377 2005-11-11 Raphael Neider <rneider AT web.de>
1378
1379         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1380         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1381           compute pointer's type from operand,
1382           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1383           improved single bit reads, fixes bug #1353379
1384
1385 2005-11-09 Borut Razem <borut.razem AT siol.net>
1386
1387         * support/scripts/sdcc.nsi: added lib/pic to the package
1388
1389 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1390
1391         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1392
1393 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1394
1395         * support/regression/tests/bug1348008.c: added
1396         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1397         * support/regression/tests/bug1337835.c: updated comment
1398
1399 2005-11-06 Borut Razem <borut.razem AT siol.net>
1400
1401         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1402           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1403           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1404           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1405           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1406           dynamic construction of cl_error_class and derivates - 2.nd try
1407
1408 2005-11-05 Borut Razem <borut.razem AT siol.net>
1409
1410         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1411           bug, which caused Bus Errors on sparc solaris
1412
1413 2005-11-04 Borut Razem <borut.razem AT siol.net>
1414
1415         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1416           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1417           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1418           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1419           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1420           and derivates to resolve the initialization problem on OSX
1421
1422 2005-11-02 Borut Razem <borut.razem AT siol.net>
1423
1424         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1425           corrected typo - #include <winsock2.h>
1426
1427 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1428
1429         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1430           (_asxxxx_mapping): added org directive for future enhancements
1431
1432 2005-11-01 Borut Razem <borut.razem AT siol.net>
1433
1434         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1435           enabled sockets on WIN32
1436         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1437
1438 2005-10-31 Borut Razem <borut.razem AT siol.net>
1439
1440         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1441           WIN32 backslash path delimiters should be escaped when used in C strings
1442         * support/regression/tests/bitfields.c: exclude failing assertions for
1443           __CYGWIN32__ and __MINGW32__ hosts
1444
1445 2005-10-30 Borut Razem <borut.razem AT siol.net>
1446
1447         * src/SDCCutil.c: corrected double comparison typo
1448
1449 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1450
1451         * device/lib/medium/Makefile: added for new memory model medium
1452         * device/include/asm/mcs51/features.h: updated for medium/pdata
1453         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1454           added Multiply & Accumulate sbit's and MAC0_PAGE define
1455         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1456         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1457         * device/lib/_mullong.c: update for medium model
1458         * device/lib/incl.mk: added medium model
1459         * doc/sdccman.lyx: documented medium model
1460         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1461         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1462         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1463         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1464           (allocParms): set SCLS and OCLS to pdata for medium model
1465         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1466           for pdata,
1467           (powof2): return <0 if not power of 2
1468         * src/avr/gen.c (genBitWise): use updated powof2
1469         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1470           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1471           (shiftLLeftOrResult): use B if necessary
1472         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1473         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1474         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1475         * support/regression/Makefile.in: added test-mcs51-medium
1476         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1477
1478 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1479
1480         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1481         specifier unsigned
1482         * device/lib/time.c (mktime): fixed bug 1334315
1483
1484 2005-10-28 Raphael Neider <rneider AT web.de>
1485
1486         * device/include/pic/p16f_common.inc: added common declarations
1487         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1488
1489 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1490
1491         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1492           (aopPutUsesAcc): added to predict accumulator use,
1493           (assignResultValue): save acc if necessary,
1494           (genMinusDec): store result if indirectly addressed,
1495           (genDivOneByte):  save acc if necessary,
1496           (movLeft2Result): bugfix if left already in acc,
1497           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1498             attention to accumulator use (esp. pdata),
1499           (genReceive): receive pdata correctly
1500         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1501         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1502
1503 2005-10-27 Raphael Neider <rneider AT web.de>
1504
1505         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1506
1507 2005-10-27 Raphael Neider <rneider AT web.de>
1508
1509         * .version: changed version to 2.5.4
1510         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1511         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1512           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1513             arithmetics support routines
1514         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1515         * device/lib/Makefile.in: also create installdir for pic
1516
1517         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1518           pic14 port as well
1519         * src/pic/device.c (dump_sfr): rewritten to delegate register
1520           placement to the linker (use `extern sym' rather than sym EQU addr),
1521           (validAddress): fixed to check last specified address
1522         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1523           (popGetLit): truncate literal value to 8 bit,
1524           (popGet): moved assert to more appropriate place
1525           (popGetExternal): create pCode operand from and mark the according
1526             symbol as being `extern'
1527           (popGetAddr): added sanity check on immediate's offset, provide
1528             GPOINTER tag on demand
1529           (aopPut): fixed for immediates,
1530           (mov2w_op): move operand's address or contents to WREG (depending on
1531             operand type), safer variant of mov2w,
1532           (movwf,call_libraryfunc): NEW, handy abbreviations,
1533           (get_argument_pcop,get_return_val_pcop,pass_argument,
1534           get_returnvalue): interface for accessing function parameters and
1535             return values,
1536           (assignResultValuei,genRet): use new parameter/return value interface
1537           (pic14_getDataSize): back to old version handling generic pointers,
1538           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
1539             provided implementation and/or fixed old one,
1540           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
1541             calls, removed legacy 8051 reference code
1542           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
1543           (loadSignToC): NEW, move the operands sign bit to CARRY,
1544           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
1545             genRightShiftSigned, accepts negative shift counts,
1546           (setup_fsr): load FSR and adjust IRP (indirect memory access),
1547           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
1548             generic pointers, __data pointers and __code pointers,
1549           (genUnpackBits,genPackBits): rewritten to work with generic pointers
1550             and signed bitfields, limit bitfields to 8 bit,
1551           (genDataPointerGet): fixed number of bytes read,
1552           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
1553           (genPointerGet,genPointerSet): fixed handling of __code pointers,
1554             pointers to constant data are no longer assumed to point to __code
1555             space, removed invalid pointer types,
1556           (bitpatternFromVal): retrieve the PICs representation of an integer
1557             or float literal,
1558           (genDataPointerSet): fixed assigning to po_immediate operands,
1559           (genGenPointerSet): implemented as library call,
1560           (genIfx): fixed incorrect condition,
1561           (genAddrOf): limit generic pointers' addresses to 2 bytes,
1562             provide GPOINTER tag according to destination's storage class,
1563           (genCast): added code to handle casting to generic pointers, added
1564             sign-/zero extension of the result
1565           (aop_isLitLike,op_isLitLike): fixed handling of immediates
1566         * src/pic/gen.h: added macros to access IRP bit in STATUS register
1567         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
1568           extend the result
1569         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
1570           address/register resides in the shared banks
1571           (emitSymbolToFile): improved to handle global and `pinned' symbols,
1572             put all variables into separate sections (have the linker arrange
1573             them)
1574           (picglue): put init code and interrupt handlers in separate sections
1575         * src/pic/main.c: added port specific options table, modified to PORT
1576           structure to make GPOINTERs 3 byte, added pic14_options
1577           (_pic14_do_link): private linking routine (update paths to libraries,
1578             add libsdcc.lib by default)
1579         * src/pic/main.h: declare pic14_options
1580         * src/pic/pcode.c: fixed instructions i/o relations,
1581           (RegCond): reverted to correct version,
1582           (newpCodeOpLit): truncate literals to 8 bit,
1583           (genericPrint): added debug output,
1584           (getRegFromInstruction): fixed for various operand types, simplified
1585           (BuildFlow): fixed broken handling of isntructions with labels
1586           (LinkFlow): start at last instruction in flow (skip trailing comments),
1587             pass the flow on to the next instruction after CALL
1588           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
1589           (insertPCodeInstruction): fixed inserting after a skip instruction,
1590           (DoBankSelect): fixed for labeled instructions
1591           (OptimizepBlock): honor --nopeep switch
1592           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
1593         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
1594         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
1595           (pCodeOptime2pCodes): allow disabling this optimization via
1596             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
1597             but is still buggy), started implementation of a dataflow based
1598             pCode optimization (CSE + dead code elimination)
1599           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
1600         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
1601           names are independant of the stack location and therefore portable across
1602           devices
1603
1604 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1605
1606         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
1607           (selectSpil): fixed bug 1337835 by not spilling bit variables
1608         * support/regression/tests/bug1337835.c: added test for this bug
1609         * src/mcs51/peeph.def: restart after rule 3.c,
1610           addded rules 263.x to optimize loading constants
1611
1612 2005-10-26 Raphael Neider <rneider AT web.de>
1613
1614         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
1615         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
1616           (genAssign): emit warning when casting literals to generic pointer
1617             type, also applies when taking the address of a fixed variable,
1618           (genCast): improved casting to generic pointers
1619         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
1620           extern variables, added verbose error message
1621         * device/include/pic16/{string.h,errno.h}: added #pragma library c
1622
1623 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
1624
1625         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
1626         carry must be complemented too
1627         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
1628         could be emitted by genMinus
1629         * src/SDCCval.c (constVal): fixed bug 1305065
1630
1631 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
1632
1633         * src/SDCCast.c (addCast): added promotion for bit variables
1634         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
1635         promotion casts + optimisation
1636         (optimizeGetWord): fix warning 'i' might be used uninitialized
1637         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
1638         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
1639
1640 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
1641
1642         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
1643         all chars are promoted to int; promotion should be handled in SDCCast.c
1644
1645 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1646
1647         * device/lib/_strcmp.c: Fixed bug 1326457
1648
1649 2005-10-11 Raphael Neider <rneider AT web.de>
1650
1651         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
1652         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
1653
1654 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
1655
1656         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
1657         * support/regression/tests/sfr16.c: added test for the sfr32 bug
1658
1659 2005-10-04 Raphael Neider <rneider AT web.de>
1660
1661         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
1662           device/lib/pic16/pics.all: added pic18f1320
1663         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
1664
1665 2005-09-30 Raphael Neider <rneider AT web.de>
1666
1667         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
1668         * src/pic16/devices.inc: NEW, provides device descriptions
1669         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
1670
1671 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
1672
1673         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
1674           GETHBIT
1675
1676 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
1677
1678         * doc/sdccman.lyx: updated Highest Order Bit documentation,
1679           documented Any Order Bit, Higher Order Byte and Higher Order Word
1680         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
1681         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
1682           (optimizeGetAbit): new, to get any bit, not only the high bit,
1683           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
1684           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
1685           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
1686           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
1687             RIGHT_OP: also try GETBYTE, GETWORD optimization,
1688             GETABIT, GETBYTE, GETWORD: decorate them,
1689           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
1690           (ast_print): added GETABIT, GETBYTE, GETWORD
1691         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
1692         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
1693           (geniCodeBinary): new generic binary icode,
1694           (ast2iCode): added GETABIT, GETBYTE, GETWORD
1695         * src/port.h: updated comment for PORT.hasExtBitOp
1696         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
1697           (genGetByte): new, to get a single byte,
1698           (genGetWord): new, to get a word from a long,
1699           (gen51Code): added GETABIT, GETBYTE, GETWORD
1700         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
1701
1702 2005-09-23 Raphael Neider <rneider AT web.de>
1703
1704         * configure.in, configure: have device/lib/pic configured
1705         * device/lib/Makefile.in: added model-pic14
1706         * device/lib/clean.mk: added pic/ to clean rule
1707         * device/lib/pic: added rudimentary pic14 library providing support
1708           functions for multiplication/division/generic pointer access
1709         * src/SDCCopt.c (convilong): mark support functions as extern
1710           for pic14 port as well
1711         * src/pic/gen.c (genMult): added assertions,
1712           (genpic14Code): emit warning on unhandled iCodes
1713         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
1714         * src/pic/pcode.c (pCodeOpCopy),
1715         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
1716           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
1717           SFR_REGISTER}), made safe for future extensions
1718         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
1719           instructions even if preceeded by SKIP instructions (also remove
1720           them); removed unused code
1721         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
1722           prevents leaving parts of the structure uninitialized after copying
1723
1724 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
1725
1726         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
1727           ago by me
1728         * support/regression/tests/addsub.c: added test for the bug
1729
1730 2005-09-21 Raphael Neider <rneider AT web.de>
1731
1732         * device/include/pic16/pic18f1220.h,
1733           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
1734         * device/lib/pic16/Makefile.rules: added missing opening paren
1735         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
1736           are provided in genutils.c,
1737           (genUminusFloat,genUminus,genCmpEq): added asserts on different
1738           operand/result sizes,
1739           (genCmp): assert on NULL pointers first, then check deref'ed values
1740         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
1741           result size
1742
1743 2005-09-18 Raphael Neider <rneider AT web.de>
1744
1745         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
1746           as these are now unused,
1747           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
1748         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
1749           local, avoids uninitialized pointer dereference on r->name
1750         * src/pic16/ralloc.c (newReg): fixed indentation
1751
1752 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
1753
1754         * src/SDCCval.c (constVal): fixed bug 730366
1755         * support/Util/SDCCerr.c,
1756         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
1757
1758 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
1759
1760         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
1761
1762 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
1763
1764         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
1765
1766 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
1767
1768         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
1769           (hex2dec): made hex_digit unsigned char, removed ascii dependance
1770         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
1771           (hex2dec): made hex_digit unsigned char, removed ascii dependance
1772         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
1773         * packihx/packihx.c (hexDigit): made c unsigned char
1774         * as/mcs51/lklibr.c (fndsym),
1775         * link/z80/lkgb.c (gb),
1776         * link/z80/lklibr.c (fndsym),
1777         * link/z80/lkrloc.c (relr),
1778         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
1779         * src/SDCC.lex (checkCurrFile, process_pragma),
1780         * src/SDCCglue.c (spacesToUnderscores),
1781         * src/SDCCmain.c (setParseWithComma, processFile),
1782         * src/asm.c (tvsprintf, printCLine),
1783         * src/avr/gen.c (emitcode, aopPut),
1784         * src/ds390/gen.c (emitcode),
1785         * src/hc08/gen.c (emitcode, emitinline),
1786         * src/mcs51/gen.c (emitcode, genInline),
1787         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
1788           tokenizeLineNode),
1789         * src/pic/ralloc.c (debugLog),
1790         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
1791           tokenizeLineNode),
1792         * src/pic16/ralloc.c (debugLog),
1793         * src/z80/main.c (_process_pragma):
1794            made all ctype.h function calls safe
1795         * src/SDCCopt.c: include math.h for fabs
1796         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
1797           and used them throughout the code to make ctype.h function calls safe
1798         * src/ds390/main.c (asmLineNodeFromLineNode),
1799         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
1800         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
1801            unsigned char*
1802         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
1803           (newpCodeAsmDir): made ctype.h function calls safe
1804         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
1805           pic16_emitcode):  made lbp unsigned char*
1806         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
1807           (pic16_newpCodeAsmDir): made ctype.h function calls safe
1808         * src/xa51/gen.c (emitcode),
1809         * src/z80/gen.c (_emit2): made lbp unsigned char*
1810         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
1811            char*
1812
1813 2005-09-05 Raphael Neider <rneider AT web.de>
1814
1815         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
1816           access bank splitpoint
1817
1818 2005-09-05 Raphael Neider <rneider AT web.de>
1819
1820         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
1821
1822 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
1823
1824         * .version: changed to version 2.5.3
1825         * doc/sdccman.lyx: changed version to 2.5.3,
1826           documented --codeseg and --constseg and pragma codeseg and constseg,
1827           documented bit parameters (reentrant) and bit returning
1828         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
1829            currFunc->recvSize, but is this ok for all ports?
1830           (ast2iCode): result of ~ on unsigned char must be cast to int for
1831            bool to work
1832         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
1833           function pointers in bit space
1834         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
1835           (processFuncArgs): call port.reg_parm() with reentrancy info
1836         * src/port.h,
1837         * src/avr/main.c,
1838         * src/ds390/main.c,
1839         * src/hc08/main.c,
1840         * src/pic/main.c,
1841         * src/pic16/main.c,
1842         * src/xa51/main.c,
1843         * src/z80/main.c: port.reg_parm prototype extended with
1844           "bool reentrant" parameter
1845         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
1846           options.stackAuto for allocating bit register parameters
1847         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
1848           (genSend): set BitBankUsed if it is,
1849           (selectRegBank): factored out of genCall for use in genPcall,
1850           (genCall): removed redundant dtype assignmen, use selectRegBank,
1851           (genPcall): handle returning in Carry properly, save in F0 if needed,
1852           (genReceive): handle bit register parameters
1853         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
1854           (mcs51_assignRegisters): enable bit registers for all reentrant
1855            functions and don't set BitBankUsed unconditionally
1856         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
1857         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
1858         * support/regression/tests/funptrs.c: added tests for BOOL and for return
1859
1860 2005-08-27 Borut Razem <borut.razem AT siol.net>
1861
1862         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
1863         ppc-osx (Darwin) does not support -u option. It seems that it is
1864         supported only on Linux - GNU cp
1865
1866 2005-08-25 Borut Razem <borut.razem AT siol.net>
1867
1868         * sim/ucsim/gui.src/serio.src/Makefile.in,
1869           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
1870           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
1871           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
1872           install and strip, since the strip at /usr/ccs/bin should be used
1873           on solaris
1874
1875 2005-08-24 Borut Razem <borut.razem AT siol.net>
1876
1877         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
1878
1879 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
1880
1881         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
1882         ffffffffu
1883
1884 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
1885
1886         * as/mcs51/aslink.h: completed lkrloc.c prototypes
1887         * as/mcs51/lkmain.c (link_main): fixed warning
1888         * device/include/stdbool.h: ds390 has no advanced bit support yet
1889         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
1890         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
1891         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
1892           and updated their macros
1893         * src/SDCCval.c (constVal): updated comment for renamed b_long
1894
1895 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
1896
1897         * as/mcs51/asdata.c: changed ctype['['] to BINOP
1898         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
1899           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
1900           (oprio): set priority for '['
1901         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
1902            and adb_24_bit
1903         * as/mcs51/asm.h: added defines R_BIT and S_BIT
1904         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
1905         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
1906         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
1907           added overlayable BIT_BANK area
1908         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
1909           (summary2): explain 'T' in legenda
1910         * as/mcs51/lkrloc.c: replaced old K&R style,
1911           (relr): added R_BIT processing,
1912           (errmsg): added "Bit-addressable relocation error",
1913           (adb_bit): added for converting from byte- to bit-addressable space,
1914           (adb_24_bit): added for converting from byte- to bit-addressable space
1915         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
1916            used in reentrant functions now even as return value
1917         * device/lib/_gptrput.c (_gptrput): removed obsolete code
1918         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
1919           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
1920         * src/SDCCglobl.h: added indicator BitBankUsed
1921         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
1922            the bit registers b0-b7
1923         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
1924           (geniCodeCast): fixed bug 1263853,
1925           (geniCodeLogicAndOr): put result in bool or char,
1926           (geniCodeReceive): added parameter func for accessing the return type,
1927           (geniCodeFunctionBody): pass func to geniCodeReceive
1928         * src/SDCCmain.c: added indicator BitBankUsed
1929         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
1930         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
1931           (checkSClass): don't put automatic bool/bit on stack,
1932           (checkFunction): removed check on function cannot return bit
1933         * src/SDCCsymt.h: added newBoolLink prototype
1934         * src/mcs51/gen.c (rb1regs): added bit registers,
1935           (movc): created for assigning to carry,
1936           (pushReg, popReg): created for pushing registers,
1937           (sameRegs): check both AOP_REG and AOP_CRY types,
1938           (aopOp): handle bit registers,
1939           (aopPut): optimization no self-assign,
1940           (saveRegisters): push reg->base (bits) only once for bit registers,
1941            and use pushReg,
1942           (unsaveRegisters): pop reg->base only once and use popReg,
1943           (assignResultValue): added parameter func and return in carry for bits,
1944           (genIpush): optimization no reload in A if not changed,
1945           (genSend): bit parameters in reentrant functions are passed in bit
1946            registers by first assigning to bits in B, then save registers and
1947            copy B to bits,
1948           (genCall): handle returning in Carry properly, save it in F0 if needed,
1949           (genPcall): updated assignResultValue call, this is not safe yet for bit
1950            returning function !!!
1951           (genFunction): don't generate equ's for bit registers and use pushReg,
1952           (genEndFunction): take care of bit returning functions and use popReg,
1953           (genRet): return bit in Carry,
1954           (genIfx): optimize bit registers and other directly addressable bits,
1955           (genReceive): updated assignResultValue call
1956         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
1957           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
1958            registers when using stack-auto
1959         * src/mcs51/ralloc.c (_G): added allBitregs,
1960           (regs8051): added the bit registers,
1961           (createStackSpil): use macro IS_BIT,
1962           (getRegBit): added to allocate a bit register, else spill,
1963           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
1964           (updateRegUsage): factored out to ease stepping while debugging,
1965           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
1966            also allocate bit registers,
1967           (fillGaps): handle bit registers,
1968           (findAllBitregs): added to create bit vector with all bit registers,
1969           (mcs51_allBitregs): returns this bit vector,
1970           (mcs51_assignRegisters): when using stack-auto use bit registers for
1971            passing parameters and creating local variables
1972         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
1973
1974 2005-08-22 Borut Razem <borut.razem AT siol.net>
1975
1976         * device/lib/Makefile.in: replaced find option -or with -o
1977           to make it run on solaris
1978
1979 2005-08-22 Raphael Neider <rneider AT web.de>
1980
1981         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
1982           fixes #1265442 (crash on Solaris)
1983
1984 2005-08-20 Borut Razem <borut.razem AT siol.net>
1985
1986         * configure, configure.in: added tests for libsocket and libnsl libraries,
1987           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
1988           from support/regression/Makefile.in
1989         * support/regression/Makefile.in: added
1990         * device/lib/pic16/Makefile.common.in: force make to use bash shell
1991         * sim/ucsim/libtool: regenerated on sparc-solaris
1992         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
1993           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
1994           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
1995           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
1996           sparc-solaris, which doesn't use GNU ld linker
1997         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
1998         * as/Makefile: find on sparc-solaris does not support -maxdepth option
1999
2000 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2001
2002         * src/mcs51/peeph.def: updated comments
2003
2004 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2005
2006         * device/lib/_gptrget.c,
2007         * device/lib/_gptrput.c: slightly shorter
2008         * doc/sdccman.lyx: incremented version
2009         * src/mcs51/peeph.def: moved peephole comments to the line of first
2010           change to better keep line correlation, reanimated 186.e
2011         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2012
2013 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2014
2015         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2016           David Saxton with quotes around file name.
2017
2018 2005-08-15 Borut Razem <borut.razem AT siol.net>
2019
2020         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2021           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2022           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2023           make tests run on x86_64 platform
2024
2025 2005-08-13 Raphael Neider <rneider AT web.de>
2026
2027         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2028           as it might be executed DURING a build (parallel make is wonderful)
2029
2030 2005-08-13 Raphael Neider <rneider AT web.de>
2031
2032         * device/lib/Makefile.in (port-specific-objects-pic16):
2033           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2034         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2035           dependency
2036         * device/lib/pic16/Makefile.rules: build subdirs before creating
2037           the library, removed builddir rule, create $(builddir) early in
2038           recurse rule, use empty recurse rule for leaf directories
2039         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2040           mkdir errors (race condition), removed duplicate suffix "hex"
2041           from clean rules
2042         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2043         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2044           prevents mkdir -p from aborting on Alpha
2045
2046 2005-08-12 Raphael Neider <rneider AT web.de>
2047
2048         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2049           db-statements in order to allow for arrays of pointers in code
2050           sections to be placed without interspersed 0-padding, fixes
2051           bug #1256215
2052         * (emitStatistics): fixed division by zero for pic18f1220
2053         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2054           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2055         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2056         * (pic16_pCodeConstString): keep track of already emitted string
2057           literals to prevent "duplicate definitions of symbol _str_NR"
2058         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2059           debug message
2060         * device/lib/Makefile.in: ignore failing PIC16 library builds
2061         * device/lib/pic16/Makefile: do not build if gputils are missing
2062         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2063
2064 2005-08-10 Raphael Neider <rneider AT web.de>
2065
2066         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2067           my last commit)
2068
2069 2005-08-10 Raphael Neider <rneider AT web.de>
2070
2071         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2072           Rokas' patch to add the new fixed point type "__fixed16x16"
2073         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2074           functions for __fixed16x16 arithmetics
2075         * device/lib/pic16: reimplemented the build system to support
2076           a separate build directory, better handling of libio (create
2077           the library in a separate subdir for each architecture) and
2078           easier configuration (centralized in Makefile.common)
2079
2080 2005-08-07 Raphael Neider <rneider AT web.de>
2081
2082         * src/pic16/gen.c (genrshTwo): fixed sign extension
2083         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2084         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2085           added T0CONbits
2086         * device/include/pic16/pic18f4220.h: NEW, header for
2087           pic18f4220 and pic18f4320
2088         * device/include/pic16/pic18fregs.h: added new devices,
2089           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2090         * device/include/pic16/signal.h: resolved name clashes
2091           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2092           to also allow testing for interrupt enable bits, added
2093           comments on how to use the macros
2094         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2095         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2096           register definitions for the devices
2097         * device/lib/pic16/pics.all: added new devices
2098         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2099           allocated memory
2100         * device/lib/pic16/libc/stdlib/memfree: do not count
2101           the block header as free memory
2102         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2103           simplified and added missing end-of-blocklist-marker
2104           (reported by Peter Onion, fixes #1252814)
2105         * (_mergeHeapBlock): fixed loop condition
2106         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2107           len==0, restructured code
2108         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2109           up a bit, reduced bitfield accesses, prevent endless loops
2110           in case of heap corruption
2111         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2112           "unreferenced arguments/must return a value" warnings
2113         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2114           replaced BAUDREG with SPBRG
2115         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2116           device/lib/pic16/debug/gstack/gstack.c: replaced
2117           _naked, _asm, _endasm with __naked, __asm, __endasm
2118
2119 2005-08-05 Raphael Neider <rneider AT web.de>
2120
2121         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2122           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2123
2124 2005-08-05 Borut Razem <borut.razem AT siol.net>
2125
2126         * device/lib/Makefile.in: added missing ';'
2127         * configure: removed ^M characters
2128
2129 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2130
2131         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2132           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2133           License
2134
2135 2005-08-04 Borut Razem <borut.razem AT siol.net>
2136
2137         * configure.in: pic16 libraries build 2nd try - enable running
2138           configure in device/lib/pic16
2139         * configure: regenerated from configure.in
2140         * device/lib/Makefile.in: create $(PORT)/bin directory
2141
2142 2005-08-03 Raphael Neider <rneider AT web.de>
2143
2144         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2145           to get/set values via pointers
2146         * (genUnpackBits,genPackBits): changed detection of
2147           ptr->bitfield vs. sym.bitfield, fixed access via generic
2148           pointers, removed dead (wrong) code for multibyte bitfields
2149         * (genNearPointerGet, genGenPointerGet): removed useless code,
2150           fixed bitfield detection, fixes #1250594
2151         * (genNearPointerSet): removed useless code
2152         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2153           and introduced macro pic16_emitpcode that conditionally emits
2154           the origin of the following pCode (useful for debugging SDCC)
2155         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2156         * (createDefmap): fixed handling of LFSR for --optimize-df
2157
2158 2005-08-02 Borut Razem <borut.razem AT siol.net>
2159
2160         * device/lib/Makefile.in: pic16 libraries build enabled since
2161           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2162
2163 2005-08-02 Raphael Neider <rneider AT web.de>
2164
2165         * src/pic16/gen.c (genPackBits): removed deprecated warning
2166         * (genGenPointerSet): fixed bitfield detection
2167
2168 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2169
2170         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2171
2172 2005-07-31 Raphael Neider <rneider AT web.de>
2173
2174         * device/lib/pic16/libdev/pic18f458.c,
2175           device/include/pic16/pic18f458.h: added missing T0CONbits
2176
2177 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2178
2179         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2180
2181 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2182
2183         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2184
2185 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2186
2187         * device/include/mcs51/at89c51ed2.h: added.
2188
2189 2005-07-23 Raphael Neider <rneider AT web.de>
2190
2191         * src/pic/gen.h: added emitpcode macro for debugging
2192         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2193           and replace by macro adding debug information on demand
2194         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2195         * (gencjne): tried to fix; replaced with correct (slower) code
2196         * (gen{Unp,P}ackBits): fixed single bit access
2197         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2198         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2199           previous instruction
2200         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2201           register has to be handled with care (forbidding movement
2202           of assignments/uses, removing assignments completely, ...)
2203         * (pCodeOptime2pCodes): make use of regIsSpecial
2204         * added lots of debugging output (commented out)
2205         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2206           from being reused as result UNLESS it is known to work
2207
2208 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2209
2210         * support/Util/dbuf.h: include <stddef.h> for size_t
2211         * .version: changed to version 2.5.2
2212
2213 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2214
2215         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2216
2217 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2218
2219         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2220           (genModOneByte): removed needless psha/pula
2221
2222 2005-07-22 Raphael Neider <rneider AT web.de>
2223
2224         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2225           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2226         * src/pic/gen.c (resolveIfx): do not "invent" labels
2227         * (genSkipc): changed to positive logic
2228         * (genSkipCond): removed as no longer needed
2229         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2230           backport from PIC16
2231         * (genLeftShift): check operands are in different registers
2232         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2233           INCF does not update CARRY...
2234         * src/pic/main.c: fixed _linkCmd
2235         * src/pic/pcode.c (unlinkpCode): added inactive code
2236         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2237           alive (do not assign result and operand overlapping registers)
2238
2239 2005-07-22 Raphael Neider <rneider AT web.de>
2240
2241         * src/pic/device.c (dump_sfr): replaced register declaration with
2242           call to emitSymbolToFile() to avoid duplicate symbols
2243         * (assignRelocatableRegisters): do not declare external symbols
2244         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2245           right (take size of type, not etype)
2246         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2247         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2248         * (packRegsForAccUse): disabled assignment of WREG as
2249           the result reg to prevent occurence of just fixed #1235003,
2250           fixes #1242954
2251         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2252           symbols (avoids duplicate symbols in .asm file)
2253         * (pic14emitRegularMap): use emitSymbolToFile()
2254         * src/pic/gen.c (aopOp): fixed spillLocation handling
2255         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2256         * (genDataPointerSet): removed unneccessary variables/output
2257
2258 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2259
2260         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2261         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2262
2263 2005-07-21 Raphael Neider <rneider AT web.de>
2264
2265         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2266           architecture cannot handle them efficiently, fixes bug #1235003
2267         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2268           check for empty sets before using them (fixes bug #1232190)
2269
2270 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2271
2272         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2273           (lnksect2): generate warnings for memory overlap
2274         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2275           constseg to set the name of these segments so you can instruct the linker
2276           to place them in banks
2277         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2278         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2279           added code_seg and const_seg to options
2280         * src/SDCCglue.c (emitMaps): use options.const_seg,
2281           (createInterruptVect): put interrupt vectors in segment HOME,
2282           (glue): put HOME before static segment and put the main glue in HOME,
2283           (glue): use options.code_seg
2284         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2285         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2286           these segments so you can instruct the linker to place them in banks
2287           (linkEdit): use code_loc for HOME segment which should be the first
2288           segment in code memory now
2289         * src/SDCCmem.c: fixed more stuff like bug 1238386
2290         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2291           (changePointer): don't change function pointers to code pointers for
2292           banked functions,
2293           (compareType): added exceptional check for banked function pointers
2294         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2295         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2296           after static in code memory
2297         * src/mcs51/gen.c: added aopLiteralLong prototype,
2298           (aopForSym): use getSize for functions,
2299           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2300           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2301           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2302           the segment,
2303           (genPcall): use call for literal function pointers and generate banked
2304           calls over the one trampoline so there's only one place for the user to
2305           modify according to his/hers hardware,
2306           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2307           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2308         * src/mcs51/main.c: added keyword banked,
2309           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2310         * support/Util/SDCCerr.c,
2311         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2312           needed for passing the bank and address to the trampoline
2313         * device/lib/mcs51/crtbank.asm: added for bankswitching
2314         * device/lib/mcs51/Makefile: added crtbank
2315
2316 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2317
2318         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2319           for fields at offset 0 of a struct or union as reported
2320           on 2005-07-07 in the developer mailing list.
2321
2322 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2323
2324         * src/SDCCmem.c: fixed bug 1238386
2325
2326 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2327
2328         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2329           (patch #1144962), added peephole 300, enabled 259.x
2330         * doc/sdccman.lyx: removed screenshot and provided link instead
2331
2332 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2333
2334         * doc/sdccman.lyx: added section about debugging with ddd
2335         * doc/figures/ddd_example.eps: screenshot of debugging session
2336
2337 2005-07-04 Raphael Neider <rneider AT web.de>
2338
2339         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2340           like CODE pointers, fixes #1115683
2341         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2342           call, fixes bugs #1232211, #1228110,
2343           fixed wrong casts to pCodeFlow from pCodeInstructions
2344
2345 2005-07-04 Raphael Neider <rneider AT web.de>
2346
2347         * src/pic/gen.c (popGet): changed assert to allow for
2348           bit operands
2349         * (popGetAddr): changed signature to provide
2350           an additional index, patched all call sites
2351         * (genCmpEq): handle literal-like operands correctly
2352         * (genAddrOf): added sanity checks on __code/__data pointers
2353         * (genAssign): added handling of symbols from __code section
2354         * (gencjne): do not generate code for comparisons whose result
2355           is neither stored nor used, fixes bug #1171114
2356         * (AccLsh, AccRsh): operate on operand instead of WREG
2357         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2358           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2359           by known count
2360         * rewrote complete shift-by-literal logic, commented unused
2361           functions out
2362         * (genConstPointerGet): get multiple bytes (if result size > 1),
2363           fixed handling of non-immediate addresses
2364         * (genPointerGet): handle CODE pointers like CONST pointers
2365         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2366         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2367           operand is to be treated as a literal or not
2368         * (mov2w,genPcall,genCmpEq),
2369           src/pic/genarith.c: use aop_isLitLike() to decide between
2370           literal/register contents
2371         * (addSign): added missing offset
2372         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2373           only emit comment in debug-mode,
2374           use {aop,op}_isLitLike throughout the file
2375         * src/pic/glue.c: fix initializers for pointers (work in progress)
2376         * src/pic/pcode.c (get_op): honor index on _const symbols
2377         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2378         * (dumppBlock): added pCode size estimation
2379         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2380           check for IS_SYMOP before OP_SYMBOL'ing
2381         * fixed indentation, compacted switch-statements
2382         * (allocReg): find free register and allocate it instead of
2383           allocating new registers all the time
2384         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2385           registers as its operands (necessary only for multibyte GETs)
2386
2387 2005-07-01 Raphael Neider <rneider AT web.de>
2388
2389         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2390           debugging .asm-output macros FENTRY + FEXIT
2391         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2392           way... I wonder...
2393         * (emitpComment): NEW, printf to pCode
2394         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2395           offset handling
2396         * (popGetAddr): NEW, variant of popGet to access an immediates
2397           high(er) bytes instead of the n'th byte of memory they reference,
2398           replaced popGet with popGetAddr where neccessary
2399         * (genDataPointerGet): reactivated and fixed implementation
2400         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2401           accesses
2402         * (genDataPointerSet): fixed multibyte assignments
2403         * (genpic14Code): fixed --i-code-in-asm handling
2404         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2405         * (genPlus): fixed index-out-of-bounds error
2406         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2407         * src/pic/ralloc.c: added debugging output macro FENTRY2
2408         * (spillThis): fixed indentation, enbraced for-body for clarity
2409         * (rematStr): commented out as now unused
2410         * (regTypeNum): commented out special spill case (overwrites
2411           arbitrary values)
2412         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2413
2414 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2415
2416         * doc/sdccman.lyx: documented sfr16/sfr32,
2417           added example for using storage class with function pointers
2418         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2419
2420 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2421
2422         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2423         * device/lib/_itoa.c,
2424         * device/lib/_ltoa.c: optimized codesize
2425         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2426           but don't know how to suppress the double warning.
2427         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2428         * support/Util/SDCCerr.c,
2429         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2430
2431 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2432
2433         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2434           fixed old K&R prototypes
2435         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2436         * device/lib/_gptrget.c,
2437         * device/lib/_gptrgetc.c,
2438         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2439           also new versions for small generic pointers and banked generic pointers
2440         * src/port.h: added const_name
2441         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2442         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2443         * src/SDCCcse.c (findPrevIc): check all associative operators
2444         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2445         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2446         * src/SDCCmem.c: updated comments,
2447           set far-space to 0 for pdata, results in optimized code
2448         * src/SDCCmem.h: added macro CONST_NAME
2449         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2450           moving the info into the highest bits, see also gptrget/gptrput
2451         * src/src.dsp: added sdcc.ico to project files
2452         * src/avr/gen.c (genCast): fixed bug 0x%d
2453         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2454         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2455           relation between ptr_type and DCL_TYPE,
2456           (genCast): fixed bug 0x%d
2457         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2458           (CODE)" for const_name
2459         * src/hc08/gen.c (genCast): fixed bug 0x%d
2460         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2461           (hc08_port): added "CONST (CODE)" for const_name
2462         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2463           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2464           between ptr_type and DCL_TYPE,
2465           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2466           operand* and took AOP() inside function so sfr-ness can be checked,
2467           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2468           new prototype,
2469           (genFunction, genEndFunction): optimized stack setup,
2470           (genMinus): optimized for literals with ending zeroes (in bytes),
2471           (genCast): fixed bug 0x%d
2472         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2473           (mcs51_port): added "CONST (CODE)" for const_name
2474         * src/mcs51/peeph.def: made rule 226 more generic
2475         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2476         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2477         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2478         * src/z80/main.c (z80_port): added NULL for const_name,
2479           (gbz80_port): added NULL for const_name
2480         * support/regression/tests/bug663539.c,
2481         * support/regression/tests/sfr16.c: new tests
2482
2483 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2484
2485         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2486
2487 2005-06-24 Raphael Neider <rneider AT web.de>
2488
2489         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2490           corrected typos...
2491         * device/include/pic16/signal.h: added USBIF
2492           and SIG_USB
2493
2494 2005-06-24 Raphael Neider <rneider AT web.de>
2495
2496         * device/lib/pic16/libdev/pic18f2455.c,
2497           device/include/pic16/pic18f2455.h: NEW
2498         * device/include/pic16/pic18fregs.h,
2499           device/lib/pic16/pics.all,
2500           src/pic16/device.c: added 18f2455
2501         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2502           device/include/pic16/{pic18f[68][567].h,usart.h}:
2503           replaced MULTIPLE_USARTS define with more relaible
2504           compatibility sfrs (for USART access)
2505
2506 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2507
2508         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2509           and the output asm file line is printed on two lines.
2510
2511 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2512
2513         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2514           BGT, BLE, BHI, and BLS instructions
2515         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2516           genCmpEq): removed
2517         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2518           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2519           fixes bug #1216342
2520         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2521
2522 2005-06-15 Raphael Neider <rneider AT web.de>
2523
2524         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2525         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2526         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2527           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2528           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2529
2530 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2531
2532         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2533           Marcel Telka in bug #1215704
2534
2535 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
2536
2537         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
2538           located in shared memory bank.
2539
2540 2005-05-31 Raphael Neider <rneider AT web.de>
2541
2542         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
2543           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
2544           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
2545
2546 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
2547
2548         * device/lib/_strncpy.c: fixed the fix
2549
2550 2005-05-26 Raphael Neider <rneider AT web.de>
2551
2552         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
2553           initializers with \0, bug #1208187
2554         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
2555           intializers with \0, bug #1208187
2556
2557 2005-05-26 Raphael Neider <rneider AT web.de>
2558
2559         * src/pic16/glue.c (pic16_printIvalChar): fixed string
2560           initializers with \0, bug #1208187
2561         * src/pic16/main.c (_process_pragma): added sanity checks
2562           for stack position and size, emit warnings when appropriate
2563
2564 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
2565
2566         * device/lib/_strncpy.c: fixed not filling with \0
2567
2568 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2569
2570         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
2571           createFunction),
2572         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
2573           compound_statement),
2574         * src/SDCCsymt.h,
2575         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
2576
2577 2005-05-24 Raphael Neider <rneider AT web.de>
2578
2579         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
2580
2581 2005-05-24 Raphael Neider <rneider AT web.de>
2582
2583         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
2584           TRISE definitions, closes bug #1162453
2585
2586 2005-05-22 Raphael Neider <rneider AT web.de>
2587
2588         * src/pic16/main.c (_process_pragma): check for missing
2589           arguments to pragmas code and udata
2590         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
2591           consistency fixes to match other headers (thanks to Jim Paris)
2592         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
2593
2594 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
2595
2596         * src/SDCCicode.c (isOperandEqual): fixed missing ;
2597
2598 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
2599
2600         * support/regression/tests/bug1198642.c: new test
2601         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
2602         * src/SDCCcse.c (findPrevIc): added comment, please have a look
2603         * support/scripts/resource.h,
2604         * support/scripts/resource.rc,
2605         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
2606         * support/scripts/sdcc.ico: added 32x32 icon
2607
2608 2005-05-18 Raphael Neider <rneider AT web.de>
2609
2610         * device/lib/pic16/libdev/pic18f*.c,
2611         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
2612           keywords to "__sfr" and "__at (X)"
2613         * device/include/pic16/pic18fregs.h: added pic18f4520
2614         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
2615           #1203088 (MPLAB compatibility)
2616
2617 2005-05-17 Raphael Neider <rneider AT web.de>
2618
2619         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
2620         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
2621         * device/lib/pic16/pics.all: added new devices
2622         * src/pic16/device.c: added support for pic18f4520
2623
2624 2005-05-16 Raphael Neider <rneider AT web.de>
2625         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
2626         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
2627         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
2628           convenience function for bit access
2629
2630 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2631
2632         * device/lib/printf_large.c: fixed bug 1193299
2633         * support/regression/tests/bug1057979.c: added test %3.3s
2634
2635 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2636
2637         * device/include/mcs51/8051.h,
2638         * device/include/mcs51/8052.h: made parseable with lint
2639         * device/include/mcs51/lint.h: added include file for (sp)lint
2640         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
2641         * doc/cdbfileformat.lyx,
2642         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
2643
2644 2005-05-14 Raphael Neider <rneider AT web.de>
2645
2646         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
2647         * device/lib/pic16/libc/stdlib/itoa.c (new)
2648         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
2649         * device/lib/pic16/libio/Makefile: exclude subdir according to
2650           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
2651         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
2652         * src/pic16/gen.c (genFunction): prevent annoying warning
2653         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
2654           nameclashes on BeOS
2655         * support/cpp2/cppmain.c (cpp_output_string): new
2656         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
2657           fixes bug 1116802
2658
2659 2005-05-13 Borut Razem <borut.razem AT siol.net>
2660
2661         * src/SDCCmain.c (linkEdit): fixed bug 1195202
2662
2663 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2664
2665         * .version: changed to version 2.5.1; back to bleeding edge development
2666
2667 2005-05-11 Borut Razem <borut.razem AT siol.net>
2668
2669         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
2670           generate PDF version 1.3 documents
2671
2672 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2673
2674         * .version: changed to version 2.5.0
2675
2676 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2677
2678         * doc/sdccman.lyx: updated weblinks, index and smaller updates
2679
2680 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2681
2682         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
2683         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
2684         well as many smaller updates.
2685         * .version: changed to version 2.5.0-pre1
2686
2687 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2688
2689         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
2690
2691 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2692
2693         * support/regression/tests/bug1185672.c: added
2694         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
2695           bug 1185672
2696         * src/mcs51/gen.c (genCall): added comments, made it look safer
2697         * src/mcs51/gen.c (genEndFunction): simplified
2698
2699 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
2700
2701         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
2702
2703 2005-04-14 Borut Razem <borut.razem AT siol.net>
2704
2705         * fixed bug 1045046 - SIGSEGV with really simple code?:
2706           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
2707           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
2708
2709 2005-04-14 Borut Razem <borut.razem AT siol.net>
2710
2711         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
2712           src/pic16/device.h: temporarily disabled experimental #inline pragma
2713           for 2.5.0 release
2714
2715 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
2716
2717         * device/include/z80/stdio.h,
2718         * device/include/z80/string.h: removed these highly incomplete files so
2719           SDCC can use the default ones in device/include/
2720
2721 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2722
2723         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
2724         gcc warning.
2725         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
2726         fix sdcpp warnings.
2727
2728 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
2729
2730         * device/include/malloc.h: removed redundant __reentrant prototypes
2731         * device/lib/_mullong.c: added working xstack variant in asm (C version
2732           doesn't pass regression tests)
2733         * device/lib/bpx.c: used __data and made bpx char for mcs51
2734         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
2735           (createFunction): fixed bug with xstackPtr
2736         * src/SDCCcse.c: corrected comments
2737         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
2738           (killDeadCode, eBBlockFromiCode): removed unused code
2739         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
2740           corrected comments
2741         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
2742           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
2743           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
2744           (genModOneByte): fixed warning in MSVC
2745         * src/mcs51/main.c (): added comments
2746         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
2747
2748 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
2749
2750         * src/SDCCmain.c (linkEdit): oops, changed one line too many
2751
2752 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
2753
2754         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
2755
2756 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
2757
2758         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
2759         characters arrays of larger size than the declared one.
2760
2761 2005-04-10 Borut Razem <borut.razem AT siol.net>
2762
2763         * src/pic/gen.c (genInline),
2764           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
2765           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
2766           (findNextInstruction), (findPrevInstruction),
2767           (findInstructionUsingLabel),
2768           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
2769         * src/pic/pcode.c (findLabel): added missing '\n'
2770         * src/src.dsp: added SDCCdwarf2.c to the project
2771
2772 2005-04-09 Borut Razem <borut.razem AT siol.net>
2773
2774         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
2775
2776 2005-04-08 Raphael Neider <rneider AT web.de>
2777
2778         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
2779           into the chain after a given one) and mergeDefmapSymbols (combine
2780           defmap entries for each symbol per pcode)
2781         * (createDefmap): have defmap entries merged in the end
2782         * (defmapReplaceSymRef): split defmap entries covering two accesses to
2783           a symbol before replacing one access type's symbol, merge symbols in
2784           the end (replacement symbol might already have an entry)
2785         * (assignValnums): keep reference to written WREG intact
2786
2787 2005-04-08 Raphael Neider <rneider AT web.de>
2788
2789         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
2790           Alpha)
2791
2792 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
2793
2794         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
2795         bytes
2796
2797 2005-04-07 Raphael Neider <rneider AT web.de>
2798
2799         * device/include/pic16/usart.h: added compatibility defines for
2800           devices with more than one USART
2801         * device/include/pic16/pic18f[68][567]20.h: activated above defines
2802
2803 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2804
2805         * device/lib/Makefile.in: updated for port specific include
2806
2807 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2808
2809         * support/regression/ports/mcs51/spec.mk: added mcs51 include
2810
2811 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2812
2813         * device/include/8051.h,
2814         * device/include/8052.h,
2815         * device/include/at89S8252.h,
2816         * device/include/at89c55.h,
2817         * device/include/at89x051.h,
2818         * device/include/at89x51.h,
2819         * device/include/at89x52.h,
2820         * device/include/mcs51reg.h,
2821         * device/include/reg51.h,
2822         * device/include/reg764.h,
2823         * device/include/regc515c.h,
2824         * device/include/sab80515.h: (re)moved these 12 files
2825         * device/include/mcs51/8051.h,
2826         * device/include/mcs51/8052.h,
2827         * device/include/mcs51/at89S8252.h,
2828         * device/include/mcs51/at89c55.h,
2829         * device/include/mcs51/at89x051.h,
2830         * device/include/mcs51/at89x51.h,
2831         * device/include/mcs51/at89x52.h,
2832         * device/include/mcs51/mcs51reg.h,
2833         * device/include/mcs51/reg51.h,
2834         * device/include/mcs51/reg764.h,
2835         * device/include/mcs51/regc515c.h,
2836         * device/include/mcs51/sab80515.h: and added them here
2837
2838 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
2839
2840         * device/include/stdarg.h: changed SDCC specific keywords to double
2841           underlined form.
2842         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
2843           mcs51 and ds390.
2844         * device/include/hc08/mc68hc908gp32.h,
2845         * device/include/hc08/mc68hc908jb8.h,
2846         * device/include/hc08/mc68hc908jkjl.h,
2847         * device/include/hc08/mc68hc908qy.h: fixed comments
2848         * device/include/mcs51/README: updated
2849         * device/include/mcs51/c8051f120.h: added PINRSF
2850         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
2851         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
2852           amidst code. Also inline is not supported.
2853
2854 2005-04-06 Raphael Neider <rneider AT web.de>
2855
2856         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
2857         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
2858           callers stack/frame pointers
2859
2860 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
2861
2862         * device/include/pic16/usart.h: added, missing in previous commit,
2863         * device/include/pic16/adc.h: fixed typo,
2864         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
2865         commit,
2866         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
2867         <p18fxxx.inc>
2868         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
2869         uninitialized because a bug appears with gplink
2870         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
2871         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
2872         complains for unrecognised option
2873
2874 2005-04-05 Raphael Neider <rneider AT web.de>
2875
2876         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
2877           structs as well (using memcpy)
2878         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
2879           on ISRs (GOTO has no label)
2880         * src/pic16/device.h: added OF_OPTIMIZE_DF
2881         * src/pic16/main.c: added compiler switch --optimize-df to enable the
2882           new data flow analysis/optimization
2883         * src/pic16/pcode.c: added (prototypes for and implementation of)
2884           dataflow analysis functions, fixed pCodeInstructions' inCond and
2885           outCond values, made RCALL a branch instruction
2886         * (pic16_unlinkpCode): keep C line if possible
2887         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
2888           C line moved if possible
2889         * (pic16_getRegFrompCodeOp): NEW, improved version of...
2890         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
2891           to use new pic16_getRegFrompCodeOp (works for more SFRs)
2892         * (pic16_BuildFlow): fixed skip instructions with label (did not start
2893           new flow)
2894         * (pic16_getJumptabpCode): NEW, needed in...
2895         * (LinkFlow): fixed handling of jumptables, calls and conditional
2896           branches
2897         * (pic16_InsertCommentAfter): NEW
2898         * (pic16_pCodeReplace): made verbose and flow preserving
2899         * (AnalyzeFlow): added call to data flow analysis
2900         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
2901         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
2902         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
2903
2904 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2905
2906         * src/SDCCast.c (decorateType): fixed bug #1105626
2907
2908 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
2909
2910         * device/include/asm/pic16/features.h,
2911         * pic18f*.h headers,
2912         * device/include/pic16/adc.h,
2913         * device/include/pic16/delay.h,
2914         * device/include/pic16/i2c.h,
2915         * device/include/pic16/malloc.h,
2916         * device/include/pic16/stdio.h,
2917         * device/include/pic16/stdlib.h,
2918         * device/include/pic16/string.h,
2919         * device/lib/pic16/libc/stdio/printf_tiny.c,
2920         * device/lib/pic16/libc/stdio/printf_small.c,
2921         * device/lib/pic16/libc/stdio/strmgpsim.c,
2922         * device/lib/pic16/libc/stdio/strmmssp.c,
2923         * device/lib/pic16/libc/stdio/strmusart.c,
2924         * device/lib/pic16/libc/stdio/vfprintf.c,
2925         * device/lib/pic16/libc/stdlib/ltoa.c,
2926         * device/lib/pic16/libc/stdlib/putchar.c,
2927         * device/lib/pic16/libc/stdlib/x_ftoa.c,
2928         * device/lib/pic16/libc/stdlib/memchrpgm.c,
2929         * device/lib/pic16/libc/stdlib/memchrram.c,
2930         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
2931         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
2932         * device/lib/pic16/libio/adc/adcbusy.c,
2933         * device/lib/pic16/libio/adc/adcread.c,
2934         * device/lib/pic16/libio/adc/adcsetch.c,
2935         * device/lib/pic16/libio/usart/ubaud.c,
2936         * device/lib/pic16/libio/usart/ubusy.c,
2937         * device/lib/pic16/libio/usart/udrdy.c,
2938         * device/lib/pic16/libio/usart/uopen.c,
2939         * device/lib/pic16/libio/usart/uputc.c,
2940         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
2941         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
2942         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
2943         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
2944         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
2945         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
2946         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
2947         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
2948         specific keywords to double underlined form,
2949         * device/lib/pic16/libc/Makefile.rules,
2950         * device/lib/pic16/libsdcc/Makefile.rules,
2951         * device/lib/pic16/libm/Makefile,
2952         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
2953         to compile with C standard set in Makefile.common
2954         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
2955         rand.c and crc.c in compilation process,
2956         * device/lib/pic16/libsdcc/int/divuint.c,
2957         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
2958         `c' from signed to unsigned,
2959         * device/lib/pic16/startup/crt0.c,
2960         * device/lib/pic16/startup/crt0i.c,
2961         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
2962         keywords to double underlined form, bug fixes in _do_cinit function
2963         which prevented the correct initialization of the .idata segment,
2964         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
2965         core to enter a infinite loop
2966         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
2967
2968 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2969
2970         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
2971
2972 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2973
2974         * device/include/Makefile.in: add support for hc08 subdirectory
2975         * device/include/hc08/: new subdirectory
2976         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
2977         Lucas Loizaga, thanks!
2978         * device/include/hc08/mc68hc908qy.h,
2979         * device/include/hc08/mc68hc908gp32.h,
2980         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
2981         their own directory. Changed internal macro names to use the compiler
2982         reserved namespace. Changed SDCC specific keywords to double
2983         underlined form.
2984         * device/include/math.h,
2985         * device/include/malloc.h,
2986         * device/include/stdarg.h,
2987         * device/include/stdbool.h
2988         * device/include/string.h,
2989         * device/include/tinibios.h,
2990         * device/include/ds400rom.h,
2991         * device/include/8051.h,
2992         * device/include/8052.h,
2993         * device/include/80c51xa.h,
2994         * device/include/at89c55.h,
2995         * device/include/at89S8252.h,
2996         * device/include/at89x51.h,
2997         * device/include/at89x52.h,
2998         * device/include/ds80c390.h,
2999         * device/include/reg764.h,
3000         * device/include/regc515c.h,
3001         * device/include/sab80515.h,
3002         * device/include/mcs51/c8051f000.h,
3003         * device/include/mcs51/c8051f018.h,
3004         * device/include/mcs51/c8051f020.h,
3005         * device/include/mcs51/c8051f040.h,
3006         * device/include/mcs51/c8051f060.h,
3007         * device/include/mcs51/c8051f120.h,
3008         * device/include/mcs51/c8051f300.h,
3009         * device/include/mcs51/c8051f310.h,
3010         * device/include/mcs51/c8051f320.h,
3011         * device/include/mcs51/c8051f330.h,
3012         * device/include/mcs51/c8051f350.h,
3013         * device/include/z180.h: Changed SDCC specific keywords to double
3014         underlined form.
3015
3016 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3017
3018         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3019         18F4455,
3020         * (pic16_assignConfigWordValue): disable testing of configuration
3021         register value with config mask,
3022         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3023         function with port->fun_prefix,
3024         * (genFunction): when generating a naked interrupt function never
3025         create an absolute segment placed in interrupt vector address, place
3026         the actual interrupt function at IVA instead, when an interrupt
3027         function is generated with unspecified interrupt then do not create
3028         the absolute section,
3029         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3030         code for generating a call to generic pointer get/put function with
3031         a call to function pic16_callGenericPointer(),
3032         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3033         the call to the generic pointer get/put functions with prefixing the
3034         function name with port->fun_prefix,
3035         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3036         * src/pic16/main.c (_process_pragma): prefix function with
3037         port->fun_prefix,
3038         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3039         calling assembler, old 18Fxxxx macro is deprecated,
3040         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3041         PC_ASMDIR in while condition,
3042         * (findInstruction): add PC_ASMDIR in while condition,
3043         * (buildCallTree): prefix main with port->fun_prefix,
3044         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3045         identifier for variable with banked access in instructions BTFSS,
3046         BTFSC, BCF, BSF, BTG
3047         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3048         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3049         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3050         perform optimization when enviroment variable NO_REG_OPT is set,
3051         * (insideLRBlock): NEW, return 1 if register is inside an
3052         INF_LOCALREGS block,
3053         * (RemoveRegFromLRBlock): remove a register that is completely
3054         eliminated by register optimization, but it is still left in local
3055         register store/restore in/from stack block,
3056         * (Remove2pcodes): after removing register, check to see if it
3057         should be removed from local register store/restore in/from stack
3058         block,
3059         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3060         DUMMY_READ_VOLATILE,
3061
3062         * device/include/pic16/adc.h: minor prototype modifications and
3063         update,
3064         * device/include/pic16/malloc.h: added GPL notice various
3065         modifications,
3066         * device/include/pic16/stdint.h: NEW, standard header for ints
3067         * device/include/pic16/delay.h: NEW, header for delay functions,
3068         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3069         delay1mtcy,
3070         * device/include/pic16/signal.h: NEW, header providing helper macros
3071         for implementing signal handlers,
3072         * device/include/pic16/stdio.h: added prototypes for functions,
3073         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3074         prototypes for stdin and stdout, added macro PUTCHAR to
3075         automatically implement putchar function prototype,
3076         * device/include/pic16/usart.h: modified and updated USART library,
3077         * device/lib/pic16/libio/adc/,
3078         * device/lib/pic16/libio/i2c: some modifications to improve library
3079         performance,
3080         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3081         family of functions,
3082         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3083         family of functions and other sources,
3084         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3085         of the PIC18Fxx[28] devices,
3086         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3087         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3088         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3089         _do_cinit function, because the previous failed when local variables
3090         where not placed in the same memory bank,
3091         * device/lib/pic16/libsdcc/char/: various modifications to improve
3092         library performance,
3093         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3094         information on the new functions of the c library and more...
3095
3096 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3097
3098         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3099
3100 2005-03-26 Raphael Neider <rneider AT web.de>
3101
3102         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3103           if condition == CARRY)
3104         * (genCmp): adapted to new genSkipc semantics
3105         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3106           on rIfx (genCmp was broken)
3107
3108 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3109
3110         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3111         * src/z80/main.c (_keywords[]),
3112         * src/SDCCglobal.h (struct options),
3113         * src/SDCC.y,
3114         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3115         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3116         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3117         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3118         always available in leading double underscore form. The C99 support is
3119         mostly missing, but it's a start.
3120         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3121         reserved identifier "__data".
3122
3123 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3124
3125         * src/mcs51/peeph.def: fixed bug 1170013
3126
3127 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3128
3129         * device/include/mcs51reg.h: fixed bug 842007
3130
3131 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3132
3133         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3134         last time.
3135
3136 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3137
3138         * src/port.h (struct PORT),
3139         * src/avr/ralloc.c (avr_assignRegisters),
3140         * src/avr/main.c,
3141         * src/ds390/ralloc.c (ds390_assignRegisters),
3142         * src/ds390/main.c,
3143         * src/hc08/ralloc.c (hc08_assignRegisters),
3144         * src/hc08/main.c,
3145         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3146         * src/mcs51/main.c,
3147         * src/pic/ralloc.c (pic14_assignRegisters),
3148         * src/pic/main.c,
3149         * src/pic16/ralloc.c (pic16_assignRegisters),
3150         * src/pic16/main.c,
3151         * src/xa51/ralloc.c (xa51_assignRegisters),
3152         * src/xa51/main.c,
3153         * src/z80/ralloc.c (z80_assignRegisters),
3154         * src/z80/ralloc.h,
3155         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3156         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3157         * src/SDCCcse.h,
3158         * src/SDCCdflow.c (computeDataFlow),
3159         * src/SDCCdflow.h,
3160         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3161         * src/SDCCloop.h,
3162         * src/SDCCcflow.c (*),
3163         * src/SDCCcflow.h,
3164         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3165         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3166         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3167         immedDom() returning wrong block; probably fixes bug #1160833)
3168
3169 2005-03-20 Borut Razem <borut.razem AT siol.net>
3170
3171         * support/scripts/inc2h.pl: WIN32 port
3172
3173 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3174
3175         * device/lib/makefile.in: added abs.c and labs.c
3176
3177 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3178
3179         * device/include/stdint.h: added
3180         * device/lib/abs.c: added
3181         * device/lib/labs.c: added
3182         * device/include/stdlib.h: added abs() and labs() prototypes
3183         * device/lib/libsdcc.lib: added abs and labs
3184         * device/include/float.h,
3185         * device/lib/_fsmul.c,
3186         * device/lib/printf_fast.c,
3187         * device/lib/printf_tiny.c: updated comments
3188
3189 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3190
3191         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3192         bug #1164313
3193
3194 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3195
3196         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3197         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3198
3199 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3200
3201         * device/lib/printf_large.c: removed inline assembly for portability and
3202           readability. Use printf_fast if speed or size are more important.
3203         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3204         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3205
3206 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3207
3208         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3209         prevent compiler warning
3210
3211 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3212
3213         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3214         moved to level 0 and declared as static. Also they are explicit
3215         placed in access bank. This was necessery because some times they
3216         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3217         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3218         optimizations. Currently only compare to unsigned char is implemented,
3219         * src/pic16/gen.c: added fReturnIdx array,
3220         * (struct resolvedIfx) is moved to gen.h and made public,
3221         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3222         * (aopForSym): added an optimization to directly store in stack of
3223         the operand of a SEND iCode,
3224         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3225         but as registers instead (AOP_REG) using the fReturnIdx array,
3226         * (pic16_freeAsmop): remove the freed register from the
3227         _G.sregsAlloc field,
3228         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3229         a compare of 'WREG',
3230         * (pic16_popGetTempRegCond): changed function prototype, now
3231         function takes also a bitVector argument v which holds the current
3232         set of registers that are allocated for stack access by aopForSym,
3233         registers allocated in aopForSym for accessing stack symbols are not
3234         any more part of the functions usedRegs field,
3235         * (genCall): some times aopOp is called for a stack variable to be
3236         send, aopForSym might perform the push, if this is true make sure
3237         that genCall doesn't push the variable twice by testing _G.resDirect,
3238         * (genFunction): changed testing for unspecified interrupt number
3239         from 256 to INTNO_UNSPEC,
3240         * modified selection scheme of frame pointer generation. Previously
3241         if function did use local registers a frame pointer was generated,
3242         now a frame pointer is generated only if function has arguments
3243         (that need PLUSW2 register access), or has stack arguments, or the
3244         compiler is not instructed to omit the frame pointer,
3245         * (genEndFunction): before restoring local registers that were saved
3246         in the function preamble, also restore the registers that *might*
3247         have been allocated for stack access,
3248         * (genRet): removed some old comments,
3249         * (genCmp, the active (RN's) version): added a call to the
3250         pic16_genCmp_special function to perform the compare with a more
3251         robust and optimized way,
3252         * (genInline): a feature has been added in inline code generation,
3253         which allows a wildcard variable substitution when writing inline
3254         assembly. Code is incomplete and experimental therefore undocumented,
3255         * (genCast): changed order of aopOp for result and right to allow
3256         aopForSym to directly load the result if possible,
3257         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3258         perform an optimized compare on some selected special occasions,
3259         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3260         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3261         generate an IVT any more,
3262         * src/pic16/main.c (pic16_optionsTable): added command line option
3263         --optimize-cmp,
3264         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3265         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3266         macros,
3267         * src/pic16/NOTES: Raphael Neider added in list of active developers
3268         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3269         jumptable_end to prevent bug #,
3270         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3271         inCond and outCond fields,
3272         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3273         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3274         turn off register spilling,
3275         * (packRegsForOneUse): synced with other ports' versions although it
3276         is not used currently,
3277         * (pic16_packRegisters): added an optimization while reading
3278         structure bitfields, some registers may be saved (malloc code is
3279         decreased by 80 bytes)
3280
3281 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3282
3283         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3284         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3285         this can be optimized more?
3286
3287 2005-03-10 Raphael Neider <rneider AT web.de>
3288
3289         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3290           genNearPointerGet): (hopefully) fixed access to bitfields via
3291           pointers (p->bitN = x; and x = p->bitN; failed)
3292
3293 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3294
3295         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3296
3297 2005-03-09 Raphael Neider <rneider AT web.de>
3298
3299         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3300
3301 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3302
3303         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3304         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3305           (regTypeNum): set REG_BIT type if necessary
3306         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3307         * support/regression/tests/critical.c: check bug 1144613
3308
3309 2005-03-02 Raphael Neider <rneider AT web.de>
3310
3311         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3312
3313 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3314
3315         * src/avr/ralloc.c (serialRegAssign),
3316         * src/ds390/ralloc.c (serialRegAssign),
3317         * src/hc08/ralloc.c (serialRegAssign),
3318         * src/mcs51/ralloc.c (serialRegAssign),
3319         * src/pic/ralloc.c (serialRegAssign),
3320         * src/pic16/ralloc.c (serialRegAssign),
3321         * src/xa51/ralloc.c (serialRegAssign),
3322         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3323
3324 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3325
3326         * src/SDCCast.c (decorateType): fixed bug 1124787
3327
3328 2005-02-20 Hubert Sack <sack AT digiplan.de>
3329         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3330
3331         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3332         patch #1121755
3333
3334 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3335
3336         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3337         to keep the correct label reference count when adding/removing references
3338         to labels. A peephole file using this is appended to patch #1144962.
3339
3340 2005-02-14 Raphael Neider <rneider AT web.de>
3341
3342         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3343         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3344         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3345           retrievals of result operand's value on assignment
3346
3347 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3348
3349         * device/include/pic16/string.h: modified prototype for memccpy()
3350         to memccpy(void *, void *, char, size_t)
3351         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3352         check whether to omit frame pointer or not,
3353         * (genInline): convert all occurences of "\n" to LF in inline
3354         assembler blocks, this helps formatting the inline text,
3355         * (pic16_loadFSR0): modified prototype,
3356         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3357         removed some 8051 legacy code,
3358         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3359         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3360         before allocating temporary registers in functions,
3361
3362 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3363
3364         * support/regression/tests/bitvars.c: corrected the "fix"
3365
3366 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3367
3368         * support/regression/tests/bitvars.c,
3369         * support/regression/tests/bitwise.c,
3370         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3371
3372 2005-02-10 Raphael Neider <rneider AT web.de>
3373
3374         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3375           different size for Alpha
3376         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3377
3378 2005-02-09 Raphael Neider <rneider AT web.de>
3379
3380         * src/SDCC.lex(doPragma) : save and restore warning options as well
3381           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3382         * have #pragma less_pedantic set the errorlevel to WARNING
3383           (fixes #1117001)
3384         * (cloneOptimize) : fixed wrong malloc's size
3385         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3386           facilitate correct handling of #pragma (save|restore)
3387
3388 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3389
3390         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3391
3392 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3393
3394         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3395
3396 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3397
3398         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3399
3400 2005-02-02 Raphael Neider <rneider AT web.de>
3401
3402         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3403         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3404         * (pic16_storeForReturn): fixed to allow returning function pointers
3405         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3406         * device/include/pic16/{stddef.h,stdbool.h}: added
3407
3408 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3409
3410         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3411
3412 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3413
3414         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3415         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3416          appeared to be required
3417
3418 2005-01-31 Borut Razem <borut.razem AT siol.net>
3419
3420         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3421           include/mcs51 and include/z80 directories to the package
3422
3423 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3424
3425         * src/hc08/gen.c (genFunction): fixed bug #1112752
3426
3427 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3428
3429         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3430
3431 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3432
3433         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3434
3435 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3436
3437         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3438
3439 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3440
3441         * device/include/c8051fxxx.h: removed these 6 files
3442         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3443
3444 2005-01-26 Raphael Neider <rneider AT web.de>
3445
3446         * src/pic16/gen.c (genAssign): fixed assignment from longs
3447           in codespace (were cut to three bytes)
3448         * (genDummyRead): implemented (except for CODESPACE...),
3449           fixed bug #1108575
3450         * src/pic16/glue.c (emitStatistics): beautified
3451         * device/lib/pic16/libm/Makefile: added include path
3452
3453 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3454
3455         * src/z80/gen.c (aopPut): fixed bug #1103902
3456
3457 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3458
3459         * device/lib/expf.c: fixed bug #1095792
3460
3461 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3462
3463         * device/lib/pic16/libm: added Math library sources
3464
3465 2005-01-24 Raphael Neider <rneider AT web.de>
3466
3467         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3468           to enable upcast to pCodeOpReg2 (there is no type tag to
3469           differenciate the two and pic16_popGet2p cast into PCOR2)
3470         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3471           (sizeof(sectNames) changed to sizeof(sectName))
3472           Both patches fix segfaults under MinGW.
3473
3474 2005-01-23 Raphael Neider <rneider AT web.de>
3475
3476         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3477           Safe_[mc]?alloc()'ed variables
3478         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3479           of (byte sized) temporaries (assign them to WREG for now)
3480         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3481           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3482           this might fix SIGSEGVs on MinGW...
3483         * src/SDCCopt.c (killDeadCode): restored original behaviour
3484           (volatile operands might get thrown away though)
3485
3486 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3487
3488         * src/pic16/gen.c: fixed bug #1106975,
3489         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3490         pointer update, INTCON is saved, global interrupts are disabled and
3491         restored after updateing TOS.
3492         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3493         * added function attribute 'shadowregs' to take advantage of shadow
3494         registers,
3495         * added function attribute 'wparam' as an alternative to the wparam
3496         pragma,
3497         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3498         user declares a non-ISR function as 'shadowregs',
3499         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3500
3501 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3502
3503         * .version: bumped version number to 2.4.8
3504         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3505         pic16 port,
3506         * device/lib/pic16/libio/i2c/: I2C module support library,
3507         * device/include/pic16/i2c.h: I2C support library header,
3508         * device/lib/pic16/libc/stdio/: standard IO support sources,
3509         * (printf_small.c): printf_small() source, supports float print,
3510         * (printf_tiny.c): printf_tiny() source, does not support floats,
3511         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3512         enable global optimizations for entire library source, other
3513         Makefiles in the source tree are also modified to reflect this,
3514         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3515         function,
3516         * doc/sdccman.lyx: updated to reflect new changes,
3517         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3518         sym->onStack if-case,
3519         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3520         sbit, idata, _idata, xdata, _xdata,
3521         * added pragma library, to link an external library, (see doc),
3522         * removed command line options, --pomit-config-words, --pomit-ivt,
3523         --pleave-reset-vector,
3524         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3525         when calling assembler to reflect memory model used, also define
3526         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3527         reflect stack model used,
3528         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3529         on stack return NULL,
3530
3531 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3532
3533         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
3534           of the operands is volatile. Fixes #1020220
3535
3536 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3537
3538         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
3539         * (OptimizeRegUsage): make sure that there is really no other flow where
3540           the first pCode is used
3541
3542 2005-01-22 Raphael Neider <rneider AT web.de>
3543
3544         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
3545           to fix #1106967 (pCode->seq are not set up correctly)
3546
3547 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3548
3549         * src/SDCCglue.c (glue): make sure code area is declared before the
3550         static initialization area.
3551
3552 2005-01-21 Raphael Neider <rneider AT web.de>
3553
3554         * device/lib/Makefile.in: fixed test for pic16 install dir
3555         * device/lib/pic16/*/Makefile*: modified compile flags to enable
3556           optimizations
3557         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
3558           added --optimize-goto compiler switch and pragma wparam documentation
3559         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
3560         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
3561           and PRODH closing bug #1071770 (peephole optimizer)
3562
3563 2005-01-19 Raphael Neider <rneider AT web.de>
3564
3565         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
3566           cmdLine buffers (used when calling sdcpp...) are large enough
3567           (MAX_PATH=256 truncates arguments leading to system halts when
3568           used in MinGW...)
3569         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
3570         * (genUminus): rewritten to for efficiency
3571         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
3572           used uninitialized in some cases)
3573         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
3574           copy the third byte from the int -- now assumes 0x80 (data memory)
3575         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
3576           operands (genAddLit expects the iCode's operands to swapped as
3577           well), fixed leftover bytes (crashed for short left operands)
3578         * (pic16_genMinusDec): performance improvements, removed false
3579           PIC14 emitSKPNCs
3580         * (pic16_genMinus): fixed to cope with differently sized operands
3581         * src/pic16/glue.c (pic16_glue): added new banksel optimization
3582           for --obanksel > 1
3583         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
3584         * src/pic16/graph.[ch]: implementation of directed graphs, used by
3585           new banksel optimization
3586         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
3587           analysis for temporary registers (segfaults...)
3588         * src/pic16/peeph.def: added rule
3589
3590 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
3591
3592         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
3593         which converts a float number to its ASCII representation
3594         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
3595         functions to convert the fractional and integer part of a float to ASCII,
3596         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
3597         realloc.c): added _MALLOC_SPEC to explicit place variables in data
3598         ram
3599         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
3600         _STATMEM macros,
3601         * device/include/pic16/adc.h: added GPL info,
3602         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
3603         a pCodeOp as tested operand,
3604         * (genNearPointerGet): optimized bit testing, does not use
3605         intermediate register for bit value, test directly instead with
3606         BTFSS, BTFSC, works only for single bits,
3607         * (genpic16Code): dump the name of the iCode in the asm,
3608         * src/pic16/ralloc.c (decodeOp): removed static declaration and
3609         renamed to pic16_decodeOp,
3610         * (serialRegAssign): do not allocate a temporary register for iCode
3611         sequences that test a single bit for 1/0
3612
3613 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
3614
3615         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
3616         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
3617         access stack and frame pointers. They are initially assigned to
3618         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
3619         accessing SFRs. Updated all occurences of modification of stack or
3620         frame pointer in gen.c and pcode.c,
3621         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
3622         assigning of a literal value to pointers,
3623         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
3624         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
3625         selected
3626
3627 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
3628
3629         * doc/sdccman.lyx: update documentation about stack pragma, added
3630         some info for stack memory models
3631
3632 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3633
3634         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
3635
3636 2005-01-08 Raphael Neider <rneider AT web.de>
3637
3638         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
3639           udata sections to fix bug #1097823
3640
3641 2005-01-05 Raphael Neider <rneider AT web.de>
3642
3643         * src/pic16/gen.c (genGenericShift): added handling of differently
3644           sized left operand and result
3645
3646 2005-01-04 Raphael Neider <rneider AT web.de>
3647
3648         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
3649         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
3650           to hold the condition bit)
3651         * added new version of genCmp (old code available via #define)
3652         * added new version of genShiftLeft/genShiftRight in a generic
3653           way, now supports shifting by negative values
3654         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
3655           shiftCount (expected by genGenericShift)
3656         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
3657         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
3658           dump
3659         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
3660           is an invalid literal too...)
3661
3662 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
3663
3664         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
3665         from Raphael Neider,
3666         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
3667         for 8-bit literals. This fixes some literal operands which are sign
3668         extended to 16-bits ints when instruction needs only 8-bits.
3669
3670 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
3671
3672         * device/lib/logf.c: added mcs51 assembly version
3673         * device/lib/expf.c: added mcs51 assembly version
3674         * device/lib/_logexpf.c: new shared asm code for expf and logf
3675         * device/include/math.h: add defines for assembly math library
3676         * device/lib/Makefile.in: build new _logexpf.c
3677         * device/lib/libfloat.lib: use new _logexpf.c
3678
3679 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3680
3681         * src/pic/device.c
3682         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
3683           device types which have less than 0x7f registers.
3684
3685 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3686
3687         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
3688
3689 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
3690
3691         * device/lib/printf_fast.c: only build on supported arch.
3692         * device/lib/printf_tiny.c: only build on supported arch.
3693         * device/lib/printf_fast_f.c: only build if asm float lib
3694         * device/lib/_fsget1arg.c: only build if asm float lib
3695         * device/lib/_fsget2args.c: only build if asm float lib
3696         * device/lib/_fsnormalize.c: only build if asm float lib
3697         * device/lib/_fsreturnval.c: only build if asm float lib
3698         * device/lib/_fsrshift.c: only build if asm float lib
3699         * device/lib/_fsswapargs.c: only build if asm float lib
3700         * device/include/stdio.h: don't provide print_fast,
3701           print_fast_f, print_tiny prototypes if --xstack used
3702
3703 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
3704
3705         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
3706         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
3707           to the SOURCES
3708
3709 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
3710
3711         * device/lib/printf_fast_f.c: same as printf_fast, but
3712           with floating point enabled
3713         * device/lib/printf_fast.c: minor tweaks
3714         * device/include/stdio.h: add printf_fast_f
3715
3716 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
3717
3718         * src/SDCCmain.c: make --float-reent default for mcs51
3719         * device/lib/_fsadd.c: added mcs51 assembly version
3720         * device/lib/_fssub.c: added mcs51 assembly version
3721         * device/lib/_fsmul.c: added mcs51 assembly version
3722         * device/lib/_fsdiv.c: added mcs51 assembly version
3723         * device/lib/_fseq.c: added mcs51 assembly version
3724         * device/lib/_fsneq.c: added mcs51 assembly version
3725         * device/lib/_fsgt.c: added mcs51 assembly version
3726         * device/lib/_fslt.c: added mcs51 assembly version
3727         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
3728         * device/lib/Makefile.in: add _fscmp to build
3729         * device/lib/libfloat.lib: add _fscmp to build
3730
3731 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
3732
3733         * device/lib/_fs2slong.c: added mcs51 assembly version
3734         * device/lib/_fs2sint.c: added mcs51 assembly version
3735         * device/lib/_fs2schar.c: added mcs51 assembly version
3736         * device/lib/_fs2ulong.c: added mcs51 assembly version
3737         * device/lib/_fs2uint.c: added mcs51 assembly version
3738         * device/lib/_fs2uchar.c: added mcs51 assembly version
3739         * device/lib/_slong2fs.c: added mcs51 assembly version
3740         * device/lib/_sint2fs.c: added mcs51 assembly version
3741         * device/lib/_schar2fs.c: added mcs51 assembly version
3742         * device/lib/_ulong2fs.c: added mcs51 assembly version
3743         * device/lib/_uint2fs.c: added mcs51 assembly version
3744         * device/lib/_uchar2fs.c: added mcs51 assembly version
3745         * device/include/float.h: added #define to select asm vs c
3746
3747 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
3748
3749         * device/lib/printf_fast.c: improvements to float output
3750         * device/include/float.h: add defines for assembly float library
3751         * device/lib/_fsget1arg.c: receive 1 float arg
3752         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
3753         * device/lib/_fsnormalize.c: normalize a float
3754         * device/lib/_fsreturnval.c: return float, various helper routines
3755         * device/lib/_fsrshift.c: right shift a float's mantissa
3756         * device/lib/_fsswapargs.c: swap 2 floats
3757         * device/lib/Makefile.in: build these 6 new files for mcs51
3758         * device/lib/libfloat.lib: add these 6 files to the library
3759
3760 2004-12-26 Borut Razem <borut.razem AT siol.net>
3761
3762         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
3763           built by gcc 3.4.2
3764
3765 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
3766
3767         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
3768           and fully reentrant and register bank neutral.
3769         * device/lib/printf_fast.c: added float (not enabled by default),
3770           added compact/slower integer (also not enabled by default),
3771           improved size/speed of fast integer code, other minor changes
3772         * device/include/stdio.h, device/lib/Makefile.in,
3773           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
3774
3775 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
3776
3777         * src/pic16/pcode.c: declaring variables other than at the start of a
3778           block is not supported in C by VC6.
3779
3780 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
3781
3782         * applied a previous patch from Raphael Neider that wasn't included
3783         in the previous commits, which fixes infinite loops within jumptable
3784         improvements,
3785         * made some fixes that previous patches introduced
3786
3787 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
3788
3789         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
3790         that fixes an issue with AOP_PCODE asmop's offset,
3791         * (pic16_popCopyReg): update instance field too,
3792         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
3793         function of pic port,
3794         * (genCmp, genAnd, genAssign),
3795         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
3796
3797 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
3798
3799         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
3800         variables initial values to idata section,
3801         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
3802         variables in some functions. This utilizes parmBytes field of iCode
3803         structure to hold the offset of the variable in stack. (might be
3804         able to use the stack field too?)
3805         * applied patch from Raphael Neider # ### , # ###
3806         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
3807         variable initial values in idata section,
3808         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
3809         for static variables with initial value
3810         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
3811         applied fix in while loop from Raphael Neider.
3812
3813 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
3814
3815         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
3816         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
3817         * src/ds390/ralloc.c (serialRegAssign): spill bits
3818         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
3819         * support/Util/SDCCerr.c,
3820         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
3821         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
3822         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
3823
3824 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
3825
3826         * device/include/sdcc-lib.h: inserted LGPL, added includes
3827           asm/ds390/features.h and asm/mcs51/features.h
3828         * device/include/asm/default/features.h,
3829         * device/include/asm/gbz80/features.h,
3830         * device/include/asm/z80/features.h: added empty _AUTOMEM
3831           and _STATMEM
3832         * device/include/asm/ds390/features.h,
3833         * device/include/asm/mcs51/features.h: added files with defines for
3834           _AUTOMEM and _STATMEM indicating automatic and static storage class
3835         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
3836         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
3837         * src/SDCCicode.c (geniCodeCast),
3838         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
3839         * src/SDCCloop.c (loopInduction): removed unused variable lr
3840         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
3841           to convertToFcall to include char modulo (RFE 1065037), added check
3842           if left operand is unsigned and use abs of literal value
3843         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
3844           as it doesn't work after conversion from peephole.def to peephole.rul
3845         * src/mcs51/gen.c (toBoolean): added check for size,
3846           (genModOneByte): optimized code for signed char modulo a literal
3847           power of 2 (thanks to Hubert Sack),
3848           (genRRC): removed unnecessary "clr c",
3849           (genRLC): replaced "add a,acc" with cheaper "rlc a"
3850         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
3851           jump optimization,
3852           swapped rules 256.c and 256.d,
3853           extended 256.d by using new multiple checks (thanks Erik),
3854           added rules 256.e and 256.f,
3855           updated rule 261.a and 261.b to new generated code
3856         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
3857
3858 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3859
3860         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
3861           induction related bugs, including first part of bug #1074377
3862
3863 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
3864
3865         * applied patch from bug-report #1076292,
3866         * applied patches for genAnd and Goto-optimizations for Raphael
3867         Neider,
3868         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
3869         dump a less iCode information,
3870         * src/pic16/device.h (pic16_options_t): added field debgen,
3871         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
3872         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
3873         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
3874         puclic,
3875         * (various functions): added macros FENTRY and FENTRY2 to functions,
3876         to emit function prologue,
3877         * (various functions): fixed indentation,
3878         * (genNearPointerGet): fixed loading of FSR0,
3879         * (genPackBits): applied patch from Raphael Neider to fix updating
3880         of FSR0 and touching only the modified bits,
3881         * src/pic16/genarith.c (various functions): added macros FENTRY to
3882         emit function prologue in comments,
3883         * src/pic16/pcode.h: added functions debugf2, debugf3,
3884         * src/pic16/ralloc.c: partial fix for packForPush caused
3885         segmentation fault,
3886
3887 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3888
3889         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
3890           <stsp AT users.sourceforge.net> with reversed byte order
3891         * support/regression/tests/rotate.c: added (ds390 skips some tests)
3892
3893 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3894
3895         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
3896           bug #1074377
3897         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
3898         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
3899
3900 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
3901
3902         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
3903
3904 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3905
3906         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
3907           conditions,
3908           (setFromConditionArgs): friendly operand parser for peephole rules,
3909           (operandBaseName, operandsNotRelated): new peephole condition
3910           "operandsNotRelated" -- similar to "operandsNotSame", but takes
3911           architecture specific register naming into account, handles n-way
3912           comparisons, and supports quoted literals
3913         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
3914
3915 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3916
3917         * src/mcs51/peeph.def: fixed bug #1076940
3918
3919 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
3920
3921         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
3922
3923 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3924
3925         Adding support for replacing ljmps with sjmps in jumptables
3926         generated for switch statements. For now you need to set the
3927         environment variable SDCC_SJMP_JUMPTABLE to enable this.
3928         Now 4 algorithms for mcs51 jumptable generation are used:
3929         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
3930         addresses loaded pc-relative for up to 112 cases and stack-pushing
3931         target addresses loaded with offset from dptr for up to 256 cases.
3932
3933         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
3934         * src/mcs51/main.c: adapted constants for switch table generation
3935         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
3936
3937 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
3938
3939         * device/lib/printf_large.c (_print_format): fixed bug 1073386
3940         * support/regression/tests/bug1057979.c: added test for bug 1073386
3941
3942 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
3943
3944         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
3945         compilers
3946
3947 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
3948
3949         * src/pic16/device.h,
3950         * src/pic16/genarith.c,
3951         * src/pic16/glue.c,
3952         * src/pic16/main.c,
3953         * src/pic16/pcode.c: applied patches #1068154 and #1070213
3954
3955 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
3956
3957         Large cummulative patch for pic16 port.
3958         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
3959         to call when a stack overflow occurs,
3960         * (malloc.h): added CVS Id tag,
3961         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
3962         variable,
3963         * added libc directory. The current version of LibC contains string
3964         functions, ctype functions and macros and some functions of the
3965         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
3966         be extensively tested in the future. Standard disclaimer here.
3967         Library is not automatically build yet. But one can build it by
3968         invoking 'make' inside the libc directory.
3969         * added ADC library under libio. Preliminary version yet.
3970
3971         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
3972         * src/pic16/gen.c (aopForRemat): asmop size is filled by
3973         aopForRemat() now and not by pic16_aopOp(),
3974         * (pic16_popGetTempReg): removed warning messgae when allocating
3975         temporary registers, its a buggy feature and will be removed,
3976         * (pic16_popGet): set register instance field in AOP_CRY,
3977         * (pic16_outBitC): fixed for results in size greater than 1,
3978         * (genUminusFloat): fixed for pic16, ported code from mcs51,
3979         * (pic16_storeForReturn): optimized return of 0,
3980         * (genCmp): experimental code for new genCmp which uses PIC18's
3981         special compare&skip instructions. Initial tests fail some times
3982         with variables grater than 1 byte in size, so new code is disabled,
3983         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
3984         a single bit,
3985         * (genCast): began a fix to optimize the casting of a bit to another
3986         bit, now assigning a bitfield to another bitfield will fail, sorry,
3987         * src/pic16/main.c: disabled the use of lr-support feature,
3988         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
3989         * added some function prototypes, added function _debugf prototype,
3990         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
3991         bits with offset (case PO_GPR_BIT),
3992         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
3993         command line,
3994         * (isBankInstruction): modified to return 0 for no banking instruction,
3995         and 1 for banking instruction,
3996         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
3997         caused stop processing pCodes after a inline assembly block,
3998         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
3999         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4000         registers when it shouldn't,
4001         * src/pic16/ralloc.c (allocReg): add preliminary support for
4002         supporting a limited set of temporary registers,
4003
4004 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4005
4006         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4007           genDataPointerSet): ensure assignments always copy in MSB to LSB
4008           order,
4009           (loadRegFromAop): recognize CLRH optimization,
4010           (genFunction): optimize RECEIVE iCodes in reentrant functions
4011
4012 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4013
4014         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4015           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4016           selected.
4017         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4018         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4019           contiguous with data
4020
4021 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4022
4023         * device/lib/_gptrget.c (_gptrget),
4024         * device/lib/_gptrgetc.c (_gptrgetc),
4025         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4026           instead of sjmp to ret
4027         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4028           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4029
4030 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4031
4032         * .version: bumped version to 2.4.7
4033         * device/lib/_gptrget.c (_gptrget): is now _naked
4034         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4035         * device/lib/_gptrput.c (_gptrput): is now _naked
4036         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4037           (createFunction): fixed xstack
4038         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4039         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4040           or bit either,
4041           (geniCodeCritical): store original interrupt state in an iTemp bit
4042           var unless stack-auto
4043         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4044         * src/SDCCmain.c (setIncludePath): added include/target to search path
4045         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4046         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4047           prototype,
4048           (processFuncArgs): put bit vars in bit area
4049         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4050           unsaveRBank): fixed xstack,
4051           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4052           (genFunction, genEndFunction): fixed xstack,
4053           (genAssign): optimization don't walk backwards through mem
4054         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4055         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4056         * support/regression/Makefile: also make library (for stack-auto) when
4057           making "all" and added "test-mcs51-xstack-auto"
4058         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4059         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4060         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4061         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4062         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4063           make-library by MAKE_LIBRARY
4064         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4065           regression tests for xstack
4066         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4067         * support/regression/tests/critical.c: test for critical on mcs51
4068
4069 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4070
4071         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4072           built version of sdcc instead of installed version
4073
4074 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4075
4076         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4077         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4078           vprintf.c now
4079         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4080         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4081           WARNING: remove device/lib/build/z80/printf.o by hand when
4082           updating from previous build!
4083         * device/lib/z80/printf.c: updated comment
4084         * support/regression/tests/bug1057979.c: test all ports now
4085         * support/regression/tests/bug1065458.c: file added
4086
4087 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4088
4089         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4090           *_start and *_end symbols for static functions
4091
4092 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4093
4094         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4095           and search crt0.o in all library paths,
4096           (setIncludePath): proper handling of --nostdinc,
4097           (setLibPath): proper handling of --nostdlib
4098         * support/regression/Makefile,
4099         * support/regression/ports/ds390/spec.mk,
4100         * support/regression/ports/gbz80/spec.mk,
4101         * support/regression/ports/hc08/spec.mk,
4102         * support/regression/ports/mcs51/spec.mk,
4103         * support/regression/ports/mcs51-large/spec.mk,
4104         * support/regression/ports/mcs51-stack-auto/spec.mk,
4105         * support/regression/ports/z80/spec.mk: use include and lib files from
4106           built version of sdcc instead of installed version
4107         * doc/sdccman.lyx: fixed typo in --nostdinc
4108
4109 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4110
4111         * src/pic/pcode.c,
4112         * src/pic/device.c,
4113         * src/pic/ralloc.c,
4114         * src/pic/gen.c : added support to generate code for struct bit fields.
4115
4116 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4117
4118         * as/xa51/xa_version.h,
4119         * device/include/errno.h,
4120         * device/include/regc515c.h,
4121         * device/lib/_itoa.c,
4122         * device/lib/_ltoa.c,
4123         * device/lib/ser_ir_cts_rts.c,
4124         * sim/ucsim/xa.src/glob.cc,
4125         * sim/ucsim/xa.src/inst_gen.cc,
4126         * sim/ucsim/xa.src/xa_bit.cc,
4127         * sim/ucsim/xa.src/xa_sfr.cc,
4128         * sim/ucsim/z80.src/inst_dd.cc,
4129         * sim/ucsim/z80.src/inst_fdcb.cc,
4130         * support/scripts/keil2sdcc.pl,
4131         * src/pic16/pic16.dsp,
4132         * src/pic16/pic16a.dsp: corrected cvs line endings
4133         * device/lib/printf_large.c: fixed bug 1057979
4134         * src/pic16/gen.c: fixed non-C standard code
4135         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4136         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4137         * support/regression/ports/mcs51/support.c: reload T1 asap
4138         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4139           pdata use and clear idata startup behaviour
4140         * support/regression/tests/bug1057979.c: added
4141
4142 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4143
4144         * device/examples/ds390/ow390/ad26.h,
4145         * device/examples/ds390/ow390/cnt1d.h,
4146         * device/examples/ds390/ow390/crcutil.c,
4147         * device/examples/ds390/ow390/ownet.h,
4148         * device/examples/ds390/ow390/owsesu.c,
4149         * device/examples/ds390/ow390/swt12.h,
4150         * device/examples/ds390/ow390/swtoper.c,
4151         * device/examples/ds390/ow390/temp10.h,
4152         * device/examples/ds390/ow390/thermodl.c,
4153         * device/examples/ds390/tinitalk/tinitalk.dsp,
4154         * device/examples/ds390/tinitalk/tinitalk.dsw,
4155         * device/examples/mcs51/clock/hw.h,
4156         * device/examples/mcs51/simple2/go.bat,
4157         * device/examples/serialcomm/windows/serial.h,
4158         * device/examples/xa51/dummy.c,
4159         * device/examples/xa51/hello.c,
4160         * device/include/80c51xa.h,
4161         * device/include/at89x051.h: corrected cvs line endings
4162
4163 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4164
4165         * src/pic16/main.c (options): added command line --gstack, to trace
4166         stack over/under flows,
4167         * added pragma 'wparam' to allow passing first byte of function
4168         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4169         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4170         call to __gstack_test function and sets up the symbol as extern,
4171         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4172         * popaop): added call to pic16_testStackOverflow,
4173         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4174         wparamList list,
4175         * (genCall, genPcall): now all parameters are passed via stack
4176         except in functions that are pass to wparam pragma in which WREG is
4177         used too,
4178         * (genPcall): REENTRANT flag is checked to see if variable prototype
4179         contains reentrant keyword, don't call a non-reentrant function, via
4180         a reentrant function pointer or vice versa, functions are never
4181         passed via WREG,
4182         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4183         D.Winkler,
4184         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4185         SIGSEGV when accessing a NULL register stucture,
4186         * (pic16_printGPointerType): modified to handle UPPER modifier for
4187         function initializers, changed prototype of function to simpler one,
4188         * (pic16_printIvalFuncPtr): check to see if function is already
4189         added in externs list,
4190         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4191         optimized a move from W to SFR with a move to the same register
4192         later after a CALL,
4193         * device/lib/pic16/debug: NEW directory, contains debug features
4194         which are enabled when linking with libdebug.lib, currently command
4195         line option --gstack enables stack pointer tracing for over/under
4196         flow, corresponding sources are in debug/gstack
4197
4198 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4199
4200         * doc/sdccman.lyx: updated SDCC version,
4201         * (PIC16 port): update list of command line options,
4202         * src/pic16/device.h (structure pic16_options_t): added field gstack
4203         to enable stack overflow tracing on push/pops,
4204         * src/pic16/device.c (statistics structure): added statistics
4205         structure,
4206         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4207         pic16_dump_int_registers): increase statistics counters for each
4208         * variable which is encountered
4209         * (pic16_dump_usection): emit each .udata variable to its own udata
4210         section,
4211         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4212         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4213         parameters via stack, otherwise use old scheme,
4214         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4215         assembler output file,
4216         * src/pic16/main.c: added command line options --gstack to enable
4217         push/pop tracing for stack overflow,
4218         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4219         instructions): added size of each instruction,
4220         * (pic16_countInstruction): estimate size of instructions in
4221         the_pFile list, inline assembly blocks are not counted,
4222         * (pic16_FixRegisterBanking): trace previous register usage, when
4223         banksel optimizations is greater than 0, don't emit a redudant
4224         banksel directive,
4225
4226 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4227
4228         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4229         * src/pic16/ralloc.c : applied same fix for pic16.
4230         * src/pic/gen.c : tidied it up a little.
4231
4232 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4233
4234         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4235         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4236
4237 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4238
4239         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4240
4241 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4242
4243         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4244         non-reentrant function __modsint in the interrupt function (thus
4245         corrupting math operations during serial I/O)
4246         * device/lib/ser_ir.c: as above, changed buffersize
4247         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4248         256.c,d for zeroing
4249         * doc/Makefile: added option -t for rsync
4250
4251 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4252
4253         * src/SDCCast.h (struct ast),
4254         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4255
4256 2004-10-20 Borut Razem <borut.razem AT siol.net>
4257
4258         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4259         package
4260
4261 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4262
4263         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4264         makefile targets,
4265         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4266         support functions to replace long sequences of MOVFF's from access
4267         bank registers to stack and vice versa,
4268         * src/pic16/device.h: added new field opt_flags, where optimization
4269         flags can be set to enable certain features,
4270         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4271         * pBlock, (genFunction, genEndFunction): surroung loop for
4272         saving/loading used registers in stack with PC_INFO pCodes,
4273         INF_LREGS. Code in between can then be optimized by pCode optimizer
4274         to support function calls,
4275         * (genDataPointerSet): fixed bug which loaded float fields in
4276         structures with corrupt data,
4277         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4278         in a standard way debug info on stderr. Feature used for developing
4279         and debugging only,
4280         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4281         obsolete chunks of code,
4282         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4283         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4284         * pic16/src/pcode.c (pic16_newpCodeInfo,
4285         * (pic16_newpCodeOpLocalRegs),
4286         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4287         feature,
4288         * (pic16_pCodeConstString): printing of the initial value of a
4289         symbol as a comment is inhibited since parsing was already done by
4290         copyStr and output is corrupt,
4291         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4292
4293 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4294
4295         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4296
4297 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4298
4299         * as/mcs51/lkarea.c: removed old K&R style,
4300           (lnksect): changed check on boundary error,
4301           (lnksect2): changed check on boundary error,
4302           (lnksect2): extend XSTK to end of page if size = 1
4303         * as/mcs51/lkmain.c: removed old K&R style,
4304           (Areas51): create l_IRAM symbol
4305         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4306         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4307           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4308         * device/lib/_mullong.c: added version to be compiled with xstack
4309         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4310         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4311         * device/lib/mcs51/crtxstack.asm: fixed comment
4312         * src/SDCCglue.c: maxInterrupts defaults to 0,
4313           (emitMaps): added pdata,
4314           (createInterruptVect): (re)moved default,
4315           (glue): added pdata,
4316           (glue): moved __start__xstack to XSTK with default size 1
4317         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4318           and options.float_rent when options.stackAuto is set,
4319           (linkEdit): only write XDATA_NAME if provided on command line
4320         * src/SDCCmem.h,
4321         * src/SDCCmem.c: added pdata
4322         * src/port.h: added pdata_name to PORT
4323         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4324           (saveRegisters, unsaveRegisters): removed usage of B,
4325           (genMinus): fixed accumulator clash,
4326           (genJumpTab): added comment, this needs another look
4327         * src/mcs51/gen.c: added check for "B in use" paranoia,
4328           added pushB() and popB()
4329         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4330           chance
4331         * src/avr/main.c,
4332         * src/ds390/main.c,
4333         * src/hc08/main.c,
4334         * src/mcs51/main.c,
4335         * src/pic/main.c,
4336         * src/pic16/main.c,
4337         * src/xa51/main.c,
4338         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4339           added PSEG (PAG,XDATA) or NULL to port specifier
4340         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4341         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4342           (_mcs51_genInitStartup): removed __start__xstack equ,
4343           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4344         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4345         * src/z80/gen.c (_rleAppend): fixed warnings
4346         * support/regression/tests/zeropad.c: added pdata test
4347         * .version: bumped to 2.4.6
4348
4349 2004-10-17 Borut Razem <borut.razem AT siol.net>
4350
4351         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4352         as a part of nightly build
4353
4354 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4355
4356         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4357         WREG holds the first byte function parameters,
4358         * (aopForSym): take special case for symbols which are in FARSPACE
4359         but in CODESPACE too,
4360         * (assignResultValue): modified to take into account _G.useWreg,
4361         * (genCall): don't use wreg for parameter passing when function is
4362         declared as reentrant, too, added optimization INCF to stack
4363         pointer when stack parameter count is 1,
4364         * (genFunction, genEndFunction): refurnished and fixed to not using
4365         wreg for passing parameters when function has varargs or is
4366         reentrant, fixed bug with symbol name compare for generating
4367         functions in absolute address,
4368         * (pic16_storeForReturn): refurnished,
4369         * (genCmp): began writing a new version of the function, not ready
4370         yet, therefore it is disabled,
4371         * (genAssign): do not read code memory when assigning a function to
4372         a pointer function,
4373         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4374         array of characters, not pointer,
4375         * (pic16initialComments): in debug mode emit an .ident directive for
4376         the assembler,
4377         * (_process_pragma): emit a new warning type (internal to pic16)
4378         when setting stack to default length, emit a similar warning when
4379         placing a function at absolute address and address is not word aligned
4380         * (_pic16_parseOptions): added 'return TRUE' statement,
4381         * (_pic16_linkEdit): if compiling a source, then add the source's
4382         file object, first in the list of objects to link,
4383
4384 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4385
4386         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4387         * src/pic/main.c : removed VC warning.
4388         * src/pic/gen.c : changed comment.
4389
4390 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4391
4392         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4393         reference to a deprecated symbol _GPTRREG was causing failure to
4394         link. Thanks G. M. Gallant for the info.
4395
4396 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4397
4398         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4399         comments for Bugs item #954788.
4400
4401 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4402
4403         * src/pic16/device.c (pic16_dump_gsection,
4404         * pic16_groupRegistersInSection): handle symbols declared to be in
4405         access bank differently,
4406         * src/pic16/gen.c (struct _G): added field resDirect,
4407         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4408         send values read from stack directly to result and don't allocate
4409         temporary values,
4410         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4411         same registers,
4412         * (pic16_sameRegsOfs): NEW,
4413         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4414         free because they were not allocated from temporary pool,
4415         * pic16_popRegFromString): workaround to fix a problem with
4416         allocating variables twice or never,
4417         * (genGenPointerGet): using PRODL instead of FSR0H,
4418         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4419         instead of FSR0H,
4420         * (genAssign): take advantage of the _G.resDirect flag,
4421         * (genCast): around line 11844, use mov2f instead of directly
4422         MOVFF'ing between operands to account for literal values,
4423         * src/pic16/genutils.c: some new debug functions for gpsim have been
4424         added,
4425         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4426         float with integer part only,
4427         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4428         place variables in access bank
4429         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4430         updated sources to reflect recent changes in gen.c
4431
4432 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4433
4434         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4435         sources that searched for headers in installation path, now the
4436         device/include/pic16 is used,
4437         * src/pic16/glue.c (pic16glue),
4438         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4439         .line directives if not in debug mode, this suppresses assembler's
4440         warnings for ignored directives
4441
4442 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4443
4444         * src/port.h: made reset_regparms prototype void parameter explicit.
4445         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4446         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4447         * doc/sdccman.lyx: documented warning disabling and how to use
4448           printf_large to make it print floats.
4449         * device/include/stdbool.h: NEW
4450         * device/lib/_atof.c,
4451         * device/lib/_divuint.c,
4452         * device/lib/_divulong.c,
4453         * device/lib/expf.c,
4454         * device/lib/printf_large.c,
4455         * device/lib/sincosf.c,
4456         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4457         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4458           a completely reentrant lib.
4459
4460 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4461
4462         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4463         * device/include/pic16/stdio.h: fixed bug with colon
4464
4465 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4466
4467         * device/include/pic16/stdio.h,
4468         * device/include/pic16/stdlib.h,
4469         * device/include/pic16/math.h: NEW
4470         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4471         declared as _naked to reduce overhead
4472         * device/lib/Makefile.in (target port-specific-objects-pic16):
4473         changed * to *.* so to ignore the CVS directory,
4474         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4475         stacked variables back in stack,
4476         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4477         corruption
4478
4479 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4480
4481         * .version: bumped version number to 2.4.5
4482         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4483         * support/Util/SDCCerr.c (messages structure): added entry for
4484         W_POSSBUG2
4485
4486         Large cumulative patch for pic16 port and libraries.
4487         * device/include/pic16/sdcc-lib.h,
4488         * device/include/pic16/stdarg.h,
4489         * device/include/asm/pic16/features.h,
4490         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4491         * device/include/pic16/float.h: changes reentrant keyword with
4492         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4493         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4494         updated target build-libraries to include objects from gptr,
4495         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4496         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4497         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4498         all function headings,
4499         * src/SDCCmain.c: added global parameter userIncDirsSet,
4500         * (parseCmdLine): when option -I is encountered add directory to
4501         userIncDirsSet too,
4502         * src/version.awk: added space between control and long,
4503         * src/pic16/NOTES: added some notes for the port,
4504         * src/pic16/gen.c: added prototype for mov2fp function,
4505         * (fReturnpic16[]): properly named return value registers,
4506         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4507         * (aopForSym): added code to handle symbols with onStack flag set,
4508         symbols onStack are allocated PTRSIZE bytes,
4509         * (aopFreeAsmop): handles special case where asmops are stack objects,
4510         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4511         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4512         added argument lock to trace flaws in allocating temporary registers
4513         when developing port,
4514         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4515         * (pic16_popRegFromString): reenabled allocating a direct register
4516         from string,
4517         * (assignResultValue): various beautifications,
4518         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4519         referenced function argument,
4520         * (genIpush): reenabled to allow stacked arguments, handles only
4521         ic->parmPush iCodes,
4522         * (genCall, genPcall): major changes to allow for variable argument
4523         functions, fixed a bug with falsely restoring stack pointer after
4524         returning from call,
4525         * (genFunction): pending code for critical function,
4526         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4527         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4528         * (genNearPointerGet): fixed bug with indirect reading, was always
4529         reading from INDF0
4530         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4531         pointers,
4532         * (genAddrOf): rewrote code to take address of a stacked function parameter
4533         * (genCast): fixed casting to generic pointer type,
4534         * src/pic16/gen.h: added AOP_STA,
4535         * (struct asmop): added field stk,
4536         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
4537         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
4538         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
4539         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
4540         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
4541         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
4542         generic pointers,
4543         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
4544         and library paths,
4545         * (pic16_port structure): generic pointer size is set to 3,
4546         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
4547         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
4548         compiler warning,
4549         * src/pic16/ralloc.c (allocReg): prevent allocating register when
4550         operand is an iTemp,
4551
4552 2004-09-24 Martin Helmling <mh AT octo-soft.de>
4553
4554         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
4555         * debugger/mcs51/simi.c: addapt new syntax of s51
4556
4557 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
4558
4559         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
4560         * src/pic16/pcode.c: commented out some calls to free() in order to
4561         fix bug #989576,
4562
4563 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4564
4565         * src/SDCCicode.h,
4566         * src/SDCCicode.c (isiCodeInFunctionCall),
4567         * src/avr/ralloc.c (selectSpil),
4568         * src/pic/ralloc.c (selectSpil),
4569         * src/pic16/ralloc.c (selectSpil),
4570         * src/ds390/ralloc.c (selectSpil),
4571         * src/hc08/ralloc.c (selectSpil),
4572         * src/xa51/ralloc.c (selectSpil),
4573         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
4574         stack in the middle of a function call sequence (fixes bug #1020268)
4575         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
4576         costs associated with the minimum switch case.
4577
4578 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4579
4580         * src/SDCC.lex: fixed bug #1030549
4581
4582 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4583
4584         * src/SDCCcse.h (struct cseDef),
4585         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
4586         over a function call if the CSE is derived from a symbol whose
4587         address has been taken (fixes bug #1029883)
4588         * support/regression/tests/bug-1029883: a new regression test for
4589         this bug
4590
4591 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4592
4593         * src/hc08/gen.c (emitinline): fixed bug #1029778
4594         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
4595         to a cast object is no longer a syntax error ("fixes" bug #1030006,
4596         and starts toward RFE #905167)
4597
4598 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
4599
4600         * src/pic16/gen.c (mov2f): New function to move an operand to
4601         another without considering if it is a literal or a register,
4602         * (pic16_sameRegs): don't check if they are both AOP_REG,
4603         * (AccRsh): removed andmask=0 lines,
4604         * (genLeftShift): duplicated to be improved in future versions,
4605         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
4606         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
4607         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
4608         * (pic16initMnemonics): added initialization for POC_INFSNZW,
4609         * (insertBankSwitch): fixed inserting banksel directives algorithm
4610         for instructions that follow a skip instruction, this fixes a report
4611         for broken subtraction code generation,
4612         * src/pic16/ralloc.c (deassignLRs): do not free register if current
4613         iCode is a left op, just in case result and right share the same
4614         registers
4615
4616 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4617
4618         * src/hc08/main.c,
4619         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
4620         preservation of HX
4621         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
4622         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
4623         on 2004-09-12; it was buggy
4624
4625 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
4626
4627         * src/SDCCsymt.h: removed RESULT_CHECK
4628         * src/SDCCast.c,
4629         * src/SDCCglue.c,
4630         * src/SDCCval.c,
4631         * src/pic/glue.c,
4632         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
4633
4634 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
4635
4636         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
4637         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
4638         configuration values no more rejected by compiler, they are assigned
4639         to configuration registers with a warning message instead,
4640         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
4641         the for-loop so last conf register is emitted too,
4642         * (_pic16_initPaths): link library libsdcc.lib by default,
4643         * (_hasNativeMulFor): modified test for multiplication according to
4644         Raphael Neider's remarks. Integer multiplication is also done with
4645         support functions,
4646         * device/include/pic16/pic18fregs.h: corrected type error in while
4647         testing and including 18f6720 header file
4648
4649 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
4650
4651         * src/pic16/device.h (pic16_options): removed field use_crt,
4652         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
4653         until an optimization to handle single bits is added,
4654         * (pic16_loadFSR0): moved before genUnpackBits,
4655         * (genAnd): some white lines removed,
4656         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
4657         leave_reset flags in pic16_options when using crt modules,
4658
4659 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
4660
4661         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
4662           for bugs 898889 & 979599. Also used some safer print instructions.
4663
4664 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
4665
4666         * src/pic16/device.h (pic16_options_t): added field use_crt,
4667         crt_name, no_crt,
4668         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
4669         catch a probable future bug,
4670         * src/pic16/gen.c: aopIdx function commented out,
4671         * (genAssign): commented out old code which used aopIdx,
4672         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
4673         code, added if conditionals to take into account the --use-crt
4674         command line options,
4675         * src/pic16/main.c (pic16_optionsTable): added new command line
4676         options, --use-crt= and --no-crt,
4677         * (_pic16_linkEdit): now the proper crt object is added in the
4678         linker command line except than when --no-crt is specified,
4679         * src/pic16/pcode.c,
4680         * src/pic16/pcode.h: added some structures and functions for a new
4681         optimization scheme to compansate for instruction overhead between
4682         same iCodes, this scheme is currently under development and is not
4683         working in any way,
4684         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
4685         to && operator,
4686         * device/lib/pic16/startup/crt0i.c,
4687         * device/lib/pic16/startup/crt0iz.c: added global char variable
4688         __uflags to force the generation of an idata section
4689
4690 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
4691
4692         * doc/Makefile,
4693         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
4694         * doc/sdccman.lyx: updated sdcc version to 2.4.4
4695
4696 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4697
4698         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
4699         Frieder) and clarified the default code optimization mode
4700
4701 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4702
4703         * src/SDCC.lex (doPragma, process_pragma),
4704         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
4705         "opt_code_size", and "opt_code_balanced"
4706         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
4707         regrouped options by category, added support for category headers
4708         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
4709         and "--opt-code-size"
4710         * doc/sdccman.lyx: documented these new options and pragmas
4711         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
4712         preference into account
4713
4714 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
4715
4716         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
4717           geniCodePreDec): Fixed bug 904237 by generating a warning
4718         * src/SDCCerr.h,
4719         * src/SDCCerr.c: added warning W_SIZEOF_VOID
4720
4721 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
4722
4723         * src/pic/device.c : When no max ram set validate full memory range.
4724         * src/pic/pcode.c,
4725         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
4726
4727 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
4728
4729         * device/lib/_gptrget.c,
4730         * device/lib/_gptrput.c: updated comment
4731         * device/lib/calloc.c,
4732         * device/lib/free.c,
4733         * device/lib/malloc.c,
4734         * device/lib/realloc.c: added LGPL, made them reentrant-safe
4735         * src/SDCCcse.c (cseBBlock),
4736         * src/SDCCicode.c (printOperand, geniCodeArray),
4737         * src/SDCCicode.h (struct operand): fixed bug 868103
4738         * support/regression/tests/bug-868103.c: added
4739         * src/SDCCast.c (searchLitOp),
4740         * src/SDCCcse.h (struct cseDef),
4741         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
4742         * src/SDCCicode.h (struct operand),
4743         * src/SDCCsymt.h (struct sym_link),
4744         * src/avr/gen.c (hasInc),
4745         * src/ds390/gen.c (hasInc),
4746         * src/hc08/gen.c (genPlusIncr, hasInc),
4747         * src/mcs51/gen.c (hasInc),
4748         * src/pic16/glue.c (pic16_printIvalChar),
4749         * src/pic16/ralloc.c (regWithIdx),
4750         * src/xa51/gen.c (hasInc) : removed warnings
4751         * src/SDCCast.c (createBlock): added comment ???
4752         * src/hc08/ralloc.c: updated comments
4753
4754 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4755
4756         * doc/sdccman.lyx: updated section on switch statements, added
4757         section about semaphore locking
4758         * doc/Makefile: added option -info for latex2html
4759         * device/lib/_gptrget.c,
4760         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
4761
4762 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
4763
4764         * src/pic/device.h,
4765         * src/pic/device.c,
4766         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
4767          maxram is less than 0x100.
4768
4769 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
4770
4771         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
4772
4773 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4774
4775         * src/port.h,
4776         * src/mcs51/main.c,
4777         * src/ds390/main.c,
4778         * src/z80/main.c,
4779         * src/hc08/main.c,
4780         * src/pic/main.c,
4781         * src/pic16/main.c,
4782         * src/avr/main.c,
4783         * src/xa51/main.c
4784         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
4785         a jump table is the best form for a switch statement, including
4786         automatic insertion of missing cases to make the case range
4787         continuous. Developed in collaboration with Frieder Ferlemann.
4788
4789 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4790
4791         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
4792         accumulator result if it needs sign extension
4793
4794 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4795
4796         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
4797
4798 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4799
4800         * device/lib/gbz80/printf.c,
4801         * device/lib/z80/printf.c: removed define for NULL
4802
4803 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4804
4805         * as/xa51/xa_link.c,
4806         * device/examples/ds390/ow390/ad26.c,
4807         * device/examples/ds390/ow390/cnt1d.c,
4808         * device/examples/ds390/ow390/counter.c,
4809         * device/examples/ds390/ow390/ds2480.h,
4810         * device/examples/ds390/ow390/ds2480ut.c,
4811         * device/examples/ds390/ow390/findtype.c,
4812         * device/examples/ds390/ow390/gethumd.c,
4813         * device/examples/ds390/ow390/owllu.c,
4814         * device/examples/ds390/ow390/ownetu.c,
4815         * device/examples/ds390/ow390/swt12.c,
4816         * device/examples/ds390/ow390/swtloop.c,
4817         * device/examples/ds390/ow390/temp.c,
4818         * device/examples/ds390/ow390/temp10.c,
4819         * device/examples/ds390/ow390/thermo21.c,
4820         * device/examples/ds390/ow390/tinilnk.c,
4821         * device/examples/ds390/ow390/tstfind.c,
4822         * device/examples/serialcomm/windows/serial.cpp,
4823         * device/examples/serialcomm/windows/test_serialcomm.cpp,
4824         * device/include/reg51.h: fixed line endings for cvs
4825
4826 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4827
4828         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
4829         packRegsForAccUse, packRegisters): new accumulator register
4830         packing algorithm
4831         * support/regression/ports/hc08/support.c (_putchar): suppress
4832         warning of unused variable
4833         * src/SDCCicode.c: added SWAP entry to codeTable
4834
4835 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
4836
4837         * device/lib/sprintf.c: forgot to add this file before previous commit
4838
4839 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
4840
4841         * src/pic16/gen.c (genPackBits): added operand right in function
4842         parameters, load result directly if p_type is POINTER (that is
4843         called by genNearPointerSet)
4844         * (genUnPackBits): added operand left in function parameters,
4845         * (genNearPointerGet, genNearPointerSet): prevent the loading of
4846         FSR0 if accessing bitfields,
4847
4848 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
4849
4850         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
4851           _print_format; updated printf, sprintf, vsprintf
4852         * device/include/asm/default/features.h: corrected comment/define
4853         * device/lib/Makefile.in: added sprintf.c
4854         * device/lib/libsdcc.lib: added sprintf module
4855         * device/lib/printf_large.c,
4856         * device/lib/vprintf.c,
4857         * device/lib/sprintf.c: totally refactored printf_large and vprintf
4858           into these 3 files
4859         * support/regression/Makefile: changed ALL_PORTS into a usefull default
4860         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
4861         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
4862           hc08 test
4863         * support/regression/tests/zeropad.c: define idata as data for hc08
4864
4865 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4866
4867         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
4868         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
4869         labels are referenced at least once (even if a reference is not found)
4870         * src/hc08/gen.c (emitcode): set isComment flag for comments
4871         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
4872         loads), rules 6a..6b (optimize jumps to return)
4873
4874 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4875
4876         * device/lib/acosf.c (acosf),
4877         * device/lib/asinf.c (asinf),
4878         * device/lib/atanf.c (atanf),
4879         * device/lib/ceilf.c (ceilf),
4880         * device/lib/cosf.c (cosf),
4881         * device/lib/coshf.c (coshf),
4882         * device/lib/cotf.c (cotf),
4883         * device/lib/fabsf.c (fabsf),
4884         * device/lib/floorf.c (floorf),
4885         * device/lib/log10f.c (log10f),
4886         * device/lib/logf.c (logf),
4887         * device/lib/sinf.c (sinf),
4888         * device/lib/sinhf.c (sinhf),
4889         * device/lib/sqrtf.c (sqrtf),
4890         * device/lib/tanf.c (tanf),
4891         * device/lib/tanhf.c (tanhf),
4892         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
4893         replaced all instances of "reentrant" in the library functions
4894         defined in math.h with this macro.
4895         * support/regression/tests/float_trans.c: reenabled test for hc08
4896
4897 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
4898
4899         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
4900         erroneously deleted
4901
4902 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4903
4904         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
4905         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
4906         multi-byte volatile operands are used
4907         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
4908         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
4909         initialization to area GSINIT0 so that it would always precede
4910         any static initializers in GSINIT
4911         * support/regression/tests/zeropad.c: fixed idata define for hc08
4912         * support/regression/tests/bug-927659.c,
4913         * support/regression/tests/float_trans.c: disabled tests for hc08
4914         pending missing library routines
4915         * .version: increased version number to 2.4.4 - hc08 port now passes
4916         regression tests
4917
4918
4919 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
4920
4921         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
4922         * Makefile.common.in,
4923         * as/Makefile,
4924         * as/hc08/Makefile.in,
4925         * as/mcs51/Makefile.in,
4926         * as/z80/Makefile.in,
4927         * debugger/mcs51/Makefile.in,
4928         * device/include/Makefile.in,
4929         * device/lib/Makefile.in,
4930         * doc/Makefile,
4931         * link/Makefile,
4932         * link/z80/Makefile.in,
4933         * packihx/Makefile.in,
4934         * sim/ucsim/main_in.mk,
4935         * sim/ucsim/avr.src/Makefile.in,
4936         * sim/ucsim/doc/Makefile.in,
4937         * sim/ucsim/gui.src/serio.src/Makefile.in,
4938         * sim/ucsim/hc08.src/Makefile.in,
4939         * sim/ucsim/s51.src/Makefile.in,
4940         * sim/ucsim/xa.src/Makefile.in,
4941         * sim/ucsim/z80.src/Makefile.in,
4942         * src/Makefile.in,
4943         * support/cpp2/Makefile.in,
4944         * support/librarian/Makefile,
4945         * support/makebin/Makefile: added DESTDIR to the install path proposed
4946         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
4947         * doc/sdccman.lyx: added DESTDIR documentation
4948
4949 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
4950
4951         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
4952         instruction for interrupt handlers, use fast returns when returning
4953         from high priority interrupts
4954
4955 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4956
4957         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
4958         code generation
4959         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
4960         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
4961         bugs, ported much of Bernhard's code from mcs51
4962         * src/mcs51/gen.c (genSend),
4963         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
4964         than one when calling a reentrant function
4965         * device/lib/_mullong.c: defined an alternate struct layout for big
4966         endian ports (hc08)
4967
4968 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4969
4970         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
4971         test
4972
4973 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4974
4975         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
4976         are sane and complete before asking the port its prefered parameter
4977         passing method (fixes bug #1017633)
4978         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
4979         and _ret3
4980
4981 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4982
4983         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
4984         problem in bitfields >= 8 bits.
4985
4986 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
4987
4988         * src/SDCCsymt.c: undid changes that were not meant to be committed
4989
4990 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
4991
4992         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
4993
4994 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
4995
4996         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
4997           copied and wrong bit got inverted
4998
4999 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5000
5001         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5002         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5003         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5004         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5005         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5006         assignments to bitfields at known addresses
5007         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5008         reads from bitfields at known addresses
5009         * src/hc08/ralloc.c (packRegisters),
5010         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5011         genhc08Code): optimize pointer get values used as conditionals
5012         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5013         and branch
5014
5015 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5016
5017         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5018         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5019         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5020         as conditionals
5021
5022 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5023
5024         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5025
5026 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5027
5028         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5029         related problems
5030
5031 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5032
5033         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5034
5035 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5036
5037         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5038         mcs51 port
5039
5040 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5041
5042         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5043
5044 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5045
5046         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5047         cases use more compact code.
5048
5049 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5050
5051         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5052
5053 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5054
5055         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5056
5057 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5058
5059         * src/SDCCsymt.h,
5060         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5061         parameter of changePointer() from symbol* to sym_link*
5062         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5063         * src/SDCCsymt.c (compareType): void* type is castable to other
5064         pointers, but not necesarily an exact match.
5065         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5066         is no longer blindly treated as an exact match.
5067         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5068
5069 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5070
5071         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5072
5073 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5074
5075         * src/pic/gen.c,
5076         * src/pic/pcode.c,
5077         * src/pic/ralloc.h,
5078         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5079
5080 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5081
5082         * src/pic/device.c,
5083         * src/pic/device.h,
5084         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5085
5086 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5087
5088         * src/mcs51/gen.c (emitcode): fixed bug #992819
5089
5090 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5091
5092         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5093           there's no need to make it worse
5094
5095 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5096
5097         * src/mcs51/ralloc.c (deassignLR),
5098         * src/ds390/ralloc.c (deassignLR),
5099         * src/hc08/ralloc.c (deassignLR),
5100         * src/z80/ralloc.c (deassignLR),
5101         * src/pic/ralloc.c (deassignLR),
5102         * src/pic16/ralloc.c (deassignLR),
5103         * src/avr/ralloc.c (deassignLR),
5104         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5105         rlivePoint): fixed another part of bug #971834
5106
5107 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5108
5109         * src/z80/main.c: enabled "critical" keyword
5110         * src/z80/mappings.i,
5111         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5112         functions (fixes bug #979646)
5113         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5114
5115 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5116
5117         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5118           such as c:\mydir.
5119
5120 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5121
5122         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5123           doesn't disable too much optimizations
5124
5125 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5126
5127         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5128
5129 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5130
5131         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5132
5133 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5134
5135         * src/pic/gen.c tidied up tabs
5136         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5137         * src/pic/main.c tidied up tabs
5138         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5139         * src/pic/pcoderegs.c tidied up tabs
5140         * src/pic/ralloc.c tidied up tabs
5141
5142 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5143
5144         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5145         to S_FIXED for pic16 port and when symbol is not in level 0,
5146         allocate for S_REGISTER storage class and pic16 port, too,
5147         * src/pic16/device.h: prototype for checkSym,
5148         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5149         * (pic16_assignConfigWordValue): test the value and the mask to
5150         validate that the value is suitable for the configuration word,
5151         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5152         collect extern declared symbols, don't emit symbol twice, check
5153         first if symbol is in publics set first,
5154         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5155         * added command line '--fstack' which enables an experimental
5156         feature for stack access, too buggy to be used yet...
5157         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5158         * (pic16_allocDirReg): when register has storage class S_REGISTER
5159         allocate in pic16_dynAccessRegs,
5160         * device/include/pic16/pic18f????.h: modified configuration word
5161         naming convention, words started as CONFIG0H but should be CONFIG1H
5162
5163 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5164
5165         * device/include/mcs51reg.h: fixed bug 970993
5166
5167 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5168
5169         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5170         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5171         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5172         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5173         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5174         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5175           error/warning numbers,
5176           added function setWarningDisabled()
5177         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5178         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5179           _memcmp.c _memmove.c calloc.c realloc.c free.c
5180         * support/regression/tests/malloc.c: added tests for new functionality
5181         * support/regression/tests/zeropad.c: added tests for truncated initializers
5182           and initialized char arrays starting with '\x0'
5183         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5184
5185 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5186
5187         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5188
5189 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5190
5191         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5192         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5193         peephole 177.e. Thanks to anonymous
5194
5195 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5196
5197         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5198         function isn't used in the source but referenced as a
5199         variable initializer then declare it as extern in .asm file
5200
5201 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5202
5203         * .version: increased version number to 2.4.3
5204
5205         Adding version extension according to ChangeLog CVS revision
5206         * src/Makefile.in (target all): added dependency 'version.h'
5207         * (rule version.h): added rule to create version.h from ChangeLog,
5208         * (rule dep): added dependency version.h,
5209         * src/version.awk: AWK script to create version.h
5210         * src/SDCCdwarf2.c (dwWriteModule),
5211         * src/SDCCglue.c (initialComments),
5212         * src/SDCCmain.c (printVersionInfo): modified to write after
5213         version string the version extension number,
5214         * src/SDCCutil.c: included "version.h"
5215         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5216         number,
5217         * src/SDCCutil.h: added prototype for getBuildNumber
5218
5219         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5220         includeDirsSet, too,
5221         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5222         const char [] is found in function prototype...
5223
5224         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5225         moving to WREG with source is already in WREG,
5226         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5227         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5228         * (aopForSym): stack'ed symbols are partially supported, added
5229         if-clause to support symbols in FARSPACE,
5230         * (sameRegs): added test for AOP_ACC to see if registers are same,
5231         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5232         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5233         * (pic16_popRegFromString): will not allocate a new register if it
5234         doesn't find one by name, bug may have introduced...
5235         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5236         * (genIpush): revived to use pic16 port's stack,
5237         * (genAddrOf): added incomplete case for stack'ed operand,
5238         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5239         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5240         can handle multibyte operands,
5241         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5242         * (pic16initialComments): added message for MPLAB compatibility
5243         mode enabled,
5244         * src/pic16/main.h: prototype for pic16_mplab_comp,
5245         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5246         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5247         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5248         because of increased complexity of procedure,
5249         * (_process_pragma): stack pragma changed to format 'stack pos len',
5250         emit symbol '_stack_end' to conform with gplink,
5251         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5252         to search for register,
5253         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5254         PO_GPR_REGISTER,
5255         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5256         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5257         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5258         case for PO_GPR_REGISTER,
5259         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5260         dies, the new era is ahead !...
5261         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5262         pic16_dynInternalRegs,
5263         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5264         * (pic16_allocDirReg): minor optimizations and bug fixes,
5265         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5266
5267         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5268         load stack and frame pointer with address of 'stack_end' symbol
5269
5270 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5271
5272         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5273         without source code but only variable initializers
5274
5275 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5276
5277         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5278         external are not declared as extern to reduce overhead while linking
5279
5280 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5281
5282         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5283
5284 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5285
5286         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5287           Yee Keat for the patch
5288         * src/SDCCast.c (decorateType): fixed bug #979599
5289         * src/ds390/gen.h: removed local fReturnSizeDS390
5290         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5291         * src/ds390/gen.c (genAnd, genOr, genXor),
5292         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5293
5294 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5295
5296         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5297         add relFilesSet to $3, manipulate $2 to handle linking of object
5298         files without source files in command line,
5299         * device/include/pic16 (all headers): added ID location macros,
5300         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5301         entries for ID location bytes,
5302         * (pic16_assignIdByteValue): NEW,
5303         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5304         added field dumpcalltree to pic16_options_t,
5305         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5306         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5307         emitting rFalseIfx label after check_carry label,
5308         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5309         pic16_emitDIRegs), NEW
5310         * (pic16glue): dump .calltree file when option --calltree found,
5311         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5312         * (_pic16_genAssemblerPreamble): emit ID locations after
5313         configuration registers,
5314         * (pic16_linkCmd): modifications of the link command,
5315         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5316         * (pic16_pCodeInitRegisters): don't init stack registers,
5317         * (pic16_findPrevInstruction): fixed bug,
5318         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5319         bug with immediate registers,
5320         * (buildCallTree): traces stack push and pop,
5321         * (pct2): dump also stack usage for each function,
5322         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5323         * (pic16_allocDirReg): various modifications,
5324         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5325         fixed to 1,
5326
5327 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5328
5329         * src/pic16/pcode.c: removed buggy double colon
5330
5331 2004-07-01 Borut Razem <borut.razem AT siol.net>
5332
5333         * support/scripts/sdcc.nsi: added include/pic16 to setup
5334
5335 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5336
5337         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5338         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5339         target 'clean',
5340         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5341         specific command line arguments. Also added sample lkr script
5342         for placing a variable at a specific memory bank.
5343         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5344         at a specific memory bank,
5345         * (pic16_dump_isection): fixed bug which caused string literals to
5346         be omitted when dumping idata section,
5347         * (pic16_groupRegistersInSection): added code to handle registers
5348         in specific memory banks,
5349         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5350         public, all references are renamed too,
5351         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5352         AOP_DPTR2,
5353         * (pic16_storeForReturn): added case to handle when dest is WREG,
5354         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5355         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5356         pic16_rel_udata, check to see if that register is marked as being
5357         a member of a specific memory bank,
5358         * (pic16_printIvalCharPtr): added code to add string literals either
5359         to code or the idata sections,
5360         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5361         also accept the 'udata' pragma,
5362         * src/pic16/main.h: new structure types sectName and sectSym
5363         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5364         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5365         * (pic16_findPrevInstruction): fixed, it returned nothing,
5366         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5367         instruction combinations,
5368         * (pic16_FixRegisterBanking): heavily reorganised,
5369         * (pic16_AnalyzeBanking): if generating banksel directives is
5370         disabled, then don't call FixRegisterBanking at all,
5371         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5372         completely removed,
5373         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5374
5375 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5376
5377         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5378         Phuah Yee Keat <yk.phuah AT nestac.com>
5379
5380 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5381
5382         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5383         correctly the IVT even if it is relocated to some other location
5384
5385 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5386
5387         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5388         * device/include/pic16/pic18f2220.h: NEW,
5389         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5390         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5391         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5392         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5393         nodefaultlibs, ivt_loc is the location of the interrupt vector
5394         table, and nodefaultlibs signs that default libraries should not be
5395         linked in link stage,
5396         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5397         according to --ivt-loc argument,
5398         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5399         when pragma stack is found,
5400
5401 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5402
5403         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5404         256 (range check), 257 (do while), 258.a-f (bit banging
5405         f.e. on 3-wire SPI bus)
5406
5407 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5408
5409         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5410         variables used exclusively within a loop
5411
5412 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5413
5414         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5415
5416 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5417
5418         * src/SDCClrange.c (computeClash): fixed bug #971834
5419
5420 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5421
5422         * src/mcs51/gen.c (genCmp): fixed bug #975903
5423         * src/hc08/gen.c (operandsEqu),
5424         * src/ds390/gen.c (operandsEqu),
5425         * src/z80/gen.c (operandsEqu),
5426         * src/pic/gen.c (operandsEqu),
5427         * src/pic16/gen.c (operandsEqu),
5428         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5429         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5430
5431 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5432
5433         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5434
5435 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5436
5437         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5438         default case in switch statement,
5439         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5440         to eliminate problem with initialisation of pointers, but problem
5441         still exists,
5442         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5443         * (emitStaticSegment): removed various lines emitting debug info,
5444         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5445         added processor registers for utilizing EEPROM,
5446         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5447         configurable and set 8
5448
5449 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5450
5451         * .version: increased version number to 2.4.2,
5452
5453         Cumulative patch for pic16 port
5454         * src/pic16/device.c: changed scheme to dump initial values for
5455         variables in idata segment, all print_idata* functions were removed,
5456         now the pic16_printIval* will be called,
5457         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5458         * _pic16_printPointerType, pic16_printPointerType,
5459         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5460         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5461         NEW, similar to the respective functions in SDCCglue.c,
5462         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5463         way, emitting hex bytes,
5464         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5465
5466 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5467
5468         * src/avr/ralloc.c (serialRegAssign),
5469         * src/xa51/ralloc.c (serialRegAssign),
5470         * src/pic/ralloc.c (serialRegAssign),
5471         * src/pic16/ralloc.c (serialRegAssign),
5472         * src/hc08/ralloc.c (serialRegAssign),
5473         * src/z80/ralloc.c (serialRegAssign),
5474         * src/ds390/ralloc.c (serialRegAssign),
5475         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5476
5477 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5478
5479         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5480         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5481
5482 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5483
5484         Cumulative patch for pic16 port:
5485         * src/pic16/device.h (typedef PIC16_device) modified fields for
5486         defining microcontrollers,
5487         * src/pic16/device.c: added new info for all devices in Pics16 array,
5488         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5489         to be optimised out by the pCode optimiser,
5490         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5491         specially, bug reported by G.M. Gallant,
5492         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5493         as force'd so that cannot be optimised out by pCode optimiser,
5494         * src/pic16/pcode.c,
5495         * src/pic16/pcodepeeph.c,
5496         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5497         they are disabled by default, but can be enabled explicit with
5498         command argument --denable-peeps, for testing,
5499         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5500         --pomit-ivt in COMPILE_FLAGS
5501
5502 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5503
5504         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5505           compilation on MSVC
5506
5507 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5508
5509         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5510
5511 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5512
5513         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5514         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5515
5516 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5517
5518         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5519         would only assign 0x300001 register.
5520
5521 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5522
5523         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5524         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5525
5526 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5527
5528         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5529         for ds80c400
5530         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5531         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5532         added peephole 254 (left shift), 255 (jump table)
5533
5534 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
5535
5536         * device/lib/Makefile.in: removed comment line with model-pic16,
5537         * (target port-specific-objects-pic16): the libraries and objects
5538         are copied to the build directory form the device/lib/pic16/bin
5539         directory
5540
5541         Cumulative patch concerning pic16 port:
5542         * library directory has been re-organized,
5543         * added support for PIC18F1220,
5544         * added headers and library sources for chips 18f1220,18f6520,
5545         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
5546
5547         * configuration registers setting has changed, now each supported
5548         device has a complete description of the registers it uses,
5549         * all initialisations are moved to idata sections, these section
5550         can be absolute or relocatable,
5551         * fixed initialisation of codespace variables,
5552         * fixed warning about PCLATU and gpsim,
5553         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
5554         * (genAssign): use table reads when assigning from variables in codespace,
5555         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
5556         char/int variables placed in codespace,
5557         * (pic16_emitConfigRegs): NEW, emits a list with configuration
5558         registers set in .asm file, no need for --pomit-config-words anymore,
5559         * (pic16glue): some 8051 legacy segments are commented out
5560         (to be removed completely),
5561         * added support for alternative assembler and linker with --asm=
5562         and --link= command line arguments,
5563         * peepholes are disabled automatically in the port, no need to
5564         specify on command line,
5565         * port supports natively char/int/long multiplication, but converts
5566         all divisions to support functions,
5567         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
5568         to the file set in variable $2,
5569         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
5570         strings in ASCII format and not in hex,
5571         * ralloc.c (serialRegAssign): added a triplet of conditional calls
5572         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
5573         allocate proper register if iCodes aren't temporary,
5574
5575 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
5576
5577         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
5578
5579 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
5580
5581         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
5582         is commented out
5583
5584 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5585
5586         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
5587         computed address is reused
5588         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
5589         multi-byte bitfields
5590
5591 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5592
5593         * src/z80/gen.c: (genArrayInit): must check for pointers too
5594
5595 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5596
5597         * support/regression/tests/zeropad.c: never meant to commit the
5598           nestedstruct test: removed, added check for GCC version
5599
5600 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
5601
5602         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
5603         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
5604         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
5605           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
5606           bugs 928906 and 954082 half-empty initializers
5607         * src/SDCCsymt.h,
5608         * src/SDCCsymt.c (getAllocSize): added for above fix
5609         * src/z80/gen.c (genArrayInit): fixed bug 741044
5610         * support/regression/tests/zeropad.c: added tests
5611
5612 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
5613
5614         * src/pic16/device.c (pic16_dump_section): corrected bug which
5615         caused some symbols of the libraries to be misplaced
5616
5617 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5618
5619         * src/pic16/glue.c,
5620         * src/pic16/ralloc.h,
5621         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
5622         to fix conflict with pic port
5623
5624 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5625
5626         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
5627         externs configuration variables,
5628         * src/pic16/ralloc.h,
5629         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
5630         prototype in header, commented out some debug messages
5631
5632 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
5633
5634         * src/pic16/glue.c,
5635         * src/pic16/main.c,
5636         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
5637         for gpasm COFF object generation. Thanks to D. Hawkins for
5638         his patch info
5639
5640 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5641
5642         * src/ds390/main.c,
5643         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
5644         Brock for spotting this)
5645         * src/ds390/gen.c (genEndFunction),
5646         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
5647         interrupt handler and critical. Disable push/pop optimizations when
5648         peephole optimizations disabled.
5649
5650 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5651
5652         Updated pic16 library sources and headers.
5653         * device/lib/pic16/pic18f*/ ,
5654         * device/include/pic16/*.h: modified to handle structured SFR
5655         definitions
5656
5657 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5658
5659         * src/port.h (PORT structure): added hook initPaths, now each
5660         port can declare its own default search paths,
5661         which can been seen with the --print-search-dirs option,
5662         see pic16 port for example,
5663         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
5664         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
5665         * (doPrintSearchDirs): NEW, replaces in a central manner the
5666         printing of search dirs which was split in set*Paths functions,
5667         * (main): added call to port->initPaths and doPrintSearchDirs,
5668         * src/avr/main.c,
5669         * src/ds390/main.c,
5670         * src/hc08/main.c,
5671         * src/izt/i186.c,
5672         * src/izt/tlcs900h.c,
5673         * src/mcs51/main.c,
5674         * src/pic/main.c,
5675         * src/pic16/main.c: modified port structures to reflect addition of
5676         initPaths hook,
5677
5678         * src/pic16/device.c (regCompare): registers are finally sorted by name,
5679         * (pic16_dump_section): for registers in same address reserve memory once,
5680         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
5681         to no_banksel,
5682         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
5683         result is greater in size than right or left,
5684         * (pic16_genUMult8X8_8): there are some cases where the result can
5685         be 16 bits size, so handle these,
5686         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
5687         * (pic16_outBitC): modified to emit pcodes,
5688         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
5689         or not,
5690         * (genDivOneByte): implemented algorithm to divide 8-bits,
5691         * (genCmp): uncommented goto, but issues still exist,
5692         * (genAnd): fixed a bug with variables >8bits,
5693         * (genPackBits): optimization added that uses BCF/BSF to change a
5694         single bit,
5695         * (genAssign): fixed bug when assigning floating point literals,
5696         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
5697         __sdcc_gsinit_startup label,
5698         * src/pic16/main.c (_pic16_init): removed search directory
5699         initialisations,
5700         * (_pic16_initPaths): NEW, used to initialise search directories,
5701         * (_hasNativeMulFor): support functions for all except char/int
5702         multiplication, and char division,
5703         * (PIC16_port struct): modified entry for native mul support,
5704         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
5705         no_banksel option,
5706         * (buildCallTree): call to register_usage is ifdef'ed out,
5707
5708 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5709
5710         * device/include/string.h: applied Stas Sergeev's patch to make this
5711         header file compatible with the preprocessor -Wundef option
5712         * src/SDCCmain.c (main): abort compilation if preprocessor reports
5713         failure (fixes bug #941458)
5714
5715 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5716
5717         * src/SDCCopt.c (killDeadCode): fixed bug #907733
5718         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
5719         that the variable, not the function, should be static
5720         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
5721         to be consistent with non-literal case
5722
5723 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5724
5725         * src/SDCCast.c (isConformingBody): fixed bug #949967
5726         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
5727         convilong): fixed bug #952086
5728
5729 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5730
5731         * src/SDCCmem.c (allocVariables): fixed bug #955321
5732
5733 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5734
5735         * src/hc08/main.c (_hc08_genAssemblerEnd),
5736         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
5737         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
5738         completely eliminated the use of a temporary file
5739         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
5740         when more than one file linked
5741         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
5742
5743 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5744
5745         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
5746         which fixes bug #543481
5747         * support/regression/tests/bug-751703.c: fixed comments left from a
5748         cut and paste error
5749         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
5750         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
5751         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
5752         scopes
5753         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
5754         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
5755         are now changed to underscores in moduleName
5756
5757 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5758
5759         * as/mcs51/lkmem.c: better fix for bug #954173
5760
5761 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
5762         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5763
5764         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
5765         * device/include/c8051f000.h,
5766         * device/include/c8051f120.h,
5767         * device/include/c8051f300.h,
5768         * device/include/c8051f310.h,
5769         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
5770         PWM16) and detab'ed
5771
5772 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5773
5774         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
5775         and mailing lists, doc'ed --no-peep-comments, removed reference
5776         to knoppix (newest version has no LyX/LaTeX), other minor changes
5777         * src/SDCCglue.c (glue): save 2 bytes stack space with
5778         option --main-return. The ljmp could probably be avoided too
5779
5780 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5781
5782         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
5783
5784 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5785
5786         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
5787         * src/SDCCopt.c (isLocalWithoutDef),
5788         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
5789         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
5790         (credit to Maarten Brock for patch #949363, on which this is based)
5791         * support/regression/tests/bug-751703.c: some test cases of extern used
5792         within inner scopes.
5793
5794 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5795
5796         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
5797         SPEC_STRUCT
5798         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
5799         struct definitions
5800         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
5801         dwWriteLabel): fix to create valid debugger symbols even when
5802         the module name has non-alphanumeric symbols in it
5803         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
5804         when a variable's allocation has been optimized away
5805
5806
5807 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5808
5809         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
5810         * src/hc08/main.c,
5811         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
5812         * src/mcs51/main.c,
5813         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
5814         * src/ds390/main.c,
5815         * src/z80/gen.c (z80_emitDebuggerSymbol),
5816         * src/z80/main.c,
5817         * src/pic/gen.c (pic14_emitDebuggerSymbol),
5818         * src/pic/main.c,
5819         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
5820         * src/pic16/main.c,
5821         * src/avr/gen.c (avr_emitDebuggerSymbol),
5822         * src/avr/main.c,
5823         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
5824         * src/xa51/main.c,
5825         * src/SDCCdebug.c (emitDebuggerSymbol),
5826         * src/SDCCdebug.h,
5827         * src/port.h: added a debugger struct to the port struct. Added a
5828         callback for defining debugger symbols
5829
5830         * src/SDCCast.c (createLabel),
5831         * src/SDCC.y (labeled_statement): mark all compiler generated labels
5832         with isitmp = 1
5833         * src/SDCCicode.h,
5834         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
5835         iCode back to the ast for the function
5836
5837         * src/hc08/ralloc.c (hc08_assignRegisters),
5838         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
5839         unneeded fields from the regs struct.
5840         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
5841         pushReg() & pullReg() functions instead of emitcode()
5842
5843         * src/hc08/gen.c (genLabel, genhc08Code),
5844         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
5845
5846         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
5847         debugger hooks
5848
5849         * src/hc08/gen.c (genEndFunction, genhc08Code),
5850         * src/hc08/gen.h,
5851         * src/mcs51/gen.c (genEndFunction, gen51Code),
5852         * src/mcs51/gen.h,
5853         * src/ds390/gen.c (genEndFunction, gen390Code),
5854         * src/ds390/gen.h,
5855         * src/z80/gen.c (genEndFunction, genZ80Code),
5856         * src/z80/gen.h,
5857         * src/z80/z80.h,
5858         * src/pic/gen.c (genEndFunction, genpic14Code),
5859         * src/pic/gen.h,
5860         * src/pic16/gen.c (genEndFunction, genpic16Code),
5861         * src/pic16/gen.h,
5862         * src/avr/gen.c (genEndFunction, genAVRCode),
5863         * src/avr/gen.h,
5864         * src/xa51/gen.c (genEndFunction, genXA51Code),
5865         * src/xa51/gen.h,
5866         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
5867         specific code to cdbFile.c and out of the backend code generators
5868
5869         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
5870         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
5871         starting address is now 0
5872
5873         * as/hc08/asm.h,
5874         * as/hc08/m08pst.c,
5875         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
5876         assembler directive for DWARF support
5877         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
5878
5879         * src/src.dsp,
5880         * src/Makefile.in,
5881         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
5882
5883 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5884
5885         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
5886         and inappropriate peephole optimization in jump tables
5887
5888 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5889
5890         * as/hc08/m08pst.c,
5891         * src/SDCCglue.c: sdccopt works for the hc08 port now
5892
5893 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
5894
5895         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
5896
5897 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5898
5899         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
5900
5901 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5902
5903         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
5904         rules
5905         * src/SDCCmain.c,
5906         * src/SDCCglobl.h,
5907         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
5908         comments from the peephole optimizer replacement rules
5909         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
5910         symbols
5911         * src/SDCCcse.c (updateSpillLocation),
5912         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
5913         equivalents
5914         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
5915         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
5916         objects far pointers
5917
5918 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5919
5920         * src/SDCCsymt.h: a missing part of my last change
5921         * src/pic/ralloc.c (regTypeNum),
5922         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
5923
5924 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5925
5926         * src/SDCCicode.h,
5927         * src/SDCCicode.c (aggrToPtrDclType),
5928         * src/SDCCptropt.h,
5929         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
5930         ptrPseudoSymConvert),
5931         * src/pic/ralloc.c (regTypeNum),
5932         * src/pic16/ralloc.c (regTypeNum),
5933         * src/hc08/ralloc.c (regTypeNum),
5934         * src/ds390/ralloc.c (regTypeNum),
5935         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
5936         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
5937
5938 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5939
5940         * link/z80/lkmain.c (afile),
5941         * as/hc08/lkmain.c (afile),
5942         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
5943         prevent a pointer problem when a filename has no directory and
5944         no extension specified.
5945
5946 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5947
5948         * link/z80/lkmain.c (afile): allow periods in directory names
5949         * link/z80/lkmain.c (afile),
5950         * as/mcs51/lkmain.c (afile),
5951         * as/hc08/lkmain.c (afile): allow linker script file to have an
5952         extension other than ".lnk"
5953         * link/z80/lklex.c (getfid),
5954         * link/z80/lkmain.c (parse),
5955         * as/mcs51/lklex.c (getfid),
5956         * as/mcs51/lkmain.c (parse),
5957         * as/hc08/lklex.c (getfid),
5958         * as/hc08/lkmain.c (parse): Support comments in the linker script
5959         file on lines by themselves and after filenames
5960
5961 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5962
5963         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
5964
5965 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5966
5967         * src/z80/peeph-z80.def: removed some peephole rules that don't
5968         work with multibyte arithmetic (fixed bug #937126)
5969         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
5970         to registers and not global variables
5971         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
5972         geniCodePreInc, geniCodePostDec, geniCodePreDec,
5973         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
5974         checking for assignments not internally generated (fixed bug #931895)
5975         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
5976         structure member (fixed bug #930072)
5977
5978 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5979
5980         * src/SDCCmain.c (linkEdit),
5981         * src/hc08/main.c (_hc08_parseOptions),
5982         * as/hc08/Makefile.in,
5983         * as/hc08/aslink.h,
5984         * as/hc08/asm.h,
5985         * as/hc08/m08pst.c,
5986         * as/hc08/lkrloc.c (relr, rele),
5987         * as/hc08/lkarea.c (lnkarea)
5988         * as/hc08/lkmain.c (afile, parse),
5989         * as/hc08/lkelf.c: support for ELF output
5990         * as/hc08/lks19.c (s19),
5991         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
5992
5993 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5994
5995         * as/mcs51/lkihx.c: Fixed bug #899105.
5996
5997 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5998
5999         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6000         .dsp files from Unix to DOS.
6001
6002 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6003
6004         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6005         function pointers; we have been compliant for several months now.
6006         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6007         change that was accidently commented out
6008         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6009         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6010         bug #922319
6011
6012 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6013
6014         * src/hc08/gen.c: output of all of the internal debugging information
6015         is now controlled by the D() macro; it is disabled by default
6016
6017 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6018
6019         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6020         harder to keep the same registers during a CAST iCode
6021         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6022         long via int can be done in a single cast, if the signedness is
6023         correct.
6024         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6025         putchar() in tinibios.c in ds390's library
6026
6027 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6028
6029         * src/SDCCast.c (decorateType): fixed bug #898889,
6030         cast result of a literal complement too
6031         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6032         fixed check for bitfields
6033
6034 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6035
6036         * src/SDCCicode.c (geniCodeLogic): made it static,
6037         (geniCodeLogicAndOr): added in order to fix bug #905492,
6038         (ast2iCode): fixed bug #905492
6039         * support/regression/tests/bug-905492.c: added
6040         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6041         (processParms): fixed bug #927659: don't copy parms, this will clear
6042         decorated flag
6043         * support/regression/tests/bug-927659.c: added
6044
6045 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6046
6047         * src/SDCCast.c (addCast): don't cast float to char
6048         * device/lib/libsdcc.lib: added _memmove
6049
6050 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6051
6052         * device/lib/large/Makefile: fixed parallel execution by
6053         replacing `make` by `$(MAKE)`
6054
6055 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6056
6057         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6058         offsets (fixes bug #923936)
6059
6060 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6061
6062         * device/lib/small/Makefile: fixed parallel execution by
6063         replacing `make` by `$(MAKE)`
6064
6065 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6066
6067         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6068
6069 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6070
6071         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6072         * src/regression/Makefile: Regression test was not running.
6073
6074 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6075
6076         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6077         complement if possible
6078         * src/SDCCval.c (valComplement),
6079         * src/SDCCicode.c (operandOperation): fixed complement of literal
6080         * support/regression/tests/onebyte.c (testComplement): added
6081
6082 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6083
6084         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6085         return an optimized tree; actually replace actParm with the new tree
6086         * src/SDCCast.h: added some parantheses to remove side effects
6087         * support/regression/tests/bug-920866.c
6088
6089 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6090         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6091         Bit operands were not being handled properly in the pic14 port.
6092         (now src/regression/add.c passes again).
6093
6094 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6095
6096         * src/SDCC.y (labeled_statement): case and default no longer require
6097         a following statement (RFE #893037)
6098
6099 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6100
6101         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6102         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6103         disabled (fixes bug #916294)
6104         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6105         "mov a,acc"; patch provided by Lenny Story
6106         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6107
6108 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6109
6110         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6111         functions
6112         * src/ds390/gen.c (genFunction, genEndFunction),
6113         * src/ds390/ralloc.c (ds390_assignRegisters),
6114         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6115         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6116         pushed if there are parameters passed on the stack. Also, a cleaner
6117         way to decide if r0/r1 should be pushed/popped. (Together they fix
6118         bug #918693)
6119
6120 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6121
6122         * doc/sdccman.lyx,
6123         * device/lib/mcs51/crtpagesfr.asm,
6124         * device/lib/mcs51/crtxinit.asm,
6125         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6126         to avoid confusion with Si Lab's SFRPAGE register.
6127
6128 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6129
6130         * src/SDCCglue.c (emitMaps): allow public sfr variables
6131         * src/SDCCglue.c (initialComments): include compiler build date
6132         with compiler version and put the timestamp of the generated
6133         assembly file on a serperate line to be less confusing.
6134         * src/port.h: added genInitStartup hook
6135         * src/avr/main.c,
6136         * src/ds390/main.c,
6137         * src/hc08/main.c,
6138         * src/pic/main.c,
6139         * src/pic16/main.c,
6140         * src/xa51/main.c,
6141         * src/z80/main.c: genInitStartup initialize as NULL (default to
6142         historical behaviour)
6143         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6144         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6145         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6146         library instead of hard coding it into the compiler.
6147         * support/regression/ports/mcs51-stack-auto/spec.mk,
6148         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6149         * device/lib/mcs51/Makefile,
6150         * device/lib/small/Makefile,
6151         * device/lib/large/Makefile,
6152         * device/lib/mcs51/crtpagesfr.asm,
6153         * device/lib/mcs51/crtstart.asm,
6154         * device/lib/mcs51/crtxclear.asm,
6155         * device/lib/mcs51/crtxinit.asm,
6156         * device/lib/mcs51/crtclear.asm,
6157         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6158         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6159         and into user configurable files.
6160         * device/lib/clean.mk: clean mcs51 directory too
6161         * support/regression/tests/longlit.c: added static to T1 declaration
6162         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6163         accesses in the initialization code
6164
6165 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6166
6167         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6168         OSCTRIMVAL as noted in bug #916008
6169
6170 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6171
6172         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6173         in loops with multiple exits (reported as incorrect registers
6174         used by Martin Helmling in Sdcc-user list)
6175
6176 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6177
6178         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6179         made ds390 register extensions look less like error messages
6180
6181 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6182
6183         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6184         reported by Adam Wozniak in Sdcc-user list
6185
6186 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6187
6188         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6189         arithmetic optimizations, added debug output
6190
6191 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6192
6193         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6194         * sdcc.spec: updated and split sdcc into 3 rpms
6195         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6196         needed for literals of LEFT_OP and '+'
6197         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6198         introduced RESULT_TYPE_NOPROM
6199         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6200         left shift
6201         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6202         limited promotion to int only for '*'
6203         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6204
6205 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6206
6207         * src/pic16/gen.c (genSkip),
6208         (genc16bit2lit), (gencjneshort): commented out
6209         (is_LitOp): new helper function, checks operand type
6210         (genCmpEq): rewritten
6211
6212 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6213
6214         * support/regression/tests/bug-908454.c: added
6215
6216 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6217
6218         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6219         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6220         (geniCodeCast): cosmetic, don't preserve bit storage class
6221         (geniCodeLeftShift): added promotion
6222         (geniCodeLogic): fixed regression
6223         * src/SDCCsymt.c (computeTypeOr): accept bits too
6224         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6225
6226 2004-03-07  Borut Razem <borut.razem AT siol.net>
6227
6228         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6229
6230 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6231
6232         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6233         version of pic16_genPackRegisters which does not check if ic is a
6234         CAST operator,
6235         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6236         function cause string1.c regression test fails
6237
6238 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6239
6240         * sim/ucsim/configure.in,
6241         * sim/ucsim/configure,
6242         * sim/ucsim/doc/Makefile.in: use docdir
6243         * src/SDCC.y: fixed sbit atrributes
6244         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6245         * src/SDCCast.c (decorateType): |^& need special promotion handling
6246         * src/SDCCast.h,
6247         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6248         * src/SDCCsymt.h (computeType),
6249         * src/SDCCicode.c: computeType() needs op
6250         * src/SDCCsymt.c (checkTypeSanity),
6251         * doc/sddman.lyx: "plain" bitfields are unsigned
6252         * src/SDCCsymt.c (computeTypeOr): added
6253         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6254         |^& ops
6255         * src/SDCCval.c (val*): computeType() needs op
6256         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6257         * support/regression/tests/onebyte.c: added tests for |^&
6258
6259 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6260
6261         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6262         for writing icode into asm output.
6263
6264 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6265
6266         * src/pic16/device.c: added some debug lines enabled
6267         with macro DEBUG_CHECK,
6268         * src/pic16/genarith.c: more debug in genPlus,
6269         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6270         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6271         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6272         * (aopForSym): onStack symbols are re-placed in data memspace,
6273         and onStack flag is cleared,
6274         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6275         copy temporary pcodeop,
6276         * (genPcall): added warning for not updating PCLATU,
6277         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6278         always true for pic16 port,
6279         * (genMultOneWord): NEW, supports integer multiplication,
6280         * (genMult): modified to call genMultOneWord,
6281         * (ifxForOp): added warning when return NULL,
6282         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6283         flag is set before call to operandFromSymbol for implicit
6284         added structures,
6285         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6286         options.intlong_rent are set by default,
6287         * (_hasNativeMulFor): modified to allow port generation of integer
6288         multiplication,
6289         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6290         set regtype to REG_SFR for all registers, restricting seting the
6291         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6292
6293 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6294
6295         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6296         more than 500 times in the regression tests
6297
6298 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6299
6300         * support/Util/SDCCerr.h,
6301         * support/Util/SDCCerr.c,
6302         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6303         enumerator_list),
6304         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6305         for symbol conflicts.
6306         * support/valdiags/tests/enum.c,
6307         * support/valdiags/tests/tentdecl.c,
6308         * support/valdiags/tests/struct.c: expect possible error messages
6309         referring to original symbol definitions.
6310         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6311         * src/SDCCsymt.h,
6312         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6313
6314 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6315
6316         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6317
6318 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6319
6320         * src/pic16/ralloc.c (newReg): fixed bug #908929
6321
6322 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6323
6324         * src/ds390/gen.c: added missing #include "main.h"
6325
6326 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6327
6328         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6329         checking if symbol is already in set,
6330         * src/pic16/device.h: prototype for checkAddSym,
6331         * src/pic16/gen.c: (_G): added entry interruptvector,
6332         * (assignResultValue): removed some commented out lines,
6333         * (genFunction): check for ISR via sym->type, absolute section for
6334         interrupt code is created via a new pBlock, the goto instruction is
6335         placed now correctly at the interrupt vector position, changed all
6336         references from ivec to _G.interruptvector,
6337         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6338         is the interrupt is a high priority one, same for return from ISR,
6339         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6340         externs to calls of checkAddSym,
6341         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6342         pic16_pcode_verbose flag is set,
6343         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6344         * src/pic16/pcoderegs.c: message about how many registers are saved
6345         will only be emitted if pic16_pcode_verbose flag is set,
6346
6347 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6348
6349         * src/ds390/ralloc.h,
6350         * src/ds390/ralloc.c (ds390_regWithIdx),
6351         * src/ds390/gen.c (emitcode),
6352         * src/ds390/main.h,
6353         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6354         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6355         ds390operandCompare, getRegsRead, getRegsWritten,
6356         initializeAsmLineNode): customized instruction size calculation for
6357         ds390, started basis for some register optimizations
6358         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6359         corresponding assembly output
6360         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6361         missing push/pop of r0/r1. Optimized push/pops
6362
6363 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6364
6365         * src/mcs51/main.c (instructionSize): fixed ACALL size
6366         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6367
6368 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6369
6370         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6371         the sorting of rlist with NULL elements
6372         * (print_idataType, print_idata): NEW to create idata sections
6373         * src/pic16/device.h: idataSymSet new variable
6374         * src/pic16/gen.c (genFunction): fixed some bugs in string
6375         comparing, improved the absolute section creation for ISRs,
6376         added FSR0L/FSR0H in registers that are saved in an ISR,
6377         * (genInline): fixed the processing of inline snippets,
6378         now they undergo no process by the peephole optimizer
6379         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6380         are placed in idataSymSet,
6381         * (pic16emitStaticSeg): extern symbols are added in externs,
6382         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6383         switching when aboslute variables are placed in access bank memory
6384         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6385         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6386         commented out with #if,
6387         * (pic16_packRegisters): reintroduce the check for CAST because some
6388         symbols are not correctly handled,
6389         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6390         pCodeInstruction instead of pCode,
6391         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6392         pCodeAsmDir definition,
6393         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6394         directive, then the argument directive is emitted without the leading
6395         tab, hack for inline labels which must be in the first column,
6396         * (compareLabel,pic16_findNextInstruction),
6397         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6398         * (insertBankSwitch): modified for the new pCodeAsmDir,
6399
6400 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6401         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6402
6403         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6404         instance,
6405         * (pushSide): commented out with #if,
6406         * (assignResultValue): fixed some typos in saving
6407         registers,
6408         * (genPcall): FIXED and sync'ed with genCall,
6409         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6410         * (genNearPointerGet): fixed to handle some more cases,
6411         implementation scheme via table reads,
6412         * (genConstPointerGet): modified to access code memory correct,
6413         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6414         and improved to handle some cases
6415         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6416         instead of "RETLW" for init data
6417         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6418         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6419         variables are placed in access bank memory (<0x80 and >=0xf80),
6420         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6421         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6422         TBLWT_POSTDEC,TBLWT_PREINC
6423         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6424         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6425         directives
6426         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6427         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6428         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6429         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6430
6431 2004-02-29  Borut Razem <borut.razem AT siol.net>
6432
6433         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6434         support/Util/findme.h, support/Util/system.h: enhance binary relative
6435         search for lib and include by using findProgramPath()
6436
6437 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6438
6439         * src/SDCCpeeph.h,
6440         * src/SDCCpeeph.c (pcDistance),
6441         * src/port.h,
6442         * src/mcs51/ralloc.h,
6443         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6444         * src/mcs51/main.h,
6445         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6446         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6447         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6448         size calculation port specific, started basis for some register
6449         optimizations
6450         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6451         missing push/pop of r0/r1. Optimized push/pops
6452         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6453         * device/lib/_modsint.c (_modsint),
6454         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6455         and stack version so regression tests pass
6456
6457 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6458
6459         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6460         * src/SDCCast.c (decorateType): catch another small optimization
6461         with '?' operator
6462         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6463         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6464         modified to finally use computeType() all over SDCC,
6465         see Feature Request #877103
6466         * src/SDCCval.h: cosmetic
6467         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6468         valCompare(); regression tested in muldiv.c
6469         * support/regression/tests/muldiv.c (testMod): mod sign follows
6470         dividend only
6471
6472 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6473
6474         * src/SDCCast.c (decorateType): fixed bug #902362
6475         * doc/INSTALL.txt: fixed install instructions for win32
6476
6477 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6478
6479         * device/include/Makefile.in (install): fixed by replacing spaces
6480         by tabs
6481         * doc/README.txt,
6482         * doc/INSTALL.txt: updated for release
6483         * doc/sdccman.lyx: added warning for --xstack being buggy
6484
6485 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6486
6487         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6488         to eliminate build warnings.
6489         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6490
6491 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6492            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6493
6494         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6495         removed -penable-stack, added comment for stack pragma, added
6496         warning for not initializing the stack/frame registers, removed
6497         comment at interrupts section
6498
6499         Stack is made permanent, there is no ability to disable stack usage.
6500         * src/pic16/device.h,
6501         * src/pic16/device.c: removed all references to USE_STACK macro,
6502         * src/pic16/device.c (pic16_dump_section): when no elements in
6503         rlist, free rlist before return,
6504         * (pic16_dump_int_registers): NEW, internal registers are a new set
6505         of general purpose registers reused by each function,
6506         * (checkAddReg): returns 1 if registers is added to set,
6507         * (pic16_groupRegistersInSection): when a registers is of type
6508         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6509         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6510         SRCASECMP macro is moved here from device.c
6511         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6512         PO_PCLATU, PO_PRODL, PO_PRODH,
6513         * (pic16_pCodeOpType, genMinus,
6514         changed compares to "a" register, with AOP_ACC,
6515         * (pic16_genPlus): fixed some bugs and indented properly,
6516         * (pic16_addSign): changed size to size+offset in the MOVWF
6517         instruction,
6518         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6519         multiply 8-bit operand by literal, result is 8-bit,
6520         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6521         multiply 2 8-bit operand, result is 8-bit,
6522         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6523         genUMult8X*_16,
6524         * src/pic16/gen.c: changed accUse to contain WREG only,
6525         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6526         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6527         true, do not use immediate addressing any more unless sym is a
6528         pointer in codespace,
6529         * (aopForRemat): do not use immediate addressing when symbol not in
6530         codespace and when symbol's address is requested,
6531         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6532         accUse size (= 1),
6533         * (aopGet): added case for AOP_ACC and don't return "accumulator
6534         bug" but WREG instead,
6535         * (popGetTempReg): pushes contents of temporary register in stack,
6536         * (popReleaseTempReg): pops contents of temporary register from
6537         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
6538         * (pic16_popGet): separated case AOP_ACC to return register WREG
6539         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
6540         or PO_IMMEDIATE and initializes their instance/offset appropriately,
6541         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
6542         the use of immediate pointers to certain cases only.
6543
6544         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
6545         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
6546         * (assignResultValue, genCall, genRet): modified to use the new
6547         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
6548         genPcall is still broken,
6549         * (genFunction): added code to create 'A' type pBlocks when
6550         interrupt functions are generated, code not extensively tested yet,
6551         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
6552         * (genEndFunction): modified so ISRs pop stored registers from stack,
6553         * (genMultOneByte): cleanup,
6554         * (AccRsh): added flag andmask, to and result with appropriate mask,
6555         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
6556         * (genDataPointerGet): fixed and reenabled its use,
6557         * (genNearDataPointerGet): bugs fixed,
6558         * (genDataPointerSet): bugs fixed,
6559         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
6560         pic16_DumpSymbol, pic16_DumpOp,
6561         * src/pic16/genutils.h: function prototypes for the above functions,
6562         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
6563         pointers,
6564         * (pic16emitRegularMap): many many many improvements, but needs a
6565         major cleanup,
6566         * src/pic16/main.c: enable_stack in pic16_options is removed,
6567         * (_pic16_parseOptions): removed command line options -penable-stack,
6568         * (_process_pragma): emit stack symbol only when stack pragma is
6569         processed,
6570         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
6571         redirected to FSR0L/FSR0H pair,
6572         * (pic16_get_op, pic16_get_op2): modifications and improvements,
6573         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
6574         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
6575         for immediates,
6576         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
6577         * (dumpPicOptype): NEW,
6578         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
6579         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
6580         with movff instruction,
6581         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
6582         added pic16_int_regs, some packRegsFor* functions are commented out,
6583         because produce errors,
6584         * src/pic16/NOTES: minor modifications
6585
6586 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6587
6588         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
6589         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
6590         --pack-iram.
6591         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
6592         * as/mcs51/lkaomf51.c: fixed bug #895763
6593
6594 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
6595
6596         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
6597
6598 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6599
6600         * doc/sdccman.lyx: added details about the HC08 storage classes and
6601         interrupts, fixed the register usage info for z80 & gbz80
6602
6603 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
6604
6605         * doc/sdccman.lyx: added more pic16 port documentation
6606         * device/include/pic16/: added header pic18fregs.h
6607
6608 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
6609
6610         * doc/sdccman.lyx: added Vangelis' contribution
6611
6612 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6613
6614         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
6615         extend to the next CALL or PCALL, not just to the next CALL.
6616
6617 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
6618
6619         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
6620
6621 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6622
6623         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
6624         bug #895752 and a better fix for bug #716790
6625
6626 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6627
6628         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
6629
6630 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6631
6632         * doc/sdccman.lyx: minor changes, minor changed
6633
6634 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
6635
6636         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
6637         which can't handle SDCC_NEWONEBYTEOPS,
6638         (geniCodeMultiply): removed conversion from mult to shift for pic14
6639         and pic16
6640
6641 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6642
6643         * src/hc08/gen.h,
6644         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
6645         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
6646         thus fixing bug #895406
6647
6648 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
6649
6650         * device/lib/_modsint.c,
6651         * device/lib/_modslong.c: sign follows divisor only
6652         * src/hc08/gen.c (genMultOneByte): if result size is 1,
6653         signs or signedness can be ignored
6654         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
6655         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
6656         added optimization for IFX,
6657         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
6658         arguments;
6659         reenabled optimization for IFX, which was removed on 2004-01-11
6660         * src/SDCCast.h: added return type IFX
6661         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
6662         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
6663         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
6664         SDCC_OLDONEBYTEOPS selects the old behaviour
6665         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
6666         changed again and commented promotion rule
6667         * src/SDCCval.c (valDiv): promotion no longer necessary
6668         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
6669         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
6670         rewritten
6671         * support/regression/tests/onebyte.c: added
6672
6673 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
6674
6675         * gen.c (genInline): reverted to old code for assemnling inline
6676         code because of bug reported James Chadd
6677
6678 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
6679
6680         * ralloc.h: missing declarations from previous patch,
6681         seems that patch for ralloc.h was never applied, fixed
6682
6683 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6684            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
6685
6686         * pcode.c,
6687         * pcode.h,
6688         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
6689         indirect addressing. Marked FSR0 as deprecated
6690         * gen.c (pointerCode): commented out, not needed now
6691         (pic16_popGet2p): new MOVFF helper function
6692         (genGenPointerGet),
6693         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
6694         (shiftRLong): removed duplicate debugging info
6695
6696 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6697
6698         * src/ds390/gen.c (genNearPointerGet),
6699         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
6700         optimization with bits, but not bitfields.
6701         * src/ds390/ralloc.c (packRegisters),
6702         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
6703
6704 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
6705
6706         * src/SDCCcse.c (algebraicOpts): copy operands before modification
6707
6708 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6709
6710         * src/SDCCsymt.h,
6711         * src/SDCCicode.c (operandFromSymbol),
6712         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
6713         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
6714         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
6715         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
6716         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
6717         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
6718         bug #892038
6719         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
6720         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
6721         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
6722         * src/SDCCsymt.c (newSymbol),
6723         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6724         enumerator_list),
6725         * src/SDCCval.h,
6726         * src/SDCCval.c (newiList): fixed bug #885705
6727
6728 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6729
6730         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
6731         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
6732
6733 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6734
6735         * device/include/c8051f120.h,
6736         * device/include/c8051f300.h,
6737         * device/include/c8051f310.h: added/updated header files for Silicon
6738         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
6739         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
6740         in new section Submitting patches
6741
6742 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6743
6744         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
6745         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6746         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6747         genGenPointerSet),
6748         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
6749         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6750         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6751         genGenPointerSet),
6752         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
6753         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6754         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6755         genGenPointerSet),
6756         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
6757         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6758         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6759         genGenPointerSet): fixed bug #892400
6760         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
6761         to eliminate build warnings.
6762         * src/SDCCast.c (processParms),
6763         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
6764         fixed bug 751859
6765         * support/valdiag/valdiag.py: added GCC to the list of defines active
6766         when compiling with gcc
6767
6768 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6769
6770         * support/Util/SDCCerr.h,
6771         * support/Util/SDCCerr.c,
6772         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
6773         with an incomplete type (fixed bug #883734)
6774         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
6775
6776 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6777
6778         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
6779
6780 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6781
6782         * src/SDCCast.c (decorateType),
6783         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
6784         function pointer implementation
6785         * support/regression/tests/funptrs.c: added tests to verify both forms
6786         of function pointers work correctly. Added tests to verify parameters
6787         are passed in the correct order.
6788
6789 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
6790
6791         * device.c (regCompare): registers are sorted by ascending
6792         address and increasing size,
6793         * main.c (_pic16_finaliseOptions): removed the declaration
6794         of compiler macro MCU. Now a macro of the format pic18fxxxx
6795         will be defined from the command line
6796
6797 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6798             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
6799
6800         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
6801         PCOP_RLCF was overwritten!
6802         * gen.c (genSkip): commented out calls to pic16_emitcode,
6803         * (genCmpEQ): fixed "long" compares, only high word did get compared,
6804         * (genlshTwo),
6805         * (genRRC): added debugging info,
6806         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
6807         overwritten while shifting,
6808         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
6809         overwritten while shifting,
6810         * (AccLsh),
6811         * (AccRsh),
6812         * (shiftLLeftOrResult),
6813         * (shiftRLeftOrResult),
6814         * (shiftRLong),
6815         * (shiftLLong): Implemented with pic16_emitpcode
6816         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
6817         * (genLeftShift): Fixed bug, operand for shift by variable always
6818         was "and"ed with 0x0f,
6819         * (genLeftShiftLiteral),
6820         * (genrshTwo),
6821         * (genRightShiftLiteral): added debugging info,
6822         * (genrshFour): added comment,
6823         * (genRightShift): determined signedness from operand "left"
6824         instead of "result"
6825
6826 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6827
6828         * src/SDCCicode.c (geniCodeParms),
6829         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
6830         function pointers, fixed function pointer bugs #861242 and #861896
6831
6832 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6833
6834         * device/include/c8051f000.h,
6835         * device/include/c8051f120.h,
6836         * device/include/c8051f300.h: added header files for Silicon
6837         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
6838
6839 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
6840
6841         * src/SDCCast.c (processParams): added new type flow and restructured
6842         (gatherAutoInit): added new type flow
6843         (addCast): cosmetic changes
6844         (getLeftResultType): added new type flow for array indices, patch
6845         provided by Stas, see FR #877103
6846         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
6847         array index patch by Stas
6848         * src/SDCCast.h: added prototype getResultTypeFromType()
6849         * src/SDCCval.h,
6850         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
6851         * src/pic/glue.c (pic14emitStaticSeg),
6852         * src/pic16/glue.c (pic16emitStaticSeg),
6853         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
6854         for initialization of symbols
6855         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
6856         * support/Util/SDCCerr.h:
6857         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
6858         * .version: bumped version number to 2.3.8
6859         * device/include/Makefile.in (install),
6860         * doc/Makefile (install): changed to 'rm `find ...`' construct to
6861         avoid warnings
6862
6863 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
6864
6865         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
6866         Slade Rich fixed an optimization bug
6867         * src/pic/pcodepeep.c,
6868         * src/pic/pcoderegs.c
6869         * doc/Makefile (install): added test for directory
6870
6871 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6872
6873         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
6874         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
6875         * src/pic/ralloc.c (getRegPtr, getRegGpr),
6876         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
6877         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
6878         * as/mcs51/asexpr.c (term),
6879         * as/hc08/asexpr.c (term): fixed bug #887146
6880
6881 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6882
6883         * src/z80/gen.c (genMult): handle single byte result product
6884         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
6885         DUMMY_READ_VOLATILE (fixed bug #886367)
6886
6887 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
6888
6889         * support/regression/tests/libmullong.c: fixed logic, on little endian
6890         hosts we ended without a mullong_wrapper()
6891
6892 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6893
6894         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
6895         virus/worm forged address usage.
6896
6897 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
6898
6899         Fixed promotion, it should be done on AST level:
6900         * src/SDCCast.c (addCast): added promotion to int
6901         (decorateType): updated call to upCast()
6902         * src/SDCCicode.c (geniCodeLeftShift): removed call to
6903         usualUnaryConversions()
6904
6905 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
6906
6907         * support/regression/tests/literalop.c (mulWrapper): Added a
6908         wrapper to remove integer overflow warnings.
6909
6910         * support/regression/tests/float_trans.c: Made work on host.
6911
6912         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
6913         location of sz80.
6914
6915         * support/regression/generate-cases.py (main): Changed from inline
6916         to a main method.
6917
6918         * doc/Makefile (install): Changed to depth first to get rid of
6919         missing directory install warning.
6920
6921         * as/Makefile (install-doc): Made work on Mac.
6922
6923 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
6924
6925         * src/SDCCast.c: added an additional type flow in decorateType() of
6926         opposite direction, see feature request #860006; it's enabled at runtime
6927         by setting the environment variable SDCC_NEWTYPEFLOW
6928         * src/SDCCast.h: changed prototype of decorateType()
6929         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
6930         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
6931         'char' to 'int' can be omitted, if both operands are 'unsigned char';
6932         see feature request #877103
6933         * src/SDCCval.c: updated call of decorateType()
6934         (valBitwise): fixed bug #882876
6935         (valMinus): added promotion
6936         (valLogicAndOr): result is unsigned
6937         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
6938         * src/SDCCsymt.c (computeType),
6939         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
6940         must not cause an unsigned operation
6941         * src/pic/glue (pic14emitRegularMap),
6942         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
6943
6944 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
6945
6946         * src/pic/pcode.c (PCodeID): commented out left over debug code
6947
6948 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
6949
6950         * support/valdiag/tests/overflow.c: added shift tests
6951         * src/pic/device.c,
6952         * src/pic/gen.c,
6953         * src/pic/gen.h,
6954         * src/pic/glue.c,
6955         * src/pic/main.c,
6956         * src/pic/pcode.c,
6957         * src/pic/pcode.h,
6958         * src/pic/pcodepeep.c,
6959         * src/pic/pcoderegs.c,
6960         * src/pic/ralloc.c,
6961         * src/pic/ralloc.h: applied patch from Slade Rich;
6962         added support for multiple code pages and multiple RAM banks on the
6963         PIC 14 port. The ASM files now no longer simply assume all the
6964         code / RAM are in the same page / bank. This means the linker can
6965         safely allocate code/RAM of separate ASM files to different pages/banks.
6966         * doc/sdccman.lyx: added Slade's tips
6967         * src/mcs51/peeph.def: fixed bug #880768
6968
6969 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6970
6971         * src/hc08/ralloc.c (rematStr): fixed bug #879282
6972         * src/SDCCast.c (decorateType): fixed bug #880197
6973
6974 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
6975
6976         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
6977         getopt.h.
6978
6979         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
6980         strtof is not part of C89 and isn't included with Mac OS X.
6981
6982 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6983
6984         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
6985         shiftL2Left2Result): fixed bug #879326
6986         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
6987         (genMultOneByte): fixed bug in signed vs unsigned multiplication
6988         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
6989         address fetch for clr instruction
6990         * device/lib/hc08/_mulint.c: created optimized assembly version
6991         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
6992
6993 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
6994
6995         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
6996         proposed in FR #877103
6997
6998 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
6999
7000         * src/SDCCval.c (cheapestVal): added missing checks
7001         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7002         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7003
7004 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7005
7006         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7007         equal operands
7008
7009 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7010
7011         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7012         loaded with the linker search paths (-L arguments) and the libraries
7013         to be linked with the current source (-l arguments). Changes
7014         currently will affect only the pic16 port.
7015         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7016         include path the port specific paths and port specific libraries,
7017         * gplink command now contains the $3 argument,
7018         * src/pic16/device.h,
7019         * src/pic16/device.c,: structure PIC_device is made public and
7020         renamed to PIC16_device, the same for variable Pics which is renamed
7021         to Pics16. Updated all references to them.
7022         * src/pic16/glue.c (pic16glue): corrected bug with code
7023         initialization which bypassed the variable initializations block.
7024
7025         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7026         COMPILE_FLAGS and added the --nostdinc option
7027
7028 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7029
7030         * device/include/mc68hc908jb8.h: Register defs for another member
7031         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7032
7033 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7034
7035         Documenting changes from previous commits.
7036         * configure.in (version 1.56),
7037         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7038         when generating output files to configure the pic16 library,
7039         but now I've commented it out, since gputils aren't installed in the
7040         SF compile farm, so library won't compile
7041
7042         * device/lib/Makefile.in (version 1.56): initially I've added in
7043         target 'all' the prerequestive 'model-pic16' so it compiled the
7044         pic16 library, but now I've commented it out for the same reasons
7045         above,
7046         * added targets 'model-pic16' and 'objects-pic16' to compile the
7047         library
7048         * added target 'port-specific-objects-pic16' to handle the
7049         generated libraries and copy them into the build/ directory
7050         * added target 'clean-intermediate-pic16' to clean intermediate
7051         files into pic16 directory
7052         * in target 'installdirs' added line to create directory pic16 in
7053         the installation path
7054
7055         * device/include/Makefile.in (version 1.11): in target 'install'
7056         added lines to copy all header files to installation path,
7057         * in target 'installdirs' added line create directory for pic16
7058         headers in the installation path
7059
7060 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7061
7062         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7063          a function call
7064
7065 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7066
7067         * configure,
7068         * device/lib/configure.in,
7069         * device/lib/configure: fixed for autoconf 2.57
7070
7071 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7072
7073         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7074         option so that it actually works. Made it specific to the z80, since
7075         the gbz80 doesn't have these kinds of I/O ports.
7076
7077 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7078
7079         * device/include/z180.h,
7080         * device/lib/_memcpy.c,
7081         * device/lib/_memmove.c,
7082         * device/lib/_mulint.c,
7083         * device/lib/ser_ir.c,
7084         * device/lib/ser_ir_cts_rts.c,
7085         * device/lib/_strcmp.c,
7086         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7087         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7088         portmode; added deprecation warning for bank= and protmode= forms.
7089         Also, guard against buffer overflow.
7090         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7091
7092 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7093
7094         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7095         changed interrupt vector table generation to only emit declared vectors.
7096         * device/include/Makefile.in: added missing backslash
7097         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7098
7099 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7100
7101         Mainly changes to support compilation of the device libraries
7102         * src/pic16/device.c: stack is allocated via symbol and not
7103         via literal number. The symbol is placed in the corresponding
7104         position of the data ram
7105         * (pic16_dump_section): relocatable and absolute uninitialized
7106         data are now emitted in sorted order to reduce section naming,
7107         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7108         weren't marked as being in the access bank,
7109
7110 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7111
7112         Added portion of GNU PIC Library under the directory
7113         device/include/pic16 and device/lib/pic16. These files
7114         contain the declarations of SFRs for the PIC18Fxx2 devices.
7115         The directory is initialized via configure from toplevel.
7116
7117 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7118
7119         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7120         the spilllocations to be compared correctly
7121
7122 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7123
7124         * src/SDCCast.c (decorateType): fixed bug introduced today
7125
7126 2004-01-12  Borut Razem <borut.razem AT siol.net>
7127
7128         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7129         doc/sdccman.lyx: upper case pragmas are deprecated
7130
7131 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7132
7133         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7134         in simpler and even better code
7135
7136 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7137
7138         * src/SDCCicode.c (operandOperation): fixed bug #874819
7139         * src/SDCCast.c (decorateType): fixed
7140         char foo (unsigned long ul) { return ul > 0; }
7141
7142 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7143
7144         * doc/sdccman.lyx: Moved and added some sections, small changes
7145         all over. Telling LaTeX to be less strict with word spacing
7146         to better keep the right margin. Changed some notes about
7147         maintainance of the ports in section 3.2.1 - is it OK like this?
7148
7149 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7150
7151         SDCC source changes:
7152         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7153         convilong): modified to inform the pic16 port that builtin functions
7154         are external
7155
7156         PIC16 PORT specific changes:
7157         * src/pic16/device.c pic16_dump_equates() added,
7158         processor registers declared internally by the port are emitted in
7159         the translation as equates,
7160         * src/pic16/gen.c: inline code is passed unprocessed to the
7161         translation,
7162         * (pic16_popGetLit2): fnuction modified to take second operand as
7163         pCodeOp pointer and not as literal,
7164         * (popRegFromIdx): prefixed with pic16_,
7165         * (pic16_popCombine2): modified to receive already allocated pCode
7166         operands,
7167         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7168         * (genFunction): initializes local stack frame and pushes on stack
7169         all the registers used by this function,
7170         * (genEndFunction): restores all registers from stack and restores
7171         stack frame,
7172         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7173         improvements,
7174         * (pic16glue): changed the program startup sequence,
7175         * added new dbName code 'A' for functions placed in absolute section
7176         * src/pic16/main.c: added function attribute _naked,
7177         * added pragma 'code' to place a fnuction at an absolute address,
7178         * added command line arguments --debug-ralloc and --pcode-verbose,
7179         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7180         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7181         * (pic16_newpCodeOpLit2): modified to take the second operand as
7182         pCodeOp pointer,
7183         * (pic16_printpBlock): modified to emit each function in a separate
7184         section,
7185         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7186         UPPER for immediate operands,
7187         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7188         instruction,
7189         * src/pic16/peeph.def: all peepholes with movff are commented out,
7190         because there is a problem in the pcode peep optimizer,
7191         * src/pic16/ralloc.c: the register allocator can now reuse local
7192         function symbols for another function. This saves register usage.
7193         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7194
7195         Added file src/pic16/NOTES with information about program writing on
7196         the current port version.
7197
7198 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7199
7200         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7201         and peephole 252 (array access)
7202
7203 2004-01-09  Borut Razem <borut.razem AT siol.net>
7204
7205         * src/SDCCmain.c : fixed #872250: -l command line defined library
7206           files are scanned before standard library files
7207
7208 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7209
7210         * src/SDCCast.c (decorateType): fixed bug #874046
7211
7212 2004-01-09  Borut Razem <borut.razem AT siol.net>
7213
7214         * support/scripts/sdcc.nsi: remove previous installation
7215
7216 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7217
7218         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7219         bytes for last interrupt vector (mcs51)
7220         * sdcc.spec: fixed typo
7221
7222 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7223
7224         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7225         gen51Code): more efficient parameter receive for --model-large
7226         ("bug" #845294)
7227
7228 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7229
7230         * src/ds390/main.c,
7231         * src/z80/main.c: added missed needLinkerScript flags (more than
7232         one port structure defined in these file)
7233         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7234         bug #795325
7235
7236 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7237
7238         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7239         * src/port.h: added flag needLinkerScript in port->linker
7240         structure to inform whether to create a .lnk file or not,
7241         * src/avr/main.c,
7242         * src/ds390/main.c,
7243         * src/hc08/main.c,
7244         * src/mcs51/main.c,
7245         * src/pic/main.c,
7246         * src/pic16/main.c,
7247         * src/xa51/main.c,
7248         * src/z80/main.c: changed appropriately to configure
7249         needLinkerScript flag
7250         * src/pic/gen.c,
7251         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7252         * src/pic/glue.c: added variable udata_section_name to
7253         override default uninitialized data segment definition for
7254         devices only with SHAREBANK memory (reported from Erik Epetrich)
7255         * (pic14emitOverlay): modified to emit a commented overlay segment
7256         directive when no overlay data exist
7257         * (picglue): modified to emit uninitialized data segment
7258         according to udata_section_name
7259         * src/pic/main.c (_pic14_parseOptions): added command line
7260         options --udata-section-name=[name] to override default
7261         udata definition name
7262         * modified _linkCmd and _asmCmd to include compiler passed
7263         arguments via -W option
7264         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7265         object file from '.rel' to '.o' in port->linker structure,
7266         changed size of fptr from 2 to 3 in port structure
7267
7268 2004-01-07  Borut Razem <borut.razem AT siol.net>
7269
7270         * support/scripts/sdcc.nsi: update PATH
7271         * support/scripts/sdcc.ico: craeted
7272
7273 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7274
7275         * device/include/Makefile.in: fix install
7276         * doc/Makefile: fix install
7277
7278 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7279
7280         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7281         in bug #860505
7282         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7283         how the function variable allocation summary is displayed; also
7284         include information about variables allocated to the overlay
7285         segment
7286
7287 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7288
7289         * as/mcs51/lkmain.c: Help about -Y option
7290         * as/mcs51/lkarea.c: Fixed gcc warnings
7291
7292 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7293
7294         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7295         fixed warning
7296         * support/valdiag/tests/overflow.c: added
7297         * src/SDCCast.c (decorateType),
7298         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7299         LEFT_OP (left shift)
7300
7301 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7302
7303         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7304         (default behaviour).
7305
7306 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7307
7308         A python script to validate compiler diagnostic messages. It can be
7309         used to verify that sdcc complains about bad c source code and
7310         gives a good location of the error.
7311         * support/valdiag/Makefile,
7312         * support/valdiag/valdiag.py,
7313         * support/valdiag/tests/*
7314
7315 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7316
7317         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7318         * src/SDCCsymt.c (newEnumType),
7319         * src/SDCCsymt.h
7320         * support/Util/SDCCerr.c,
7321         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7322         enum related bugs.
7323         * support/regression/tests/enum.c: added test for enum values that
7324         require at least 2 bytes of storage.
7325
7326 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7327
7328         * src/common.h: added ifndef/define/endif macros
7329         around the header file.
7330         Bug reported from Jesus Calvino-Fraga
7331
7332 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7333
7334         * sdcc.spec: updated
7335         * device/include/Makefile.in: don't install CVS directories
7336         * device/lib/Makefile.in: added removal of CVS directories after install
7337         * doc/Makefile: fixed install, added local_icons
7338         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7339         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7340         * src/ds390/gen.c (genRightShift): fixed bug #870788
7341         * src/SDCCast.c (decorateType): fixed bug #870781
7342
7343 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7344
7345         PIC16 port related changes:
7346         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7347         added variable stackPos,
7348
7349         * gen.c: genCall, assignResultValue: added support for
7350         pushing/retrieving function parameters to/from stack,
7351         genFunction,genEndFunction: setup stack frame for the
7352         generated function,
7353         genAddrOf: will be changed according to bug 863624
7354
7355         * added files genutils.c and genutils.h which contain gen*
7356         debugged and optimised functions extracted from gen.c
7357
7358         * glue.c: added variable 'externs' which holds extern symbols,
7359         pic16emitRegularMap: is modified to properly handle relocatable
7360          symbols under the new scheme,
7361         pic16createInterruptVect: is modified
7362         pic16printPublics: is modified to emit 'global' assembler directives,
7363         added pic16_printExterns to print extern symbols,
7364         pic16glue: initializes stack/frame pointer in the beginning of
7365         the assembly output. Temporary hack, will be corrected later,
7366         because gplink yet does not support stack and SDCC does not
7367         yet support a type of crt0.o object to create the final binary.
7368
7369         * Removed many lines that contain 8051 legacy code.
7370         * The code is finally placed under a 'code' directive.
7371         * Added port specific options.
7372
7373         * _process_pragma: simplified since now we do not need *special*
7374         include file to define SFR registers. But a separate header
7375         will be needed. This will be developed later.
7376         * _pic16_parseOptions: added, parses port specific options:
7377         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7378         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7379         --preplace-udata-with=
7380
7381         * _pic16_setDefaultOptions: modified to initialize section names,
7382         but hack is temporarly out of order since it needs improvement.
7383         * _pic16_genAssemblerPreamble: configuration words are emitted by
7384         their address instead of their name. This part is incomplete and
7385         supports only the 18Fxx2 devices. Other devices will emit an error
7386         during assembly since they do not contain the same set of config
7387         registers
7388         * _pic16_genIVT: is modified,
7389
7390         * pcode.c: added definitions for some hardware registers that are needed
7391         for stack support
7392         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7393         All PCI entries are updated. Now LFSR is supported.
7394         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7395         * added pic16_newpCodeOpLit2 to support instructions with
7396         two literal arguments
7397         * pic16_pCode2str: corrected code that emits assembler instructions
7398         with two literal operands and those that have an access bit modifier
7399         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7400         this fixes a bug which caused some labels to be lost, when an
7401         assembler directive was added, i.e. banksel,
7402         * pic16_FixRegisterBanking: improved logic that causes the insertion
7403         of bank switching,
7404         * InlineFunction: functions that are called once, are not any more
7405         inlined. This can be a port option in the future,
7406
7407         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7408
7409         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7410         hold the corresponding uninitialized symbols,
7411         * pic16_allocProcessorRegister: registers have explicit marked the
7412         accessBank field,
7413         * pic16_allocInternalRegister: registers are explicit marked as
7414         not used,
7415         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7416         processing list, so bit registers were lost,
7417         *
7418
7419         * ralloc.h: added field 'accessBank' and original symbol operand
7420         in register definition,
7421         * removed the field isMapped from register definition,
7422
7423         ** Several functions have been removed from various sources:
7424         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7425         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7426         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7427         pic16_assignRelocatableRegisters
7428
7429         ** others have been introduced:
7430         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7431         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7432
7433 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7434
7435         * support/scripts/inc2h.pl: changed definition of BIT_AT
7436         to emit 'sbit at' instead of 'bit at'. This was a request.
7437
7438         PIC16 port related preliminary changes:
7439         * gen.c: prefixed function popRegFromString with
7440         pic16_ and all references to it corrected
7441         * pcode.c: all pic16_pc_* hardware registers prefixed
7442         with underscore (_),
7443         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7444         * ralloc.c: newReg(): when register is REG_SFR then
7445         set address to rIdx,
7446         pic16_allocProcessorRegister(): marks register wasUsed=0
7447         pic16_writeUsedRegs(): added a call to assign processor
7448         registers via pic16_assignFixedRegisters
7449
7450 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7451
7452         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7453         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7454         variables in unused register banks.  Also the SSEG is placed
7455         wherever there is enough space for it, and IDATA can be anywhere
7456         in internal RAM.  For now compile using -Wl-Y[stack_size].
7457         The mem file is different for this option as well, since it
7458         makes no sense of talking about DSEG lenght.
7459
7460 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7461
7462         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7463         in certain cases, e.g. when ROM assignment, patch provided
7464         from Albert den Haan.
7465
7466 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7467
7468         Many signedness and type propagation fixes:
7469         * src/SDCCicode.c: made geniCodeCast() static
7470         replaced SPEC_ by IS_ (cosmetic)
7471         (operandOperation): fixed div and mod operation
7472         (usualBinaryConversions): added support for promotion of char
7473         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7474         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7475         (geniCodeAdd): an array index will stay unsigned, even if promoted
7476         from char to int
7477         (geniCodeArray): ditto
7478         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7479         * src/SDCCsymt.c (computeType): added more support for char;
7480         promotion of char is selectable by promoteCharToInt, fixed signedness
7481         for all cases
7482         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7483         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7484         * src/SDCCval (val*): replaced signedness calculation by
7485         computeType()
7486         rearranged if-branches (cosmetic)
7487         (valShift): added warning W_SHIFT_CHANGED
7488         (valCompare): fixed problem with different types
7489         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7490         * support/regression/tests/literalop.c: added many cases
7491         * support/regression/tests/ast_constant_folding.c: changed finally to
7492         'unsigned int'
7493         * .version: new year, new version: 2.3.7
7494         * src/SDCCmain.c (main): applied patch #866468
7495         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7496         provided by Scott Bronson
7497         * doc/sdccman.lyx: updated documentation for sdcdb
7498         updated and added chapter tips
7499
7500 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7501
7502         * src/SDCCsymt.h: missing from yesterday's commits
7503
7504 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7505
7506         * src/SDCC.y (struct_or_union_specifier),
7507         * support/Util/SDCCerr.c,
7508         * support/Util/SDCCerr.h: verify that struct & union tags are used
7509         as declared.
7510
7511 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7512
7513         * src/SDCCglobl.h: missing from yesterday's commits
7514
7515 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7516
7517         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7518         sft_attributes, struct_declaration, parameter_declaration,
7519         type_name, start_block, declaration_list),
7520         * src/SDCC.lex (check_type): support redefinition of typedef names
7521
7522 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7523
7524         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7525         aligned xdata arrays. Erik helped me with the if clause.
7526
7527 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7528
7529         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7530         warning
7531
7532 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7533
7534         * src/SDCCast.h,
7535         * src/SDCCast.c (newAst_),
7536         * src/SDCCicode.h,
7537         * src/SDCCicode.c (ast2iCode, newiCode),
7538         * src/SDCCglobl.h,
7539         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
7540         expr, statement, expression_statement, selection_statement,
7541         iteration_statement, expr_opt, jump_statement): foundation for tracking
7542         sequence points
7543         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
7544         point code too)
7545
7546 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7547
7548         * support/Util/SDCCerr.c,
7549         * src/SDCCast.h,
7550         * src/SDCCast.c (createCase, createDefault, decorateType),
7551         * src/SDCClabel.c (labelUnreach),
7552         * src/SDCC.y (labeled_statement, jump_statement): More improvements
7553         to error messages.
7554         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
7555         (with thanks to Stas Sergeev)
7556         * device/include/time.h,
7557         * device/lib/time.c (CheckTime): suppress unreachable code warning
7558
7559 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7560
7561         * src/SDCCast.c (createIvalCharPtr),
7562         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
7563         bug #753752)
7564         * support/regression/tests/nullstring.c: tests for these two bugs
7565
7566 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7567
7568         * support/Util/SDCCerr.h,
7569         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
7570         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
7571         about storage class and 'at' used inside struct or union
7572         * src/SDCCBBlock.c (iCodeFromeBBlock),
7573         * src/SDCCcse.c (ifxOptimize),
7574         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
7575         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
7576         printIval, emitStaticSeg, emitOverlay),
7577         * src/SDCClabel.c (deleteIfx),
7578         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
7579         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
7580         gatherAutoInit, processParms),
7581         * support/Util/SDCCerr.h,
7582         * support/Util/SDCCerr.c (werrorfl): Support for better error location
7583         reporting for post-parse errors.
7584
7585 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7586
7587         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
7588         implicit casts via union; they don't work on big endian systems
7589         (possible fix for bug #861138)
7590
7591 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7592
7593         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
7594         * src/mcs51/main.c: fixed the fix for bug #737001
7595
7596 2003-12-15  Borut Razem <borut.razem AT siol.net>
7597
7598         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
7599
7600 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7601
7602         * support/makebin/makebin.c: put output in binary mode
7603
7604 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7605
7606         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
7607         xdata and data memory on startup. Set the environment variable
7608         SDCC_NOGENRAMCLEAR to disable this.
7609         * src/mcs51/peephole.def,
7610         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
7611         (allows non-interrupt and interrupt code to safely compete for a resource
7612         without the non-interrupt code having to disable interrupts)
7613
7614 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7615
7616         * src/SDCCicode.c (geniCodeAdd),
7617         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
7618         with valFromType if type might be a pointer and host is big endian).
7619         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
7620         types, not just integer types.
7621         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
7622         multiply defined with mismatching "at" address.
7623
7624 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7625
7626         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
7627         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
7628         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
7629         with embedded nulls (fixed bug #753752)
7630
7631 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7632
7633         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
7634         Apparently this did not see much testing (endless loop)
7635
7636 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7637
7638         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
7639
7640 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7641
7642         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
7643         gracefully handle NULL memmap pointers
7644
7645 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7646
7647         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
7648         instead of deleting the iCode when an operand is volatile
7649         * src/z80/gen.c (genDummyRead),
7650         * src/mcs51/gen.c (genDummyRead),
7651         * src/ds390/gen.c (genDummyRead),
7652         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
7653         not just IC_RIGHT
7654         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
7655         * src/SDCC.y: fixed bug #850420
7656
7657 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7658
7659         Applied z80 i/o port patch from Peter Townson and fixed some operators
7660         to better handle operands in A register.
7661         * device/include/z180.h
7662         * src/SDCC.y
7663         * src/SDCCglue.c
7664         * src/z80/gen.c
7665         * src/z80/gen.h
7666         * src/z80/main.c
7667         * src/z80/peeph-z80.def
7668         * src/z80/peeph.def
7669         * src/z80/z80.h
7670
7671 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7672
7673         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
7674
7675 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7676
7677         * device/lib/hc08/_mullong.c: Removed extra #endif
7678
7679 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7680
7681         * sim/ucsim/hc08.src/inst.cc,
7682         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
7683         carries from x to h
7684         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
7685         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
7686         * device/include/stdarg.h: fixed varargs for hc08
7687         * device/lib/Makefile.in,
7688         * device/lib/hc08/Makefile,
7689         * device/lib/hc08/_mulint.c,
7690         * device/lib/hc08/_mullong.c: fixed some endian problems
7691
7692 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7693
7694         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
7695         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
7696         * device/lib/_gptrget.c,
7697         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
7698
7699 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7700
7701         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
7702         * src/SDCCast.c (astErrors): fixed bug #846007
7703         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
7704
7705 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7706
7707         * src/SDCCast.c (decorateType): disabled a transformation I added in
7708         revision 1.188 (access to fields of a structure at an absolute address);
7709         it breaks with bitfields, extern declarations, and gcse analysis.
7710         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
7711         could be assigned through a pointer, so don't complain.
7712         * src/SDCCast.c (astErrors),
7713         * src/SDCCast.h,
7714         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
7715
7716 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
7717
7718         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
7719         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
7720         output of __config directives, since gpasm now supports them
7721         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
7722         pre-processor macro, i.e. -DMCU=p18f452
7723         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
7724         and modified to handle 'cast' icode similarly to '=' icode
7725         * src/pic16/device.h (typedef struct PIC_device): added field
7726         'extMIface' to indicate that chip has external memory interface
7727         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
7728         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
7729         18F8720
7730
7731 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7732
7733         * src/SDCC.y (pointer): fixed bug #846006
7734         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
7735         * src/SDCCast.c (decorateType): fixed bug #846009
7736         * src/ds390/peeph.def,
7737         * src/ds390/gen.c (genAnd, genOr),
7738         * src/mcs51/peeph.def,
7739         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
7740
7741 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7742
7743         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
7744         * src/SDCCdflow.c
7745         * src/SDCCcse.c
7746         * src/SDCCcse.h
7747         * src/SDCCBBlock.h
7748         * src/SDCCBBlock.c
7749
7750 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
7751
7752         fixed bug #845089
7753         * src/SDCCbitv.h,
7754         * src/SDCCbitv.c: added function to free a bitvector
7755         * src/SDCClrange.h,
7756         * src/SDCClrange.c: added function to recompute the liveranges
7757         * src/avr/ralloc.c,
7758         * src/ds390/ralloc.c,
7759         * src/hc08/ralloc.c,
7760         * src/mcs51/ralloc.c,
7761         * src/pic/ralloc.c,
7762         * src/pic16/ralloc.c,
7763         * src/xa51/ralloc.c,
7764         * src/z80/ralloc.c: recompute the liveranges after register packing
7765
7766 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
7767
7768         * src/SDCCloop.c (newInduction): fixed bug #845630
7769
7770 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7771
7772         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
7773         inadvertantly left behind from my 2003-11-12 change
7774
7775 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7776
7777         Updated headers I neglected to commit yesterday.
7778         * src/SDCClrange.h,
7779         * src/SDCCicode.h
7780
7781 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7782
7783         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
7784         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
7785         * src/SDCCopt.c (eBBlockFromiCode),
7786         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
7787         the creation of the key hash table from the sequencing so it can be used
7788         earlier (for some GCSE bug fixes still pending)
7789
7790 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7791
7792         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
7793         * support/regression/tests/addsub.c: testing genPlus shortcut
7794
7795 2003-11-15  Borut Razem <borut.razem AT siol.net>
7796
7797         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
7798
7799 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7800
7801         * src/SDCCcse.c (cseBBlock): fixed bug #527779
7802         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
7803         ordering is immaterial.
7804         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
7805
7806 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7807
7808         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
7809         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
7810         (SIGSEV) of bug #840381
7811         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
7812         unlink new file before rename if new and old filenames are the same)
7813
7814 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7815
7816         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
7817         uninitialized variables) for the mcs51. Set environment variable
7818         SDCC_GENRAMCLEAR to test.
7819         xdata initialization slightly shorter
7820
7821 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7822
7823         * src/SDCCsymt.h,
7824         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
7825         #838241 & 780691 (basicly the same bug)
7826         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
7827         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
7828
7829 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
7830
7831         * src/SDCCmain.c (linkEdit): "fix" #834252
7832
7833 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7834
7835         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
7836         * src/SDCCast.h,
7837         * src/SDCC.y: fixed bug #819403
7838
7839 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7840
7841         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
7842         the reentrant attribute.
7843         * src/hc08/gen.c (genPackBits): added missing stack readjustment
7844         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
7845         simulation
7846         * src/SDCCast.c (decorateType): fixed bug with storage class not being
7847         updated during pointer dereference; f.e. ~(((char *)1)*) was being
7848         erroneously reduced to a literal.
7849         * src/hc08/ralloc.c (packRegisters, rematStr),
7850         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
7851         some cases
7852
7853 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7854
7855         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
7856         * doc/sdccman.lyx: changed from 'article' to 'book'
7857         * doc/Makefile: readded test_suite_spec and cdbfileformat
7858
7859 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
7860
7861         * device/include/stdlib.h: include malloc.h to comply with ANSI
7862         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
7863
7864 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7865
7866         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
7867         * doc/clean.mk: also remove *.out files
7868         * doc/sdccman.lyx: some additions, larger top/bottom margins
7869
7870 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7871
7872         * src/SDCC.y: fixed bug #837365
7873         * support/regression/tests/bitopcse.c
7874         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
7875         a symbol (might be valop instead)
7876         * device/lib/Makefile.in: added errno.c to HC08SOURCES
7877         * device/lib/clean.mk: added hc08 to the cleaning list
7878
7879 2003-11-04  Borut Razem <borut.razem AT siol.net>
7880
7881         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
7882           made 2003-11-04
7883         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
7884           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
7885           malloc is declared in standard stdlib.h
7886
7887 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7888
7889         * device/lib/hc08/Makefile: need to clean .rel not .o files
7890         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
7891
7892 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7893
7894         * src/port.h,
7895         * src/hc08/main.c,
7896         * src/mcs51/main.c,
7897         * src/ds390/main.c,
7898         * src/z80/main.c,
7899         * src/avr/main.c,
7900         * src/pic/main.c,
7901         * src/pic16/main.c,
7902         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
7903         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
7904         tests (which uses the port's oclsExpense function)
7905         * src/SDCC.y,
7906         * src/SDCCast.c,
7907         * src/SDCCicode.c,
7908         * src/hc08/gen.c,
7909         * src/ds390/gen.c,
7910         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
7911
7912 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7913
7914         * src/SDCCcse.c (ifxOptimize),
7915         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
7916         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
7917         deleting the IFX iCode.
7918         * src/hc08/ralloc.c: reduced unneeded slocs
7919         * src/hc08/gen.c: fixed bug in asmopToBoolean
7920
7921 2003-11-04  Borut Razem <borut.razem AT siol.net>
7922
7923         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
7924           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
7925           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
7926           transferred to configure
7927
7928 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
7929
7930         Use headers defined in the C[++] standards:
7931         * sim/ucsim/gui.src/serio.src/fileio.cc
7932         * sim/ucsim/gui.src/serio.src/frontend.cc
7933         * sim/ucsim/gui.src/serio.src/main.cc
7934         * sim/ucsim/gui.src/serio.src/posix_signal.cc
7935         * support/Util/NewAlloc.c
7936         * as/hc08/lklibr.c
7937         * as/mcs51/lklibr.c
7938         * as/z80/aslist.c
7939         * as/z80/assym.c
7940
7941 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7942
7943         * Added MSVC projects for hc08 assembler and linker:
7944         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
7945         /as/hc08/link_hc08.dsp
7946
7947 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
7948
7949         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
7950
7951 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
7952
7953         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
7954
7955 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7956
7957         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
7958
7959 2003-10-31  Borut Razem <borut.razem AT siol.net>
7960
7961         * support/cpp2/cpplib.h,
7962           support/cpp2/cpplib.c,
7963           support/cpp2/cpplex.c,
7964           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
7965           to switch _asm block preprocessing on / off. Default is
7966           #pragma preproc_asm +
7967
7968 2003-10-31  Borut Razem <borut.razem AT siol.net>
7969
7970         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
7971           when outputting comment blocks (when executed with -C option) and
7972           _asm (SDCPP specific) blocks
7973
7974 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7975
7976         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
7977
7978 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
7979
7980         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
7981
7982 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
7983
7984         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
7985         * src/SDCCast.c (decorateType): fixed bug #832664
7986
7987 2003-10-31  Borut Razem <borut.razem AT siol.net>
7988
7989         * support\cpp2\cpplex.c: fixed for SDCPP:
7990           comments(when executed with -C option) and _asm blocks
7991           were included even if they where in skipped #if block.
7992           Applied solution from GCC cpp 3.3.2
7993
7994 2003-10-31  Borut Razem <borut.razem AT siol.net>
7995
7996         * src/SDCC.lex: sdcc now understands both formats:
7997           '# <line_number> <file_name>' and
7998           '#line <line_number> <file_name>'
7999         * support/cpp2/cppmain.c: sdcpp now generates the standard
8000           '# <line_number> <file_name>' instead of former
8001           '#line <line_number> <file_name>'
8002
8003 2003-10-30  Borut Razem <borut.razem AT siol.net>
8004
8005         * support/cpp2/cpphash.h,
8006         * support/cpp2/cpplib.h
8007         * support/cpp2/cpplex.c,
8008         * support/cpp2/cppmain.c,
8009         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8010
8011 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8012
8013         Fixed a number of problems revealed by bug #827883.
8014         * src/SDCCloop.c (loopInvariants): Spill location of the
8015         result operand should be recomputed if extracted from
8016         a loop. Also, don't extract assignments of an iTemp
8017         from a literal.
8018         * src/SDCCast.c (isConformingBody): loop reversal should
8019         not occur if the control variable is involved with a
8020         relational operator.
8021
8022 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8023
8024         * .version: bumped to 2.3.6 to reflect the big improvements
8025         made by Erik and Klaus. Thanks!
8026
8027 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8028
8029         Replaced the livrange code.
8030         * src/SDCClrange.c: added new LR code
8031         * src/SDCCloop.c,
8032         * src/SDCCBBlock.h: removed remainig parts from old LR code
8033         * src/ds390/ralloc.c,
8034         * src/ds390/gen.c: minor fixes to make it work with new code
8035
8036 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8037
8038         * as/hc08/asm.h,
8039         * as/hc08/lkrloc.c,
8040         * src/hc08/gen.c,
8041         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8042         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8043         (tweaked fix for bug #818696)
8044
8045 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8046
8047         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8048
8049 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8050
8051         * src/SDCCmain.c,
8052         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8053         * src/mcs51/gen.c (gencjneshort),
8054         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8055         more efficient (per Scott Bronson's suggestion)
8056
8057 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8058
8059         Extended the semantics of the critical keyword to include
8060         individual statements. See RFE #827755 and #799831
8061         * src/SDCC.y
8062         * src/SDCCicode.c
8063         * src/SDCCopt.c
8064         * src/SDCCast.c
8065         * support/Util/SDCCerr.c
8066         * support/Util/SDCCerr.h
8067         * src/mcs51/gen.c
8068         * src/ds390/gen.c
8069         * src/hc08/gen.c
8070
8071 2003-10-19  Borut Razem <borut.razem AT siol.net>
8072
8073         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8074
8075 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8076
8077         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8078         Fixed bug #818696
8079         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8080         and predecrement operand is displayed
8081
8082 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8083
8084         * src/SDCCval.c (valMinus): fixed bug #826041
8085
8086 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8087
8088         Some hc08 related updates that I missed earlier
8089         * sim/ucsim/stypes.h
8090         * support/regression/ports/hc08/spec.mk
8091
8092 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8093
8094         New target "hc08" for the Motorola 68hc08 family of micros
8095
8096         * configure
8097         * configure.in
8098         * Makefile
8099         * src/hc08/*
8100         * src/SDCCmain.c
8101         * src/port.h
8102         * sim/ucsim/hc08.src/*
8103         * sim/ucsim/configure.in
8104         * src/ucsim/configure
8105         * sim/ucsim/packages_in.mk
8106         * as/hc08/*
8107         * as/Makefile
8108         * device/include/mc68hc908qy.h
8109         * device/lib/hc08/*
8110         * device/lib/Makefile.in
8111         * support/regression/ports/hc08/*
8112         * support/regression/Makefile
8113
8114 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8115
8116         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8117         regression test
8118         * src/ds390/gen.c (genCast): fixed bug #821957
8119
8120 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8121
8122         * device/lib/logf.c: "fixed" overlay bug
8123         * support/regression/ports/host/spec.mk: added m library
8124         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8125         * support/regression/tests/float_trans: added (for Eric)
8126
8127 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8128
8129         * src/mcs51/gen.c (genCpl): fixed bug
8130         http://sf.net/mailarchive/message.php?msg_id=6263915
8131
8132 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8133
8134         * src/SDCCast.c (decorateType): added extended constant folding
8135         * src/SDCCsymt.c (computeType): cleanup
8136         * src/SDCCval.c (valShift): minor optimization
8137         * support/regression/tests/ast_constant_folding.c: added
8138
8139 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8140
8141         * src/SDCCmain.c: removed some unintended changes
8142
8143 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8144
8145         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8146         * src/z80/gen.c: fixed part of bug #817589
8147         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8148
8149 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8150
8151         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8152         * src/SDCCcflow.c
8153         * src/SDCCcse.c
8154         * src/SDCCdflow.c
8155         * src/SDCClabel.c
8156         * src/SDCClrange.c
8157         * src/SDCCmem.c
8158         * src/SDCCopt.c
8159         * src/SDCCpeeph.c
8160         * src/SDCCset.c
8161         * src/avr/ralloc.c
8162         * src/ds390/ralloc.c
8163         * src/izt/ralloc.c
8164         * src/mcs51/ralloc.c
8165         * src/pic/ralloc.c
8166         * src/pic16/ralloc.c
8167         * src/xa51/ralloc.c
8168         * src/z80/ralloc.c
8169         * src/z80/gen.c: removed unused label "release:"
8170
8171 2003-10-06  Borut Razem <borut.razem AT siol.net>
8172
8173         * src/SDCC.lex: removed definition of unused variables
8174           save_optimize and save_options
8175
8176 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8177
8178         * clean.mk: removed '=' in "-maxdepth=1"
8179         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8180         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8181
8182 2003-10-06  Borut Razem <borut.razem AT siol.net>
8183
8184         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8185           my_unput() replaced by unput()
8186
8187 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8188
8189         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8190         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8191         type-punned pointer will break strict-aliasing rules"
8192         Old LR behaviour is again default; Klaus' LR can be choosen by
8193         defining the environment variable LRKLAUS
8194         * src/SDCCBBlock.h
8195         * src/SDCCloop.c
8196         * src/SDCClrange.c
8197         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8198         * clean.mk: fixed removal of files in bin/CVS/
8199         * device/lib/clean.mk: fixed removal of directories small and large
8200         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8201         * src/SDCCicode.c,
8202         * src/SDCCval.c: removed superflous test for pedantic
8203
8204 2003-10-05  Borut Razem <borut.razem AT siol.net>
8205
8206         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8207           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8208           message "unmatched #pragma SAVE and #pragma RESTORE"
8209
8210 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8211
8212         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8213           assembly, critical functions, atomic, nojtbound)
8214
8215 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8216
8217         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8218         * src/SDCCBBlock.h
8219         * src/SDCCloop.c
8220         * src/SDCCloop.h
8221         * src/SDCClrange.c
8222
8223 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8224
8225         * src/z80/gen.h,
8226         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8227         * src/mcs51/gen.h
8228         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8229         * src/ds390/gen.h
8230         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8231         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8232         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8233
8234 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8235
8236         * src/z80/gen.c (genRet): fixed bug #524753
8237         * src/z80/gen.c (genCast): fixed internal error on cast from
8238         pointer to long
8239         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8240         fix for bug #477835 to the z80
8241         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8242         for tracking iCodes in the peephole optimizer for z80
8243
8244 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8245
8246         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8247         the other part of bug #814548
8248         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8249
8250 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8251
8252         * src/SDCCcse.c: fixed part of bug #814548
8253
8254 2003-09-28  Borut Razem <borut.razem AT siol.net>
8255
8256         * src/asm.c: rewrite of printILine() to use temporary file instead
8257           a pipe
8258         * src/xa51/main.c: commented out declaration of int rewinds
8259
8260 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8261
8262         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8263
8264 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8265
8266         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8267         * src/asm.c (printILine): Fixed bug #811015
8268
8269 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8270
8271         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8272         freeing.
8273
8274 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8275
8276         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8277         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8278         to correctly handle general case of AOP_PAIRPTR
8279         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8280
8281 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8282
8283         * src/mcs51/ralloc.c (fillGaps),
8284         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8285         register positioning bug)
8286
8287 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8288
8289         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8290
8291 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8292
8293         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8294         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8295         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8296         (ralloc doesn't intentionally do this now, but perhaps later)
8297         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8298         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8299         register positioning bugs (Fixed bug #762602 and #795325)
8300         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8301         (Fixed bug #808779)
8302         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8303         lines that --i-code-in-asm generates
8304
8305 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8306
8307         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8308         trying to fclose a FILE* that was already closed.
8309
8310 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8311
8312         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8313         of const struct should be treated as if const themselves)
8314
8315 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8316
8317         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8318
8319 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8320
8321         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8322         Unix (/n) and DOS (/r/n) line terminations.
8323
8324 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8325
8326         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8327         bug #613775
8328
8329 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8330
8331         * src/mcs51/gen.c (genFunction, genEndFunction),
8332         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8333         and restore of EA so that stack offsets to parameters are
8334         correct when using both critical and reentrant/stack-auto.
8335         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8336         size (can be triggered in error if sloc is shared between
8337         different sized objects)
8338         * device/include/float.h: fixed macros to explicitly use
8339         unsigned long where needed
8340
8341 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8342
8343         Feature req. 799831: added code to allow nesting of critical functions
8344         * src/mcs51/gen.c (genFunction, genEndFunction)
8345         * src/ds390/gen.c (genFunction, genEndFunction)
8346
8347 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8348
8349         * src/SDCCsymt.c (sclsFromPtr),
8350         * src/SDCCsymt.h,
8351         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8352         support for standard C idiom of memory mapped variables; for
8353         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8354         to xdata int at 0x1234 tempvar = 1.
8355         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8356         provided by Akiya ISHIDA
8357
8358 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8359
8360         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8361         * src/SDCCval.c (constVal): added reduction from int to char
8362         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8363         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8364         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8365         to ignore the sign
8366         * support/regression/tests/shifts.c: fixed
8367
8368 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8369
8370         * src/z80/gen.c (genXor): Fixed bug #805445
8371
8372 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8373
8374         Fixed bug #621531 (const & volatile confusion in the type chain).
8375         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8376         refer to the const or volatile state of the pointer itself.
8377
8378         * src/SDCCast.c
8379         * src/SDCCglue.c
8380         * src/SDCCicode.c
8381         * src/SDCCsymt.c
8382         * src/SDCCval.c
8383         * src/SDCC.y
8384         * src/SDCCsymt.h
8385         * src/pic/gen.c
8386         * src/pic/ralloc.c
8387         * src/pic16/gen.c
8388         * src/pic16/ralloc.c
8389         * support/regression/tests/const.c
8390
8391 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8392
8393         When checking for duplicated modules, use absolute paths
8394         instead of relative paths.  Files changed:
8395
8396         * as/mcs51/lklib.c
8397         * link/z80/lklib.c
8398
8399 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8400
8401         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8402
8403 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8404
8405         * device/include/string.h: added size_t typedef, changed
8406         prototypes to use size_t, eliminated separate reentrant and
8407         non-reentrant declarations, added _memmove declaration
8408         * device/lib/_memcpy.c: changed to use size_t instead of int,
8409         changed /4 to >>2 to avoid division library call
8410         * device/lib/_memcmp.c,
8411         * device/lib/_memset.c,
8412         * device/lib/_strncat.c,
8413         * device/lib/_strncpy.c,
8414         * device/lib/_strncmp.c: changed to use size_t instead of int
8415         * device/lib/_memmove.c: new file (fixed bug #772294)
8416         * device/lib/Makefile.in: added _memmove.c
8417         * device/lib/z80/asm_strings.s: fixed bug #772290
8418         * support/regression/tests/bitfields.c: attempt to fix host assertion
8419         failure on amd64-unknown-linux2.2
8420
8421 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8422
8423         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8424         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8425         * as/z80/asmain.c (main): fixed bug #801766
8426
8427 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8428
8429         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8430         compilers
8431
8432 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8433
8434         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8435         reported in bug #800609
8436
8437 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8438
8439         * Top header beautifications in src/pic16 directory:
8440           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8441           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8442           pcoderegs.h, ralloc.c, ralloc.h
8443         * main.c: added top header and GPL license notice
8444         * pcode.c: fixed the if-conditional warning
8445
8446 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8447
8448         * device/lib/_mullong.c: replaced int by short for gcc
8449
8450 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8451
8452         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8453         and JUMPTABLE iCodes properly now (worked by accident before)
8454         * src/mcs51/gen.c (leftRightUseAcc),
8455         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8456         iCode properly now. Use getSize instead of nRegs since a & b
8457         aren't part of the nRegs tally.
8458
8459 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8460
8461         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8462         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8463           before instructions that use the _STATUS register
8464
8465 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8466
8467         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8468         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8469         fetching of the pointer
8470         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8471         copied from genNearPointerSet()
8472         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8473         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8474         If they pop r0/r1 they must be called in the opposite order than aopOp().
8475         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8476         (resp. --stack-auto), prepared for --xstack
8477
8478 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8479
8480         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8481
8482 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8483
8484         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8485         these ports have their own __sdcc_external_start()
8486
8487 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8488
8489         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8490         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8491         type for bits was changed. It resulted in bit variables becoming
8492         global, which is not permitted in PIC 14 assembly output.
8493
8494 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8495
8496         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8497
8498 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8499
8500         Z80 and MCS51 linkers complaint if a public symbol is defined
8501         in more than one library module:
8502
8503         * as/mcs51/lklib.c
8504         * link/z80/lklib.c
8505         * as/mcs51/Makefile.in
8506
8507 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8508
8509         A few small changes that speed up the peephole optimizer.
8510
8511         * src/SDCCpeeph.c
8512
8513 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8514
8515         Try to make the peephole optimizer smarter by maintaining
8516         an association between the assembly source code and the
8517         iCodes that originated them. Put this information to use
8518         with a new peephole rule condition "notVolatile" so that
8519         the rules can be aggressive yet still safe.
8520
8521         * src/SDCCpeeph.c
8522         * src/SDCCpeeph.h
8523         * src/mcs51/gen.c
8524         * src/mcs51/peeph.def
8525
8526 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8527
8528         Fixed bug #741761
8529
8530         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8531         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8532         if the left or right operand symbols have the accuse flag set.
8533
8534 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8535
8536         Changed the type of the result of the ! (NOT) operator to char;
8537         previously it returned the same type as the source. This allows
8538         us to eliminate all the genFloatNot functions (all of its target
8539         implementations were very buggy) since !float can use the same
8540         code as !long now.
8541
8542         * src/SDCCicode.c (ast2iCode): ! returns char
8543         * src/mcs51/gen.c (genNot, genNotFloat),
8544         * src/ds390/gen.c (genNot, genNotFloat),
8545         * src/z80/gen.c (genNot, genNotFloat),
8546         * src/pic/gen.c (genNot, genNotFloat),
8547         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
8548
8549 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
8550
8551         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8552         1. Interrupt would not compile properly. Ensure PCLATH register is saved
8553            during interrupts. Ensure WSAVE is located at a shared bank address.
8554         2. Fixed page selection in some places
8555         3. Fixed BTFSS/C to where necessary use registers directly and not simply
8556            the registers name strings.
8557         4. Fixed "signed / unsigned compare" compiler warnings.
8558         5. The PIC port manages its own allocation of the general purpose
8559            registers, but makes no attempt to reuse them. As a result when
8560            compiling it soon runs out of general purpose registers. Some
8561            additional code was added to the files pcode.c and device.c to walk
8562            through the function call tree and rename the registers so that they
8563            get reused.
8564
8565         * src/pic/device.c
8566         * src/pic/gen.c
8567         * src/pic/glue.c
8568         * src/pic/pcode.c
8569         * src/pic/pcode.h
8570         * src/pic/ralloc.c
8571         * src/pic/ralloc.h
8572         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
8573         genPlus() & genMinus() when the result is the same as left or right
8574
8575 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8576
8577         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
8578
8579 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8580
8581         Made bitfield a distinct type from bit so that bitfields
8582         convert as per ANSI C and bits retain their traditional
8583         boolean style behaviour. Implemented bitfield support in
8584         the z80 port.
8585
8586         * src/SDCCsymt.h,
8587         * src/SDCCsymt.c,
8588         * src/SDCCast.c,
8589         * src/cdbFile.c,
8590         * src/mcs51/gen.c,
8591         * src/ds390/gen.c: bit v bitfield split
8592         * src/z80/gen.c: New support for bitfields
8593         * support/regression/tests/bitfields.c: reenabled z80,
8594         added more tests
8595
8596 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8597
8598         Rules 246.x, 247.x relate to bitfields, the others speed up
8599         access to xdata mapped I/O devices.
8600
8601         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
8602
8603 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8604
8605         Cleaned up genPackBits and genUnpackBits and added two helper
8606         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
8607         for literal assignments in genPackBits (thanks to Frieder for
8608         reminding me).
8609
8610         * src/mcs51/gen.c
8611         * src/ds390/gen.c
8612
8613 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8614
8615         Fixed bug #748310 (pointer to function type mishandled when the
8616         function name is omitted). Also fixed a SIGSEGV when a function
8617         attribute (reentrant, etc) is used on a non-function or on a
8618         function but misplaced before the parameter list.
8619
8620         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
8621         bug #748310
8622         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
8623         * support/Util/SDCCerr.h,
8624         * support/Util/SDCCerr.c: Added func attr misuse error msg
8625
8626 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8627
8628         Fixed bug #787649 by anonymous
8629         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
8630         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
8631
8632 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8633
8634         Fixed numerous bitfield problems.
8635
8636         * src/SDCC.y: More bitfield related error checking
8637         * src/SDCCsymt.h,
8638         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
8639         * support/Util/SDCCerr.h,
8640         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
8641         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8642         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8643         * support/regression/tests/bitfields.c: tests added
8644
8645 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8646
8647         Made the constant following the "interrupt" keyword optional. If
8648         omitted, the function will not automatically be given an entry
8649         in the interrupt vector table (similar to #pragma NOIV, but
8650         less syntacticly kludgy). The interrupt number is also now
8651         range checked. Also fixed a bug in the high order bit example
8652         in the manual.
8653
8654         * src/SDCC.y
8655         * src/SDCCmem.c
8656         * src/SDCCglue.c
8657         * src/SDCCsymt.h
8658         * support/Util/SDCCerr.c
8659         * support/Util/SDCCerr.h
8660         * doc/sdccman.lyx
8661
8662 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8663
8664         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
8665         * src/SDCCicode.c (operandOperation): rewritten some ops
8666         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
8667         * src/SDCCsymt.c (computeType): literals are handled the same way as any
8668         other type
8669         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
8670         be re-activated by defining REDUCE_LITERALS)
8671         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
8672         unsigned, but are signed by default
8673         * src/SDCCval.c (constVal): rearranged
8674         * src/SDCCval.c (valMod): preliminary fix
8675         * src/SDCCval.c (valCastLiteral): use TYPE_* types
8676         * support/regression/literalop.c: added, work in progress
8677
8678 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8679
8680         Generate warnings for useless declarations like "char data;"
8681         that don't do what new users expect.
8682
8683         * src/SDCC.y
8684         * support/Util/SDCCerr.h
8685         * support/Util/SDCCerr.c
8686
8687 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
8688
8689         * src/SDCCval.c (valMult): fix overflow detection of negative int
8690
8691 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8692
8693         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
8694
8695         Changes to support big endian targets:
8696
8697         * src/ports.h
8698         * src/SDCCglue.c
8699         * src/avr/main.c
8700         * src/ds390/main.c
8701         * src/izt/i186.c
8702         * src/mcs51/main.c
8703         * src/pic/main.c
8704         * src/pic16/main.c
8705         * src/xa51/main.c
8706         * src/z80/main.c
8707
8708 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
8709
8710         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
8711         * device/lib/time.c: fixed warning "integer overflow in expression"
8712
8713 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
8714
8715         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
8716         * src/SDCCval.c (constVal): changed default to signed; hex and octal
8717         constants are unsigned; added recognition of "u" flag for unsigned
8718         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
8719         * src/SDCCval.c (valDiv, valMod): fixed signdness
8720         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
8721         signedness of modulo, left and right shift
8722         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
8723         * support/Util/SDCCerr.h: added warning W_INT_OVL
8724         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
8725         * src/SDCCast.c (ast_print): improved output of constants
8726
8727 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8728
8729         Fixed some warnings when building with MSVC:
8730
8731         * as\mcs51\asdata.c
8732         * as\z80\asdata.c
8733         * as\mcs51\asm.h
8734         * as\z80\asm.h
8735         * link\z80\aslink.h
8736         * link\z80\lkdata.c
8737         * link\z80\lkeval.c
8738         * link\z80\lkgb.c
8739         * link\z80\lkihx.c
8740         * link\z80\lks19.c
8741         * link\z80\lksym.c
8742         * support\cpp2\cpplib.c
8743         * src\ds390\gen.c
8744         * src\mcs51\gen.c
8745
8746 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
8747
8748         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
8749
8750 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8751
8752         * support\librarian\clean.mk: Do not remove Makefile.
8753         * support\librarian\Makefile: added.
8754
8755 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8756
8757         Added librarian to MSVC build:
8758         * all.dsp
8759         * sdcc.dsw
8760         * support\librarian\librarian.dsp
8761
8762         'configure' not needed for librarian, removed:
8763         * support\librarian\configure
8764         * support\librarian\configure.in
8765         * support\librarian\config_in.h
8766         * support\librarian\Makefile.in
8767
8768         Hopefully these ones built the librarian and the rest of sdcc properly:
8769         * Makefile
8770         * Makefile.common.in
8771
8772         Messed up 'configure', so revert to previous version:
8773         * configure
8774         * configure.in
8775
8776 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
8777
8778         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
8779         there, while the mantissa of a double is "only" 53 bits wide.
8780
8781 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8782
8783         Adding sdcclib to the build.  MSVC project coming soon.
8784         Files added/changed:
8785
8786         * support\librarian\clean.mk
8787         * support\librarian\configure
8788         * support\librarian\configure.in
8789         * support\librarian\config_in.h
8790         * support\librarian\Makefile.bcc
8791         * support\librarian\Makefile.in
8792         * support\librarian\sdcclib.c
8793         * Makefile.bcc
8794         * Makefile
8795         * Makefile.common.in
8796         * configure
8797         * configure.in
8798
8799 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8800
8801         Linker now complaints if linked modules have conflicting options, for
8802         example, one compiled using --model-large and another one compiled with
8803         --model-small.  The following files were modified:
8804
8805         * as\mcs51\asdata.c
8806         * as\mcs51\aslink.h
8807         * as\mcs51\asm.h
8808         * as\mcs51\asmain.c
8809         * as\mcs51\asout.c
8810         * as\mcs51\i51pst.c
8811         * as\mcs51\lkdata.c
8812         * as\mcs51\lklibr.c
8813         * as\mcs51\lkmain.c
8814         * as\z80\asdata.c
8815         * as\z80\asm.h
8816         * as\z80\asmain.c
8817         * as\z80\asout.c
8818         * as\z80\z80pst.c
8819         * link\z80\aslink.h
8820         * link\z80\lkdata.c
8821         * link\z80\lklibr.c
8822         * link\z80\lkmain.c
8823         * src\SDCCglue.c
8824
8825 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8826
8827         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
8828         as/mcs51/lklibr.c: Generate a warning when a library is not found.
8829
8830 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
8831
8832         * src/z80/mappings.i: fix _mul[us][int,long] entries
8833
8834 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8835
8836         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
8837
8838 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
8839
8840         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
8841         * support/regression/tests/bitopcse.c: added
8842         fixed warning:
8843         * src/avr/gen.c:
8844         * src/pic/gen.c:
8845         * src/pic16/gen.c:
8846         * src/z80/gen.c:
8847         * src/xa51/gen.c:
8848
8849 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8850
8851         added support for new library format to z80, gbz80 linkers:
8852         *link/z80/aslink.h
8853         *link/z80/lklex.c
8854         *link/z80/lklib.c
8855         *link/z80/lklist.c
8856
8857 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
8858
8859         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
8860         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
8861
8862 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
8863
8864         added DUMMY_READ_VOLATILE:
8865         * src/SDCC.y:
8866         * src/avr/gen.c:
8867         * src/xa51/gen.c:
8868         * src/z80/gen.c:
8869         * src/pic/gen.c:
8870         * src/pic16/gen.c:
8871         * src/mcs51/gen.c:
8872         * src/ds390/gen.c:
8873         * src/SDCCcse.c (algebraicOpts): many improvements
8874         * src/SDCCcse.h: removed algebraicOpts()
8875         * src/SDCCicode.c (picDummyRead): added
8876
8877 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8878
8879         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
8880         "Insufficient space in data memory".
8881
8882 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8883
8884         * src/mcs51/gen.c: fixed bug #771358
8885         * src/z80/gen.c: fixed bug #759087
8886
8887 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
8888
8889         * src/pic16/glue.c: minor cleanup by Vangelis
8890
8891 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8892
8893         * device/include/regc515c.h: fixed #758477
8894         * device/lib/_gptrget.c: saving some cycles in generic pointer get
8895         * device/lib/_gptrput.c: saved a few bytes
8896         * my tab spacing is 8, yours too?)
8897         * device/lib/_ser.c: process RX bytes earlier than TX bytes
8898         * device/lib/serial.c: process RX bytes earlier than TX bytes
8899         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
8900
8901 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8902
8903         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
8904
8905 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8906
8907     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
8908
8909 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
8910
8911         * device/lib/Makefile.in: bad fix, reverted to 1.43
8912
8913 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
8914
8915         * device/lib/Makefile.in: added missing z80 object files
8916
8917 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
8918
8919         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
8920         pic16 progress by Vangelis:
8921         * src/SDCCglobl.h:
8922         * src/SDCCmain.c:
8923         * src/pic/Makefile:
8924         * src/pic:
8925         * pic/Makefile:
8926         * pic16/device.c:
8927         * pic16/device.h:
8928         * pic16/gen.c:
8929         * pic16/gen.h:
8930         * pic16/genarith.c:
8931         * pic16/glue.c:
8932         * pic16/main.c:
8933         * pic16/pcode.c:
8934         * pic16/pcode.h:
8935         * pic16/pcodepeep.c:
8936         * pic16/peeph.def:
8937
8938 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8939
8940     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
8941
8942 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8943
8944     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
8945     added gbz80 build to MSVC project.
8946     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
8947     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
8948     from 8051 stuff and setup so it links using a .lnk file.
8949
8950 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8951
8952     * support/librarian/sdcclib.c: sdcc librarian.
8953     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
8954     with sdcclib.
8955
8956 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8957
8958     * as/mcs51/lkmain.c: properly handle extensions in function afile.
8959
8960 2003-07-02  Borut Razem <borut.razem AT siol.net>
8961
8962         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
8963         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
8964         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
8965         src/xa51/main.c, src/z80/main.c:
8966         virtualization of glue() function: each port has it's own glue function,
8967         which is accessed by do_glue function pointer in PORT.general structure
8968
8969 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
8970
8971         * DS800C400 fun, improved ROM interface and tinibios.
8972
8973 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
8974
8975         * More support for DS80C400. Now includes beginning of interface to ROM.
8976
8977 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
8978
8979         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
8980
8981 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8982
8983         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
8984
8985 2003-06-19  Borut Razem <borut.razem AT siol.net>
8986
8987         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
8988
8989 2003-06-19  Borut Razem <borut.razem AT siol.net>
8990
8991         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
8992         fixed Z80 port - crt0.o: cannot open.
8993
8994 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
8995
8996         * support/Util/MySystem.c (merge_command): revert bad fix
8997
8998 2003-06-18  Borut Razem <borut.razem AT siol.net>
8999
9000         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9001
9002 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9003
9004         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9005         option --use-stdout sends errors to stdout instead of stderr.
9006
9007 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9008
9009         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9010
9011 2003-06-15  Borut Razem <borut.razem AT siol.net>
9012
9013         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9014         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9015         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9016         fixed width array of pointers replaced with sets;
9017         multiple include and lib paths ared transferred to preprocessor and linker
9018         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9019         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9020         fixed width array of pointers
9021         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9022         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9023         fixupPath(), getPathDifference()
9024         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9025         fixed width array of pointers
9026
9027 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9028
9029         * src/pic16/ralloc.c: fix warnings
9030         * src/pic16/pcode.c: fix warning
9031
9032 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9033
9034          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9035         know all the details, but essentially this set of changes enable
9036         the pic16 port to generate movff instructions and generate assembler
9037         directives,
9038         * src/SDCCmain.c:
9039         * src/pic16/gen.c:
9040         * src/pic16/glue.c:
9041         * src/pic16/pcode.c:
9042         * src/pic16/device.c:
9043         * src/pic16/main.c:
9044         * src/pic16/pcode.h:
9045         * src/pic16/pcoderegs.c:
9046         * src/pic16/ralloc.c:
9047         * src/pic16/ralloc.h:
9048
9049 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9050
9051         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9052         added option --vc, so sdcc errors and warnings are compatible with
9053         Microsoft Visual Studio.
9054
9055 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9056
9057         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9058           device/lib/libfloat.lib: added atof function.
9059
9060 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9061
9062         * doc/sdccman.lyx: updated to Lyx 1.3
9063         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9064         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9065         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9066
9067 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9068
9069         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9070
9071 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9072
9073         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9074           additions to the "related tools/documentation" section
9075
9076 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9077
9078         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9079
9080 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9081
9082         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9083         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9084
9085 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9086
9087         * doc/sdccman.lyx: fix double dash and other minor things
9088         * doc/Makefile: fix double dash
9089
9090 2003-05-28  Karl Bongers(patches from Martin Helmling)
9091         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9092           condition and ignore commands.
9093
9094 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9095
9096         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9097           is in parts still quite out of date, I did changes as far as I felt makes sense
9098           for a non-native english speaker.
9099           Please feel free to add to the manual or to correct my changes.
9100         * doc/Makefile: undid touching the date of intermediate tex files.
9101
9102 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9103
9104         * doc/sdccman.lyx: Manual has an index now
9105
9106 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9107
9108         Finalize muluint/mulsint and mululong/mulslong merging:
9109         * device/lib/_mulint.c
9110         * device/lib/_mullong.c
9111         * device/lib/gbz80/mul.s
9112         * device/lib/gbz80/stubs.s
9113         * device/lib/z80/mul.s
9114         * device/lib/z80/stubs.s
9115         * src/SDCCsymt.c (initCSupport)
9116
9117 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9118
9119         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9120         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9121           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9122           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9123           instead of /Zm500.
9124
9125 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9126
9127         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9128           the regression tests I'm not brave enough to enable 245.b, 245.c
9129         * doc/sdccman.lyx: added latex preamble for hyperref package.
9130           Using pdflatex this will give you a hyperlinked pdf file with
9131           bookmarks. (prepend '%' before /usepackage if this breaks something)
9132
9133 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9134
9135          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9136
9137 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9138
9139         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9140
9141 2003-05-21    <johan AT balder>
9142
9143         * src/SDCCglue.c (printIval): fixed bug #739934
9144
9145 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9146
9147         Applied patch from bug 737905 (renamed yylineo to mylineno):
9148         * src/altlex.c
9149         * src/SDCCast.c
9150         * src/SDCglobl.h
9151         * src/SDCC.lex
9152         * src/SDCCsymt.c
9153         * src/SDCCval.c
9154         * src/pic16/pcode.c: Cleaned warnings
9155         * src/pic16/pcodeflow.c: Cleaned warnings
9156         * src/pic16/pcoderegs.c: Cleaned warnings
9157
9158 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9159
9160         * src/pic16/pcode.c: Cleaned warnings
9161         * src/pic16/pcodepeep.c: Cleaned warnings
9162         * src/pic16/ralloc.c: Cleaned warnings
9163
9164 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9165
9166         * doc/sdccman.lyx: fixed bug 739745
9167         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9168
9169 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9170
9171         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9172         it can be defined with CFLAGS when running configure
9173         * src/SDCCmain.c: fixed compiling + linking with object files
9174
9175 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9176
9177         * configure.in: configure for pic16 port,
9178             added --disable-pic16-port
9179         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9180         * src/SDCCmain.c: linkOptions is changed to set *,
9181             added if/endif conditional macros to remove options help
9182             messages from optionsTable when a port is not configured, added
9183             support for the PIc16 port in the ports table, when executing
9184             the compiler with no port specified on command line, a default
9185             port is selected with the new macro DEFAULT_PORT which is
9186             defined in port.h, in setDefaultOptions() linkOptions is removed
9187             from initialization assignment, since now it is a set,
9188             parseCmdLine uses setParseWithComma for linkOptions, in
9189             linkEdit() linkOptions are accessed with new function indexSet()
9190             which returns the i'th item of a set variable. See SDCCset.c, in
9191             linkEdit() when calling buildCmdLine(), added linkOptions as
9192             last argument. Now users can pass arguments to gplink via the
9193             -Wl option, main() uses pic16glue() to glue up pic16 programs
9194         * src/SDCCpeeph.c: various changes to support pic16
9195         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9196             return the i'th item of the set
9197         * src/SDCCset.h: added function prototype for indexSet()
9198         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9199         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9200         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9201             added macro DEFAULT_PORT
9202         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9203         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9204             generated
9205         * src/pic16/glue.c: commented out some error producing lines
9206         * src/pic16/main.c: __config directives are commented out to stop
9207             gpasm complaining and test the linkage with gplink, _linkCmd and
9208             _asmCmd changed to be more gplink and gpasm friendly
9209         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9210             produced an error when parsed, peep rule 12 is added to utilize
9211             movff, but it is commented out since the pCode does not support
9212             yet a command with 2 address arguments
9213
9214 2003-05-18    <johan AT balder>
9215
9216         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9217         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9218 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9219
9220         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9221   Added feature to script commands from file.
9222
9223 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9224
9225         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9226         * src/SDCCutil.c: include ctype.h for win32
9227
9228 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9229
9230         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9231
9232 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9233
9234         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9235   Fixed so you can set breakpoints prior to run, run does not stop
9236   on entry now.  Add tbreak.  Other enhancements and fixes for use
9237   with ddd.
9238
9239 2003-05-12  Borut Razem <borut.razem AT siol.net>
9240
9241         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9242
9243 2003-05-11  Borut Razem <borut.razem AT siol.net>
9244
9245         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9246         the path of bin directory, so that PATH is the only env. variable, which has to be set
9247         in case of standard installation.
9248         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9249         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9250         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9251
9252 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9253
9254         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9255         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9256         temp files are in the port dir; clean the gen/test directory when
9257         generating new test.c
9258         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9259         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9260         * support/regression/tests/zeropad.c: added
9261
9262 2003-05-09    <johan AT balder>
9263
9264         * src/SDCCglue.c: fixed bug #597940
9265
9266 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9267
9268         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9269   cache sfr, optimize next,step, fix off by one sourceline,
9270   support ddd list function.
9271         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9272
9273 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9274
9275         * support/regression/HTMLgen.py: added compare_s2f()
9276         * support/regression/Makefile: redo 1.27
9277         * support/regression/generate-cases.py: redo 1.5
9278
9279 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9280
9281         * support/regression/tests/float.c: workaround 33 bit hex constant
9282         * support/regression/tests/simplefloat.c: fix division for host
9283
9284 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9285
9286         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9287         that tame's the PIC's over-aggressive optimizer.
9288
9289 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9290
9291          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9292          support for MSVC.
9293
9294 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9295
9296         Initial support for DS80C400. "Hello world" runs on TINIm400
9297         (with polled I/O).
9298
9299 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9300
9301          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9302          * Some notes on ddd usage added in debugger/README
9303          Martin Helmling adding more features and fixes for ddd GUI debugger.
9304          Code added for nexti, stepi, up, down, and other adjustments.
9305
9306 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9307
9308         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9309         * src/pic/peeph.def Added two rules to optimize carry manipulation
9310         * src/pic/* removed debug printfs
9311
9312 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9313
9314         * debugger/mcs51/cmd.c: added header newalloc.h
9315
9316 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9317
9318         * as/Makefile: new EXEEXT
9319         * as/z80/Makefile: remove trailing slash of BUILDIR
9320         * as/z80/clean.mk: new EXEEXT
9321         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9322         * support/cpp2/Makefile.in: new EXEEXT
9323         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9324
9325 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9326
9327         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9328         EXEEXT was introduced to fix all related problems with targets
9329         "clean", "install" and "uninstall"; a couple of further flaws
9330         especially with "clean" have been fixed too
9331         * as/mcs51/Makefile.in
9332         * as/mcs51/clean.mk
9333         * as/z80/Makefile
9334         * Makefile
9335         * clean.mk
9336         * debugger/mcs51/Makefile.in
9337         * debugger/mcs51/clean.mk
9338         * link/z80/Makefile
9339         * link/z80/Makefile.in
9340         * link/z80/clean.mk
9341         * link/Makefile
9342         * packihx/Makefile.in
9343         * packihx/clean.mk
9344         * sim/ucsim/Makefile
9345         * sim/ucsim/clean.mk
9346         * sim/ucsim/avr.src/Makefile.in
9347         * sim/ucsim/avr.src/clean.mk
9348         * sim/ucsim/s51.src/Makefile.in
9349         * sim/ucsim/s51.src/clean.mk
9350         * sim/ucsim/xa.src/Makefile.in
9351         * sim/ucsim/xa.src/clean.mk
9352         * sim/ucsim/z80.src/Makefile.in
9353         * sim/ucsim/z80.src/clean.mk
9354         * sim/ucsim/main_in.mk
9355         * sim/ucsim/packages_in.mk
9356         * sim/ucsim/gui.src/Makefile.in
9357         * sim/ucsim/gui.src/serio.src/Makefile.in
9358         * sim/ucsim/gui.src/serio.src/clean.mk
9359         * src/Makefile.in
9360         * src/clean.mk
9361         * support/cpp2/Makefile.in
9362         * support/cpp2/clean.mk
9363         * support/makebin/Makefile
9364         * support/makebin/clean.mk
9365         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9366         * doc/sdccman.lyx: --program-suffix no longer needed
9367
9368 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9369
9370          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9371          Martin Helmling added support for ddd GUI debugger.
9372          Code added to display assembly, set variables, and other commands
9373          to interface to ddd.
9374
9375 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9376
9377         * as/Makefile: fix target clean
9378         * as/clean.mk: fix target clean
9379         * as/z80/clean.mk: fix target clean
9380
9381 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9382
9383         * Makefile.common.in: added  AT EXEEXT AT
9384         * configure.in: removed all mingw32 stuff
9385         * configure: rebuilt from configure.in
9386         * doc/sdccman.lyx: updated section "installation"
9387         * support/scripts/sdcc_mingw32: adapted to configure
9388         * support/scripts/sdcc_cygwin_mingw32: added
9389
9390 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9391
9392         * src/pic Added object file support for the PIC port
9393         * src/pic Applied patch from Craig Franklin (this started the object file support)
9394         * src/regression Updated the PIC regression tests for object files
9395
9396 2003-04-20  Borut Razem <borut.razem AT siol.net>
9397
9398         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9399           lklex.c: In function `getfid':
9400           lklex.c:203: warning: array subscript has type `char'
9401         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9402           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9403         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9404           stack handling macros
9405
9406 2003-04-19  Borut Razem <borut.razem AT siol.net>
9407
9408         * "handling space characters in file path" task:
9409         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9410         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9411         * support/Util/MySystem.h: make it self-sufficient
9412         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9413           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9414           handling space characters in file path
9415         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9416           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9417         * support/Util/MySystem.c: handling space characters in executable's path
9418
9419 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9420
9421         * as/z80/Makefile: fix permanent rebuild of z80
9422         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9423         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9424
9425 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9426
9427         * src/SDCCopt.c: add special case optimization to replace modulo by
9428           a power of two with a bitwise AND.
9429
9430 2003-04-18    <johan AT balder>
9431
9432         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9433
9434 2003-04-17    <johan AT balder>
9435
9436         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9437         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9438
9439 2003-04-13  Borut Razem <borut.razem AT siol.net>
9440
9441         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9442         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9443           fixed mingw problem in adl_NORMALIZE_PATH
9444
9445 2003-04-12  Borut Razem <borut.razem AT siol.net>
9446
9447         * fixed "#pragma SAVE/RESTORE can not be nested":
9448         * src/SDCC.lex: reworked pragma handling functions
9449         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9450         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9451
9452 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9453
9454         * src/SDCCutil.c (pathEquivalent): defined but not used
9455         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9456         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9457         * configure: rebuilt from configure.in
9458         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9459         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9460         * device/include/Makefile.in: replace sdcc_datadir
9461         * device/lib/Makefile.in: replace sdcc_datadir
9462         * Makefile.common.in: add LDFLAGS from configure
9463         * packihx/Makefile.in: use LDFLAGS
9464         * src/Makefile.in: use LDFLAGS
9465         * support/cpp2/Makefile.in: add LDFLAGS from configure
9466         * support/makebin/Makefile: use LDFLAGS
9467         * .version: bumped version number to 2.3.5
9468
9469 2003-04-12  Borut Razem <borut.razem AT siol.net>
9470
9471         * completed "different paths" task:
9472         * src/SDCCmacro.c: fixed bug in handling quotes
9473         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9474         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9475
9476 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9477
9478         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9479
9480 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9481
9482         * ds390/gen.c ds390/peeph.def: fix bug 706781
9483
9484 2003-04-11  Borut Razem <borut.razem AT siol.net>
9485
9486         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9487
9488 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9489
9490         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9491         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9492          set - this bit used to not be set...).
9493         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9494           bad code in PIC Port
9495         * src/regression/and2.c added to test bug 609268
9496         * src/regression/Makefile added and2.c to regression test
9497
9498
9499 2003-04-08    <johan AT CP255758-A>
9500
9501         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9502         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9503         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9504
9505 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9506
9507         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9508         fix bug #487815
9509         * support/cpp2/Makefile.in: fix bug #487815
9510         * configure: rebuilt from configure.in
9511         * Makefile.common.in: docdir changed, new path suffixes
9512         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9513         * sdcc_vc_in.h: reflect changes from sdccconf.h
9514         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9515         * src/SDCCutil.h: remove BINDIR hack
9516         * doc/sdccman.lyx: update new path hierarchy
9517
9518 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9519
9520         * src/SDCCpeeph.c: added okToRemoveSLOC test
9521
9522 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9523
9524         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9525
9526 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9527
9528         * src/SDCCpeeph.c: added labelIsReturnOnly test
9529         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9530
9531 2003-04-05    <johan AT balder>
9532
9533         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
9534         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
9535         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
9536         * src/SDCCast.c: fixed a warning
9537         * src/SDCCast.h: fixed a warning
9538         * src/SDCCicode.c (operandFromAst): fixed a warning
9539
9540 2003-04-04    <johan AT balder>
9541
9542         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
9543         * src/SDCCast.c (decorateType): fixed bug #715076
9544         * src/SDCC.y: fixed bug #702907
9545
9546 2003-04-03    <johan AT balder>
9547
9548         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
9549         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
9550         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
9551         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
9552         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
9553
9554 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
9555
9556         * _decdptr.c: fix return values
9557         * _gptrget.c: fix return values
9558         * _gptrgetc.c: fix return values
9559         * _gptrput.c: fix return values
9560         * _mulint.c: fix return values
9561         * as/z80/Makefile: fix 'make -j' problem
9562
9563 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
9564
9565         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
9566         * configure.in: big cleanup, updated to autoconf 2.5x
9567         * configure: rebuilt from configure.in
9568         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9569         * sdcc_vc_in.h: reflect changes from sdccconf.h
9570         * doc/Makefile: fixed a flaw in "make install"
9571
9572 2003-04-02    <johan AT balder>
9573
9574         * src/ds390/gen.c (genCmp): no comments
9575         * src/mcs51/gen.c (genCmp): no comments
9576         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
9577         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
9578
9579 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
9580
9581         * support/regression/generate-cases.py: place generated file in given sub directory
9582         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
9583         * support/regression/Makefile: improvements for 'make -j';
9584         side effect: it's simpler and faster now
9585
9586 2003-03-31  Borut Razem <borut.razem AT siol.net>
9587
9588         * src/z80/main.c: link-{port} and as-{port} defined without path
9589         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
9590
9591 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
9592
9593         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
9594
9595 2003-03-30  Borut Razem <borut.razem AT siol.net>
9596
9597         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
9598           changed type of list parameter to set
9599         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
9600         * src/port.h: changed type of do_assemble() parameter to set
9601         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
9602           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
9603           definition of "cppoutfilename" macro with NULL value in preProcess()
9604         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
9605         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
9606         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
9607           replaced with set *binPathSet
9608         * shash_add() deallocates the item, if allready exsists, before adding the new one
9609         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
9610
9611 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
9612
9613         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
9614           a nested for loop bug in the PIC port
9615         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
9616           for loops
9617
9618 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
9619
9620         * support/Util/dbuf.h: remove C++ stuff to make it portable
9621
9622 2003-03-28  Borut Razem <borut.razem AT siol.net>
9623
9624         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
9625           literal strings in stringLiteral()
9626         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
9627         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
9628           to the project
9629
9630 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
9631
9632         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
9633
9634 2003-03-26    <johan AT balder>
9635
9636         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
9637         * src/ds390/gen.c (saveRegisters): catched symbol abuse
9638         * src/SDCCast.c (decorateType): fixed " -v < 3"
9639
9640 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
9641
9642         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
9643         Added Lenny Story's debug infrastructure changes:
9644         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
9645         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
9646         * src/cdbFile.c: added
9647         * src/SDCCdebug.c: added
9648         * src/SDCCdebug.h: added
9649         * src/SDCCast.c (createFunction)
9650         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
9651         * src/SDCCmain.c (parseCmdLine, main)
9652         * src/SDCCmem.c (redoStackOffsets)
9653         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
9654         * src/SDCCsymt.h
9655         * src/common.h
9656         * src/avr/gen.c (genAVRCode)
9657         * src/ds390/gen.c (gen390Code)
9658         * src/mcs51/gen.c (gen51Code)
9659         * src/pic/gen.c (genpic14Code)
9660         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
9661         * src/xa51/gen.c (genXA51Code)
9662         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
9663
9664 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9665
9666         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
9667         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
9668
9669 2003-03-22    <johan AT balder>
9670
9671         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
9672
9673 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
9674
9675         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
9676         * doc/cdbfileformat.lyx: added, written by Lenny Story
9677         * doc/Makefile: added cdbfileformat.lyx
9678         * doc/clean.mk: added cdbfileformat.lyx
9679
9680 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
9681
9682         * src/mcs51/peeph.def: fix bug #705773
9683
9684 2003-03-20    <johan AT balder>
9685
9686         An sfr/sbit can have an "at #" AND an initializer
9687         * src/SDCCsymt.c (checkSClass):
9688         * src/SDCCmem.c (allocGlobal):
9689         * src/SDCCmem.c (allocLocal):
9690         * src/SDCCast.c (createBlock):
9691
9692 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
9693
9694         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
9695
9696 2003-03-16    <johan AT balder>
9697
9698         Undid the hackup of const and volatile, the problem is much bigger
9699         * src/SDCC.y:1.65
9700         * src/SDCCast.c:1.171
9701         * src/SDCCglue.c:1.138
9702         * src/SDCCicode.c:1.146
9703         * src/SDCCsymt.c:1.150
9704         * src/SDCCval.c:1.65
9705
9706 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
9707
9708         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
9709         * src/ds390/gen.c (genAddrOf): fixed bug #704087
9710
9711 2003-03-13    <johan AT balder>
9712
9713         Hackup const and volatile modifiers in type chains a bit:
9714         * src/SDCC.y:1.63
9715         * src/SDCCast.c:1.169
9716         * src/SDCCglue.c:1.136
9717         * src/SDCCicode.c:1.143
9718         * src/SDCCsymt.c1.146
9719         * src/SDCCsymt.h1.59
9720         * src/SDCCval.c:1.63
9721
9722 2003-03-12    <johan AT balder>
9723
9724         * src/SDCCBBlock.h: more LRH debugging junk
9725         * src/SDCCcflow.h: more LRH debugging junk
9726         * src/SDCCloop.c: more LRH debugging junk
9727         * src/SDCC.y (struct_declaration): fixed bug #697590
9728         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
9729         * src/ds390/gen.c (aopForRemat): fixed bug #700031
9730         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
9731
9732 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9733         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
9734         test function names must now match exactly).
9735         * src/SDCCcse.c: added special case in findCheaperOp to allow
9736         extending a short integer. Makes less awful code for bug 700121 test case.
9737
9738 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9739
9740         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
9741         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
9742
9743 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9744
9745         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
9746         actually called (operandsNotEqual() was called for all
9747         operandsNotEqualX tests).
9748
9749 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9750
9751         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
9752         with shorter literals. Fixes bug 700121.
9753
9754 2003-03-11    <johan AT balder>
9755
9756         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
9757
9758 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
9759
9760         * src/SDCCloop.c (mergeRegions): an evil beast is dead
9761         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
9762
9763 2003-03-10  Borut Razem <borut.razem AT siol.net>
9764
9765         * src/SDCCmain.c: pipe preprocessor's output
9766         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
9767         * sdcc_vc_in.h: define pclose as _pclose for WIN32
9768         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
9769         which closes all pipes in pipeSet set
9770         * src/SDCCset.c: free deleted item in function deleteSetItem()
9771         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
9772         moved from z80 to src subproject
9773         * .version: increased version number to 2.3.4
9774
9775 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
9776
9777         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
9778         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
9779         * support/regression/ports/xa51/spec.mk: fix typo
9780
9781 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
9782
9783         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
9784
9785 2003-03-09  Borut Razem <borut.razem AT siol.net>
9786
9787         * src/SDCCmain.c: pipe preprocessor's output
9788         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
9789         * sdcc_vc_in.h: define pclose as _pclose for WIN32
9790         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
9791         which closes all pipes in pipeSet set
9792         * src/SDCCset.c: free deleted item in function deleteSetItem()
9793         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
9794         moved from z80 to src subproject
9795
9796 2003-03-09  Borut Razem <borut.razem AT siol.net>
9797
9798         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
9799         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
9800         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
9801         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
9802         * src/SDCCglobl.h: unification of WIN32 native definitions
9803
9804 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9805
9806         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
9807
9808 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
9809
9810         * src/configure.in:   check for endianess (even while cross-compiling)
9811         * src/configure:      check for endianess (even while cross-compiling)
9812         * src/configure_in.h: check for endianess (even while cross-compiling)
9813         * src/avr/gen.c:        remove old endianess stuff
9814         * src/mcs51/gen.c:      remove old endianess stuff
9815         * src/ds390/gen.c:      remove old endianess stuff
9816         * src/pic/gen.c:        remove old endianess stuff
9817         * src/pic/genarith.c:   remove old endianess stuff
9818         * src/pic/glue.c:       fix endianess check
9819         * src/pic16/gen.c:      remove old endianess stuff
9820         * src/pic16/genarith.c: remove old endianess stuff
9821         * src/pic16/glue.c:     fix endianess check
9822         * src/xa51/gen.c:       remove old endianess stuff
9823         * src/z80/gen.c:        fix endianess check
9824         * src/SDCCglue.c:       fix endianess check
9825         * src/ds390/peeph.def: fix bug 700036
9826
9827 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
9828
9829         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
9830         * src/configure: find appropriate data-types on host for SDCC's int and long
9831         * src/configure.in: find appropriate data-types on host for SDCC's int and long
9832         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
9833         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
9834
9835 2003-03-07    <johan AT balder>
9836
9837         Just a big NOOP:
9838                 some minor cleanups before the big shot
9839                 OP_DEFS and OP_USES now use Kevin's protection
9840                 new option --nolabelopt
9841
9842         * src/SDCCBBlock.c:
9843         * src/SDCCast.c,:
9844         * src/SDCCcflow.c:
9845         * src/SDCCcse.c:
9846         * src/SDCCicode.c:
9847         * src/SDCCicode.h:
9848         * src/SDCClabel.c:
9849         * src/SDCCloop.c:
9850         * src/SDCCmain.c:
9851         * src/ds390/ralloc.c:
9852         * src/mcs51/ralloc.c:
9853         * src/pic/ralloc.c:
9854         * src/xa51/ralloc.c:
9855         * src/z80/ralloc.c:
9856
9857 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
9858
9859         * src/pic/pcode.c (get_op): fix 64 bit warnings
9860         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
9861         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
9862         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
9863         * support/regression/tests/malloc.c: fix 64 bit warnings
9864
9865 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
9866
9867         * src/mcs51/gen.c (genMinus): fixed bug 696436
9868
9869 2003-03-02  Borut Razem <borut.razem AT siol.net>
9870
9871         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
9872
9873 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
9874
9875         * configure.in: test for mkstemp
9876         * sdccconf_in.h: add HAVE_MKSTEMP
9877
9878 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
9879
9880         * device/include/ctype.h: removed warning while using --stack-auto
9881         * device/include/malloc.h: removed warning while using --stack-auto
9882         * device/include/string.h: removed warning while using --stack-auto
9883
9884 2003-02-23  Borut Razem <borut.razem AT siol.net>
9885
9886         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
9887         because NDEBUG is defined (see man assert)
9888         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
9889
9890 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9891
9892         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
9893         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
9894
9895 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9896
9897         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
9898         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
9899
9900 2003-02-18    <johan AT balder>
9901
9902         * as/mcs51/asmain.c (asmbl): module can start with a digit
9903         * as/z80/asmain.c (asmbl): module can start with a digit
9904
9905 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
9906
9907         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
9908         * src/asm.c: fix pipe() for Mingw32
9909
9910 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
9911
9912         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
9913         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
9914         make -V work again; --c1mode reads now from stdin
9915         * doc/sdccman.lyx: added --c1mode
9916         * support/Util/SDCCerr.c: new messages for c1 mode
9917         * support/Util/SDCCerr.h: new messages for c1 mode
9918         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
9919
9920 2003-02-15    <johan AT balder>
9921
9922         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
9923
9924 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
9925
9926         * doc/sdccman.lyx: Environment variables, -o and other minor things
9927
9928 2003-02-14    <johan AT balder>
9929
9930         * src/xa51/main.c: before anyone really tries to use it :)
9931
9932         * Install doc's in share/sdcc/doc
9933         * removed some obsolete files
9934         * Do a proper make distclean and uninstall
9935         M Makefile.common.in
9936         R sdccbuild.sh
9937         M as/Makefile
9938         M device/include/Makefile.in
9939         M device/lib/Makefile.in
9940         M doc/sdccman.lyx
9941         M link/Makefile
9942         M sim/ucsim/doc/Makefile.in
9943         M src/clean.mk
9944         R src/avr/peeph.rul
9945         R src/xa51/peeph.rul
9946         M support/cpp2/Makefile.in
9947         M support/makebin/Makefile
9948
9949
9950 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
9951
9952         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
9953
9954 2003-02-10  Borut Razem <borut.razem AT siol.net>
9955
9956         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
9957         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
9958         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
9959         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
9960         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
9961         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
9962         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
9963         src/z80/Makefile.bcc: Borland Makefile cleanup
9964         * as/z80/Makefile.bcc: Added Borland Makefile
9965         * support/cpp2/borland.h: Removed
9966
9967 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
9968
9969         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
9970         * src/SDCC.lex: new pragma NOIV
9971         * src/SDCCglobl.h: new pragma NOIV
9972         * src/SDCCmem.c: new pragma NOIV
9973
9974 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
9975
9976         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
9977
9978 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
9979
9980         * src/SDCCmain.c: signal handling is switched off by --debug
9981         * doc/Makefile: small fix for install; use clean.mk again
9982         * doc/clean.mk: clean *.pdf and *.html too
9983
9984 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
9985
9986         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
9987         * device/lib/printfl.c: fix a ds390 bug by making it portable
9988         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
9989         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
9990         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
9991         * debugger/mcs51/cmd.c: converted multi-line string literals
9992         * sim/ucsim/globals.cc: converted multi-line string literals
9993         * src/SDCCmain.c: introduced signal handler to remove temp files
9994         * doc/Makefile: small tweaks, implement clean
9995         * doc: removed generated files
9996
9997 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9998
9999         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10000         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10001         Address Record is not correctly generated for DS390."
10002
10003 2003-02-02  Borut Razem <borut.razem AT siol.net>
10004
10005         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10006         * as/mcs51/asm.h: fixed compilation with Borland C
10007         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10008         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10009         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10010         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10011         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10012         src/z80/Makefile.bcc: delete $(LIB) only if exist
10013         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10014
10015 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10016
10017         * device/include/malloc.h: introduced NULL
10018         * device/include/string.h: introduced NULL
10019         * device/include/stdlib.h: introduced NULL
10020         * device/lib/_memcpy.c: removed NULL
10021         * device/lib/_strcat.c: removed NULL
10022         * device/lib/_strchr.c: removed NULL
10023         * device/lib/_strcmp.c: removed NULL
10024         * device/lib/_strcpy.c: removed NULL
10025         * device/lib/_strcspn.c: removed NULL
10026         * device/lib/_strlen.c: removed NULL
10027         * device/lib/_strncat.c: removed NULL
10028         * device/lib/_strncmp.c: removed NULL
10029         * device/lib/_strncpy.c: removed NULL
10030         * device/lib/_strpbrk.c: removed NULL
10031         * device/lib/_strrchr.c: removed NULL
10032         * device/lib/_strspn.c: removed NULL
10033         * device/lib/_strstr.c: removed NULL
10034         * device/lib/_strtok.c: removed NULL
10035         * device/lib/malloc.c: removed NULL, include own header
10036
10037 2003-02-02    <johan AT balder>
10038
10039         * 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
10040         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10041         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10042         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10043         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10044         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10045
10046 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10047
10048         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10049         area 'DATA'"
10050
10051 2003-02-01    <johan AT balder>
10052
10053         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10054
10055 2003-01-31    <johan AT CP255758-A>
10056
10057         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10058
10059 2003-01-30    <johan AT balder>
10060
10061         * src/SDCCBBlock.c: automatic bug detection
10062         * src/SDCCicode.c: automatic bug detection
10063
10064 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10065
10066         * src/SDCCglobl.h:   now --xram-size 0 works
10067         * src/SDCCmain.c:    now --xram-size 0 works
10068
10069 2003-01-29    <johan AT balder>
10070
10071         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10072
10073 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10074
10075         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10076         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10077         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10078         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10079         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10080         * src/SDCCmain.c:    Added options --xram-size and --code-size
10081
10082 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10083
10084         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10085         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10086
10087 2003-01-27    <johan AT balder>
10088
10089         * src/SDCC.y: fixed bug #613764
10090
10091 2003-01-26    <johan AT balder>
10092
10093         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10094         * src/SDCCsymt.h: fixed bug #673374
10095         * src/SDCCglue.c: fixed bug #661910
10096         * src/SDCCast.c: fixed bug #458099 and 673374
10097
10098 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10099
10100         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10101         * as/mcs51/strcmpi.h: added
10102         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10103         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10104         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10105         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10106         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10107         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10108         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10109         * as/mcs51/Makefile.aslink: new module strcmpi
10110         * as/mcs51/Makefile.asx8051: new module strcmpi
10111         * as/mcs51/Makefil.bcc: new module strcmpi
10112         * as/mcs51/Makefile.in: new module strcmpi
10113         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10114
10115 2003-01-26    <johan AT balder>
10116
10117         * src/SDCCglue.c: reverted back to 1.124
10118         * src/SDCCast.c: reverted back to 1.156
10119         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10120
10121 2003-01-25    <johan AT balder>
10122
10123         * src/SDCCglue.c: A better fix for bug #661910
10124         * src/SDCCast.c: A better fix for bug #661910
10125         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10126
10127 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10128
10129         * src/Makefile.in: remove spawn.o
10130         * src/SDCCmain.c: remove spawn.h
10131         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10132         * src/spawn.c: removed
10133         * src/spawn.h: removed
10134         * support/regression/ports/ds390/spec.mk: link with -r
10135
10136 2003-01-24    <johan AT CP255758-A>
10137
10138         * src/ds390/gen.c (aopOp): fixed bug #667458
10139         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10140         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10141         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10142
10143 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10144
10145         * src/mcs51/peeph.def: better assembler identation by Frieder
10146         * src/mcs51/gen.c: better assembler identation by Frieder
10147
10148 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10149
10150         * as/z80/string.h: removed for gcc 3.2
10151         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10152         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10153
10154 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10155
10156         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10157         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10158         * support/regression/Makefile: separate temp files for ports
10159         * support/regression/generate-cases.py: separate temp files for ports
10160         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10161         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10162
10163 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10164
10165         * moved tinitalk to device/examples/ds390
10166
10167 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10168
10169         * as/mcs51/lkmem.c: rflag is for DS390
10170         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10171         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10172                          (linkEdit): move mem- and map-files the same way as ihx-files
10173         * src/z80/main.c (_setDefaultOptions): removed --generic
10174         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10175         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10176         * src/pic/glue.c (picglue): --c1mode works again
10177         * src/pic16/glue.c (pic16glue): --c1mode works again
10178         * src/asm.c (printCLine): fix #660034
10179
10180 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10181
10182         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10183         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10184         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10185         * as/mcs51/lkmem (summary): better fix for sp problem
10186         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10187         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10188         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10189                                               remove --stack-after-data
10190
10191 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10192
10193         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10194         * src/SDCCutil.c (join): ugly bug: missing '\0'
10195         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10196
10197 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10198
10199         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10200         * src/port.h: typo
10201         * src/pic/main.c (_asmCmd): gpasm supports -o
10202         * src/z80/main.c: more general macros
10203         * device/lib/Makefile.in: remove intermediate files
10204
10205 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10206
10207         * .version: Bumped version number to 2.3.3
10208         * src/SDCCBBlock.c: new option -o
10209         * src/SDCCglobl.h: new option -o
10210         * src/SDCCglue.c: new option -o
10211         * src/SDCCmain.c: new option -o
10212         * src/asm.c: new option -o
10213         * src/ds390/main.c: new option -o
10214         * src/pic/glue.c: new option -o
10215         * src/pic/pcode.c: new option -o
10216         * src/pic/ralloc.c: new option -o
10217         * src/pic16/glue.c: new option -o
10218         * src/pic16/pcode.c: new option -o
10219         * src/pic16/ralloc.c: new option -o
10220         * src/z80/main.c: new option -o
10221         * device/lib/Makefile.in: use -o
10222         * support/regression/ports/ds390/spec.mk: use -o
10223         * support/regression/ports/gbz80/spec.mk: use -o
10224         * support/regression/ports/mcs51/spec.mk: use -o
10225         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10226         * support/regression/ports/z80/spec.mk: use -o
10227         * support/regression/ports/ucz80/spec.mk: use -o
10228         * support/regression/ports/xa51/spec.mk: use -o
10229         * support/regression/fwk/lib/timeout.c: fix usage string
10230
10231 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10232         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10233
10234 2003-01-07    <johan AT balder>
10235
10236         * src/SDCCast.c (decorateType): fixed bug #600035
10237
10238 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10239         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10240         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10241         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10242         * src/pic/pcode.c: outcommented unused variable to remove warnings
10243         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10244
10245 2003-01-06    <karl AT turbobit.com>
10246         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10247    regression tests.
10248
10249 2003-01-06    <johan AT balder>
10250
10251         * src/SDCCicode.c: fixed array add
10252
10253 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10254         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10255         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10256
10257 2003-01-04    <johan AT balder>
10258
10259         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10260
10261 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10262         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10263
10264 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10265         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10266         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10267
10268 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10269         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10270
10271 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10272         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10273
10274 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10275         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10276
10277 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10278
10279     * in \sdcc\as\mcs51\ changed these files in order to create an
10280     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10281     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10282     following files to include the previous two files: aslink.dsp,
10283     Makefile.aslink, Makefile.bcc, and Makefile.in.
10284
10285     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10286     .adb instead of .cdb
10287
10288 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10289
10290         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10291         value from option --iram-size.
10292
10293 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10294
10295         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10296         dram[] array.
10297
10298 2002-09-18    <wiml AT hhhh.org>
10299
10300         * SDCClrange.h: exposed setFromRange() and setToRange()
10301         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10302           packRegsForAccUse() (bug 542397)
10303         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10304           multiple times and emitting the fetch operations more than once
10305           added aopGetUsesAcc() function to allow binary operators to
10306           fetch their operands in the correct order; made genMinus() emit
10307           compact code for X = LITERAL - Y
10308
10309 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10310         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10311         sprintf() in line 1267.
10312
10313 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10314         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10315         like ports.
10316
10317 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10318         Changes to aslink (All the changes are marked with 'JCF'):
10319
10320         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10321         summary().
10322
10323         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10324         area BSEG.  Also moves, if possible, the DATA area down into the internal
10325         ram so more space is available.
10326
10327         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10328         sflag.
10329
10330         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10331         not bytes.  Function summary() which creates a memory usage summary
10332         file with extension .mem.  Reports of overlaping stack and small stack
10333         size.  If the space for the stack is less than 16 bytes aslink trows a
10334         warning.
10335
10336         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10337         the 8051.  Option 'y' for memory summary output file.
10338
10339         Changes to sdcc (All the changes are marked with 'JCF'):
10340
10341         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10342
10343         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10344         overlaying area for it (uses RegBankUsed[4]).
10345
10346         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10347         bank zero as used by default.  By default aslink locates the stack
10348         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10349         the creation of the .mem file.  Delegates the allocation of data area
10350         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10351         the begining of the stack area to aslink.
10352
10353         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10354         glue() in SDCCglue.c creates an area for it.
10355
10356 2002-09-03  Borut Razem <borut.razem AT siol.net>
10357         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10358         sdcc/src/pic/glue.c:
10359         introduced atexit() handler for teporay files removal in case of
10360         errors, assertions, ...
10361
10362 2002-08-29  Borut Razem <borut.razem AT siol.net>
10363         * sdcc/support/cpp2/auto-host_vc_in.h:
10364         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10365         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10366         Maybe there is a similar problem with BORLANDC? It should be checked!
10367
10368         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10369         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10370         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10371         was not executed, and the compiler (cl) launched a warning:
10372         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10373
10374 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10375         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10376
10377 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10378         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10379
10380         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10381           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10382           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10383           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10384           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10385           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10386           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10387         - added Release configuration in VS projects
10388         - review of compiler an linker options
10389         - VC .exe files are generated in bin_vc directory, not to interfere
10390           with binaries generated from other projects (cygwin, mingw, bcc ...)
10391
10392         * sdcc/src/yacc.dsp: added
10393
10394         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10395         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10396         and insert the version number definitions from .version
10397
10398         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10399
10400         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10401         added - genarate auto-host.h using auto-host_vc_in.h as template
10402
10403         * sdcc/sdcc_vc.h,
10404         removed from CVS, generated automatically
10405
10406 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10407         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10408
10409 2002-08-11  Borut Razem <borut.razem AT siol.net>
10410         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10411
10412 2002-08-10  Borut Razem <borut.razem AT siol.net>
10413         * src/SDCCmain.c (main):
10414         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10415         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10416         The consequence was that some temporary files were not removed.
10417
10418         * src/SDCCglue.c:
10419         unification of code in functions tempfilename() and tempfile():
10420         function tempnam() is defined in Visual Studio 6.0 and .NET
10421
10422         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
10423
10424         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10425           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
10426         - removed compiler command line option /WX: Treats all warnings as errors
10427         - update a list of source files, included into the project
10428
10429         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10430           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10431         changed project type to Generic Project so that can be correcly converted to VS.NET project
10432
10433         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10434
10435         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10436
10437         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10438
10439         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10440         added return 0 statements after assert() to make compiler happy
10441
10442         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10443         added newline in the def file to keep MSC compiler satisfied
10444
10445         * sdcc/src/z80/gen.c:
10446         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10447           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10448         - solved MSC error in function aopDump()
10449
10450         * sdcc_vc.h: define PREFIX as "\\sdcc"
10451
10452 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10453         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10454
10455 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10456         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10457         - Rewrote the register banking algorithm.
10458         - Added pCode live-range analysis to registers (for now, only non-used and
10459         singly-used registers optimized away)
10460
10461         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10462
10463         * 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.
10464
10465 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10466         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10467
10468 2002-04-22  Michael Hope  <michaelh AT vroom>
10469
10470         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10471
10472         * configure.in (DD_COPT): Added include support required for gbdk.
10473
10474         * .version: Bumped version number just to increase it.
10475
10476         * src/SDCCmain.c: Added -nostdinc to the default options.
10477
10478 2002-04-15  Michael Hope  <michaelh AT vroom>
10479
10480         * device/lib/z80/printf.c (sprintf): Added.
10481
10482         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10483
10484         * src/z80/peeph.def: Added transpose redundent load rule.
10485
10486         * src/z80/main.c: Added force callee saves for jaune.
10487
10488         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10489
10490         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10491
10492 2002-03-28  Johan Knol  <johan AT balder>
10493
10494         * src/SDCCval.c: fixed bug #532436
10495
10496 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10497         * /src/port.h:
10498         Added "char *Processor" field to the port structure.
10499
10500         * /src/SDCCmain.c:
10501         Added -p option. Allows port dependent processor to be specified.
10502
10503         * all ports:
10504         Initialized the new field char *Processor field to NULL in all ports
10505
10506         * /src/pic/*:
10507         Compiler generated registers for interrupt context saving
10508         were not getting allocated.
10509
10510 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10511
10512         * /src/SDCCast.c:
10513         Fixed left shift. Will promote the left side of a left shift
10514         if a) left shifting more than size of operand or b) when assigned
10515         to something size > size of left side
10516
10517 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10518         * src/pic/*
10519         tons of changes. Register allocation has been
10520         rewritten. Added customization for the various PICs. Flow
10521         analysis is restructured. ...
10522
10523         * src/pic/device.h:
10524         Added
10525
10526         * src/pic/device.c:
10527         Added. device.c is a PIC port hack to accomodate variations
10528         in PIC devices.
10529
10530 2002-03-13  Michael Hope  <michaelh AT vroom>
10531
10532         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10533
10534 2002-03-04  johanknol  <johanknol AT manik>
10535
10536         * /src/SDCCval.c: fixed
10537
10538         const unsigned char arr[][2] = { { 0, 1 } };
10539         t18.c:1: error: Initializer element is not constant
10540
10541 2002-03-04  bela  <bela AT manik>
10542
10543         * /device/include/mcs51reg.h:
10544         ds89c420 register definition update
10545
10546 2002-03-03    <johan AT FRIJA>
10547
10548         * support/Util/SDCCerr.c: did something, but don't no why anymore
10549
10550         * support/regression/tests/bug-524691.c: made it a little less shy
10551
10552         * src/SDCCast.c (decorateType): fixed bug #524697
10553
10554         * src/SDCCast.c: made some lineno improvements
10555
10556         * src/SDCCval.c (getNelements): changed warning to error
10557
10558         * src/SDCCglue.c (printIvalArray): changed warning to error
10559
10560         * src/SDCCicode.c: fixed a warning for mingw
10561
10562         * src/SDCCast.c (decorateType): fixed the << promotion for ops
10563
10564         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
10565
10566 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
10567
10568         * src/ds390/peeph.def:
10569         Added some more peephole rules
10570
10571         * src/ds390/gen.c: Various fixes & enhancements
10572
10573         * src/SDCClrange.c, src/SDCClrange.h:
10574         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
10575
10576         * src/ds390/ralloc.c:
10577         various fixes & enhancements (ds390) specific
10578
10579         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
10580         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
10581         from rallocs.
10582
10583         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
10584
10585 2002-03-02    <johan AT FRIJA>
10586
10587         * src/SDCCast.c (decorateType): fixed bug #524708
10588
10589         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
10590
10591         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
10592
10593 2002-03-01  Michael Hope  <michaelh AT vroom>
10594
10595         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
10596
10597         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
10598
10599 2002-03-01    <johan AT FRIJA>
10600
10601         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
10602
10603         * src/SDCCast.c (decorateType): fixed bug #524209
10604
10605         * src/SDCCval.c (valNot): fixed bug #524195
10606
10607 2002-02-26    <johan AT balder>
10608
10609         * src/xa51/gen.c: fixed a warning
10610
10611         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
10612
10613         * src/SDCCast.c (decorateType): fixed bug #522534
10614
10615 2002-02-23    <johan AT balder>
10616
10617         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
10618
10619 2002-02-22    <johan AT balder>
10620
10621         * src/SDCCast.c: fixed bug #514865
10622
10623         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
10624
10625 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
10626
10627         * sdcc/src/SDCCloop.c:
10628         Previous fix was not good. basic blocks that have "break" or "return" are
10629         not really partof a loop , but live ranges used in these blocks should
10630         be live thru the entire loop, so set partOfLoop but don't add them to
10631         loop region
10632
10633 2002-02-21    <johan AT FRIJA>
10634
10635         * src/SDCCcse.c: fixed bug #514308
10636
10637 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
10638
10639         * src/SDCCloop.c:
10640         Fixed BUG #519583. If a conditional block ended in a return/break
10641         statement inside a loop, it was not being considered part of the loop.
10642
10643         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
10644
10645 2002-02-10  Karl Bongers <karl AT turbobit.com>
10646
10647         * debugger/*:
10648         Fixed up SDCDB debugger somewhat.  Updated debugger/README
10649         with lots of comments and notes.
10650
10651         * device/examples/test2.c:
10652         Fix bug, "red" variable not being initialized(compiler complained).
10653
10654         * device/examples/Makefile, examples/test3.c:
10655         Add Makefile in device/examples folder, compiles test3.c
10656         for use as a multiple module SDCDB test case.
10657
10658         * sim/ucsim/cmd.src/cmdset.cc:
10659         Took out debug printfs in ucsim "next" command.
10660
10661         * sim/ucsim/xa.src:
10662         Karl and Johan start ucsim XA support.  Most dissassembly working,
10663         about 75% emulation done(plenty of work remaining).
10664
10665         * sim/ucsim/z80.src:
10666         Add Z80 support to ucsim, add test-ucz80 regression test,
10667         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
10668         Notice z80 compiler fails on examples/test3.c/crc code.
10669
10670 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
10671
10672         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
10673         Added support for --parms-in-bank1
10674
10675         * src/ds390/peeph.def:
10676         added a few more peephole optimzations
10677
10678         * src/ds390/main.c:
10679         1) added __builtin_inp & __builtin_outp used to read in data of given length
10680            from a memory mapped port
10681         2) added __builtin_memcmp
10682         3) added __builtin_swapw swap bytes of a short
10683
10684         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
10685         1) handle multiple send & receives from register bank1
10686         2) ralloc can now allocate DPTR1 to some liveRanges
10687
10688         * src/SDCCsymt.c, src/SDCCsymt.h:
10689         changes to handle multiple sends & receives
10690
10691         * src/SDCCptropt.h:
10692         added some pointer arithmetic optimization
10693
10694         * src/SDCCptropt.c:
10695         added some pointer arithmetic optimizations but not stable yet so not
10696         called from anywhere (will get this working shortly)
10697
10698         * src/SDCCopt.c: fixed for multiple sends & receives
10699
10700         * src/SDCCmain.c:
10701         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
10702         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
10703            set preprocessor defines (depending on options)
10704
10705         * src/SDCCicode.c, src/SDCCicode.h:
10706         changes made to handle multiple sends & receives
10707
10708         * src/SDCCglobl.h:
10709         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
10710
10711         * src/SDCCcse.c, src/SDCCcse.h:
10712         added function findbackward def (to be used in upcoming optimization)
10713
10714         * src/SDCCcflow.c, src/SDCCcflow.h:
10715         added function returnAtEnd - to determine if a basic block terminates with
10716         a RETURN iCode
10717
10718         * src/SDCCast.c, src/SDCCast.h:
10719         added option parms-in-bank1
10720
10721         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
10722         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
10723         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
10724         adjusted for --parms-in-bank1 option
10725
10726         * device/include/string.h:
10727         donot redefine "reentrant" keyword
10728
10729         * device/include/ds80c390.h: Added some more SFRs
10730
10731 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
10732
10733         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
10734
10735 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
10736
10737         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
10738
10739 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
10740
10741         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
10742
10743 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
10744
10745         * Added --xram-movc option
10746
10747 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
10748
10749         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
10750
10751 2002-01-11  Johan Knol
10752
10753         * Added math lib of Jesus Calvino-Fraga
10754
10755 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
10756
10757         * src/SDCCmain.c (processFile): fix processing of ../../src.c
10758         * support/regression/Makefile: new target test-mcs51-stack-auto
10759         * support/regression/ports/mcs51-stack-auto/spec.mk: added
10760
10761 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
10762
10763         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
10764
10765 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
10766
10767         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
10768
10769 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
10770
10771         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
10772
10773         * src/SDCCglue.h: add definition for printIvalChar()
10774
10775 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
10776
10777         * src/SDCCast.c: fix #498138 by Johan
10778
10779         * src/SDCCglue.c: fix #498138 by Johan
10780
10781 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
10782
10783         * support/regression/Makefile: fix clean
10784
10785         * support/regression/ports/ds390/support.c: fix transmission of last character
10786
10787 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
10788
10789         * /sdcc/src/ds390/gen.c:
10790         a) improved computing address of stack variable
10791         b) took out some #if 0 code
10792         c) improved parmBytes adjustment
10793         d) improved genPlusIncr & genMinusIncr
10794         e) genCmp could generate bad code (when left assigned to DPTR)
10795         f) Fixed bug in hasInc
10796
10797         * /sdcc/src/ds390/ralloc.c:
10798         a) packRegsForSupport could mess up live information (Fixed)
10799         b) packRegsDPTRuse could be incorrect for left & right shift
10800
10801         * /sdcc/src/mcs51/ralloc.c:
10802         packRegsForSupport could mess up the live information (Fixed)
10803
10804         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
10805
10806         * /sdcc/src/SDCCast.c:
10807         can reverse a loop even if function call is present as long
10808         as the loop control variable is local & is not passed as parameter
10809
10810 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10811
10812         * /sdcc/ChangeLog: *** empty log message ***
10813
10814         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
10815         More builtin function additions for TININative
10816
10817         * /sdcc/src/ds390/ralloc.c:
10818         Had broken the regression testsuite
10819
10820         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
10821
10822         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
10823         Added funcattr hasStackParms will be set for reentrant functions when there
10824         are paramteres on the stack, this helps in minimizing frame pointer generation
10825         typeFromStr can handle function pointers now
10826
10827         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
10828         *** empty log message ***
10829
10830 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10831
10832         * /src/ds390/gen.c, /src/ds390/main.c:
10833         More builtin function additions for TININative
10834
10835         * /src/ds390/ralloc.c:
10836         Had broken the regression testsuite
10837
10838         * /src/SDCCast.c: Fixed a bug in dumptree
10839
10840         * /src/SDCCsymt.c, /src/SDCCsymt.h:
10841         Added funcattr hasStackParms will be set for reentrant functions when there
10842         are paramteres on the stack, this helps in minimizing frame pointer generation
10843         typeFromStr can handle function pointers now
10844
10845         * /doc/builtins.txt, /doc/TININative.txt:
10846         *** empty log message ***
10847
10848
10849 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10850
10851         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
10852         ALPHA version for -mTININative
10853
10854         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
10855         updated to reflect changes in the port structure
10856
10857         * /src/port.h:
10858         added function do_assemble (similar to do_link) if non-null this function
10859         will be called to do assembly (-mTININative) requires a multi command
10860         assembly
10861         added function genAssemblerEnd will be called to generate assembler Epilogue
10862
10863         * /src/SDCCsymt.c:
10864         added _JavaNative to debug info printing
10865
10866         * /src/SDCCmain.c: added option --tini-libid
10867         added port->do_assemble function (-mTININative) has a multi command assemble
10868
10869         * /src/SDCCglue.c: Disabled "constExpr" check
10870         added port->genAssemblerEnd function
10871
10872         * /src/SDCCglobl.h: Added option --tini-libid value
10873
10874         * /src/SDCCast.h:
10875         tookout optimizeCompare from the header (has no external references)
10876
10877         * /src/SDCCast.c: made one more function "static"
10878
10879 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
10880
10881         * src/z80/mappings.i: Added z80asm support.
10882
10883         * src/z80/main.c: Added z80asm support on --asm=z80asm
10884
10885         * src/z80/gen.c: Fixed asm portability issues.
10886
10887         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
10888
10889         * src/SDCCglue.c (printExterns): Added global/extern split.
10890
10891 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
10892
10893         * support/regression/Makefile: added test for mcs51 model large
10894
10895         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
10896
10897         * support/regression/ports/gbz80/spec.mk: added -mgbz80
10898
10899 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
10900
10901         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
10902
10903 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
10904
10905         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
10906
10907         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
10908
10909 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
10910
10911         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
10912
10913         * support/regression/tests/simplefloat.c: Port to mcs51.
10914
10915 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
10916         * support/regression/tests/bug-485362.c: Added.
10917
10918         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
10919
10920         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
10921
10922         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
10923
10924         * src/z80/gen.c (aopDump): Added a dump function.
10925
10926 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
10927         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
10928
10929         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
10930
10931         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
10932
10933         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
10934
10935         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
10936
10937         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
10938
10939         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
10940
10941         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
10942
10943         * support/regression/ports/ds390/support.c: Use tinibios.
10944
10945         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
10946
10947 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
10948
10949         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
10950         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
10951
10952         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
10953
10954         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
10955
10956 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
10957
10958         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
10959
10960         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
10961         (packRegsForIYUse): Created and optimised.
10962
10963 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
10964
10965         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
10966 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
10967
10968         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
10969
10970         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
10971
10972         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
10973
10974 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
10975
10976         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
10977
10978         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
10979
10980 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
10981
10982         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
10983
10984         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
10985
10986         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
10987
10988 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
10989
10990         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
10991         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
10992         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
10993
10994         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
10995
10996         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
10997         (genNotFloat): Added.
10998         (genUminusFloat): Added.
10999
11000         * device/lib/z80/Makefile: Added floating pt stubs.
11001
11002         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11003
11004         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11005
11006         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11007
11008 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11009
11010         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11011
11012         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11013
11014         * sdcc/support/regression/Makefile: Add port ds390.
11015
11016         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11017
11018         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11019
11020         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11021
11022         * sdcc/support/regression/ports/ds390/support.c: Added.
11023
11024         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11025
11026         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11027
11028         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11029
11030 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11031
11032         * device/include/malloc.h: Added z80 and gbz80 support.
11033
11034         * device/lib/gbz80/heap.s: Added.
11035
11036         * device/lib/z80/heap.s: Added.
11037
11038         * device/lib/malloc.c: Added z80 and gbz80 support.
11039
11040         * support/regression/tests/malloc.c (testMalloc): Added.
11041
11042         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11043
11044         * support/regression/tests/bug-478094.c: Added.
11045
11046         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11047
11048 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11049
11050         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11051
11052         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11053
11054         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11055
11056         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11057
11058         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11059
11060 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11061
11062         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11063
11064 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11065
11066         * support/regression/tests/bug-477927.c: Added.
11067
11068         * src/z80/peeph.def: Added minor rules.
11069
11070         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11071
11072         * src/z80/peeph.def: Added jump optimisation modification.
11073
11074 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11075
11076         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11077
11078 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11079
11080         * support/regression/tests/funptrs.c: Added.
11081
11082 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11083
11084         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11085
11086 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11087
11088         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11089
11090         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11091
11092         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11093         (movLeft2ResultLong): Created.
11094
11095         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11096         (joinPushes): Added.  Joins two char pushes into a word push.
11097
11098 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11099
11100         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11101
11102         * support/makebin/Makefile (install): Added creation of dest dir.
11103
11104 2001-10-24 Karl Bongers <karl AT turbobit.com>
11105
11106         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11107
11108 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11109
11110         * src/z80/ralloc.c: Turned off faulty pack for one use.
11111
11112         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11113
11114         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11115
11116 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11117
11118         * support/regression/Makefile: Improved clean
11119
11120         * support/regression/ports/gbz80/spec.mk: Added clean
11121
11122         * support/regression/ports/host/spec.mk: Added clean
11123
11124         * support/regression/ports/z80/spec.mk: Added clean
11125
11126         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11127
11128         * support/regression/ports/mcs51/timeout.c: little improvements
11129
11130 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11131
11132         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11133
11134         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11135
11136         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11137
11138 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11139
11140         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11141
11142         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11143
11144 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11145         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11146
11147         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11148
11149         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11150
11151         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11152
11153         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11154
11155         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11156
11157         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11158
11159         * support/regression/tests/longor.c: Added.
11160
11161 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11162
11163         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11164
11165         * as/mcs51/aslink.h: define PATH_MAX
11166
11167         * as/mcs51/asm.h: define PATH_MAX
11168
11169         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11170
11171         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11172
11173         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11174
11175         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11176
11177         * src/SDCCglobl.h: define PATH_MAX
11178
11179         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11180
11181         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11182
11183 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11184
11185         * src/z80/gen.c (gencjneshort): Fixed
11186
11187         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11188
11189 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11190
11191         * support/regression/tests/bug-469671.c: Added.
11192
11193         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11194
11195 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11196
11197         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11198
11199         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11200
11201 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11202
11203         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11204
11205         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11206
11207         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11208
11209         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11210
11211         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11212
11213         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11214
11215         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11216
11217 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11218
11219         * 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.
11220
11221         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11222
11223         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11224
11225 2001-10-07    <johan AT FRIJA>
11226
11227         * device/lib/gets.c (gets): fixed the return value.
11228
11229 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11230         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11231
11232         * 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.
11233
11234         * 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.
11235
11236         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11237
11238         * src/pic/gen.c: Removed Safe_strdup.
11239
11240         * configure.in: Added option to enable libgc support.
11241
11242         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11243         (bitVectUnion): Optimised.
11244         (bitVectIntersect): Optimised.
11245         (bitVectBitsInCommon): Optimised.
11246         (bitVectCplAnd): Optimised.
11247
11248         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11249
11250 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11251
11252         * src/SDCCmain.c: distinguish between assembler debug and plain options
11253
11254         * src/avr/main.c:   remove standard assembler options
11255
11256         * src/ds390/main.c: remove standard assembler options
11257
11258         * src/mcs51/main.c: remove standard assembler options
11259
11260         * src/port.h: removed "PENDING" comment
11261
11262 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11263
11264         * src/device/lib/_mulint.c  : new, with assember functions
11265
11266         * src/device/lib/_mullong.c : new, with assember functions
11267
11268         * src/device/lib/_divuint.c : with assember functions
11269
11270         * src/device/lib/_divsint.c : with assember functions
11271
11272         * src/device/lib/_divulong.c: with assember functions
11273
11274         * src/device/lib/_divslong.c: with assember functions
11275
11276         * src/device/lib/_moduint.c : with assember functions
11277
11278         * src/device/lib/_modsint.c : with assember functions
11279
11280         * src/device/lib/_modulong.c: with assember functions
11281
11282         * src/device/lib/_modslong.c: with assember functions
11283
11284         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11285
11286         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11287
11288         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11289                                       replaced _mululong.c and _mulslong.c by _mullong.c
11290
11291 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11292
11293         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11294
11295 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11296
11297         * src/SDCCglue.c: test, if win32api is available for MINGW
11298
11299 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11300
11301         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11302         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11303         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11304         * support/regression/ports/host/spec.mk: removed GENERIC
11305         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11306         * support/regression/ports/z80/spec.mk: removed GENERIC
11307
11308 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11309
11310         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11311
11312         * support/regression/tests/bug-467035.c: Created.
11313
11314 2001-10-01    <johan AT FRIJA>
11315
11316         * src/SDCC.y: fixed bug #466586 part 1
11317
11318 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11319
11320         * SDCCicode.c: z80 has no generic pointers
11321         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11322
11323 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11324
11325         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11326
11327 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11328
11329         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11330
11331         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11332
11333 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11334
11335         * configure.in: Fixed up so that ucsim is only configured once.
11336
11337         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11338
11339         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11340         (getPathDifference): As above.
11341
11342         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11343
11344         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11345
11346 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11347         * .version: Updated to 2.3.1
11348
11349         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11350         Added copyright header.
11351
11352         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11353         (assemble): Added support for macro based assembler commands.
11354         (linkEdit): Added support for macro based linker commands.
11355         (preProcess): Changed the pre-processor to use macros.
11356         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11357         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11358
11359         * device/lib/z80/crt0.s: Added module name for debugging.
11360
11361 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11362
11363         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11364
11365         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11366
11367         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11368
11369         * src/Makefile.in: Added SDCCmacro and SDCCutil
11370
11371 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11372
11373         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11374
11375 2001-09-16    <johan AT FRIJA>
11376
11377         * 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.
11378
11379 2001-09-15    <johan AT FRIJA>
11380
11381         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11382         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11383
11384 2001-09-11    <johan AT FRIJA>
11385
11386         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11387
11388 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11389
11390         * support/regression/tests/bug-460444.c: Added test case.
11391
11392         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11393         (genCast): Added justification for all of the asserts.
11394
11395 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11396
11397         * support/regression/support.c: _xdata replaced by xdata
11398
11399         * support/regression/spec.mk: removed _generic
11400
11401 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11402
11403         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11404
11405         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11406         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11407
11408         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11409
11410         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11411
11412         * support/regression/tests/bug-460010.c: Added test case.
11413
11414         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11415
11416 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11417
11418         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11419
11420         * support/regression/testfwk.c: removed workaround for bug #436344
11421
11422         * support/regression/tests/bp.c: use less memory with mcs51
11423
11424         * support/regression/tests/bug-441448.c: use less memory
11425
11426         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11427
11428         * support/regression/collate-results.py: typo
11429
11430 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11431
11432         * support/regression/tests/fetchoverlap.c: Added new test case.
11433
11434         * support/regression/tests/bp.c: Added new test case.
11435
11436         * support/regression/tests/bug-448984.c: Added new test case.
11437
11438         * support/regression/tests/pow2shifts.c: Added new test case.
11439
11440         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11441         (genlshTwo): Fixed right shift for count > 8.
11442
11443         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11444
11445 2001-09-08    <johan AT FRIJA>
11446
11447         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11448
11449 2001-09-07    <johan AT FRIJA>
11450
11451         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11452
11453         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11454
11455 2001-09-06    <johan AT FRIJA>
11456
11457         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11458         * bernhard noted me at this: "() equals to (void)" (1.38)
11459
11460 2001-09-05    <johan AT FRIJA>
11461
11462         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11463
11464 2001-09-04    <johan AT FRIJA>
11465
11466         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11467
11468
11469 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11470
11471         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11472
11473 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11474
11475         * link/z80/aslink.h: Fixed path for PATH_MAX
11476
11477 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11478
11479         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11480
11481         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11482
11483         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11484
11485         * 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.
11486
11487 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11488
11489         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11490         (genCmp): Fixed up genCmp for the GB with longs.
11491
11492         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11493
11494         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11495
11496         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11497
11498         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11499
11500 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11501
11502         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11503
11504 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11505
11506         * 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.
11507
11508         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11509
11510 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11511
11512         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11513
11514         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11515
11516 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11517
11518   * sim/ucsim/configure:    little improvement of Cygwin-detection
11519   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11520   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11521   * support/regression/tests/bug-221100.c: small changes for mcs51
11522   * support/regression/tests/bug-221168.c: small changes for mcs51
11523   * support/regression/tests/bug-227710.c: small changes for mcs51
11524   * support/regression/tests/staticinit.c: small changes for mcs51
11525   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11526   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11527   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11528
11529 $Revision$