* link/z80/lkgb.c,
[fw/sdcc] / ChangeLog
1 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * link/z80/lkgb.c,
4         * link/z80/lkgg.c,
5         * src/pic16/gen.c,
6         * src/pic16/main.c,
7         * src/pic16/pcode.c,
8         * src/pic/main.c,
9         * src/pic/pcoderegs.c,
10         * src/SDCCicode.c,
11         * src/SDCCmain.c,
12         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
13           bug 1504689 on minGW
14
15 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
16
17         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
18
19 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
20
21         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
22
23 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
24
25         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
26           for optimization
27
28 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
29
30         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
31         to a char variable. Fixed bug #1504211
32         * device/include/pic16/adc.h,
33         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
34         and fixed bug #1364390
35
36 2006-06-10 Borut Razem <borut.razem AT siol.net>
37
38         * CVSROOT: removed the CVS left-over
39
40 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
41
42         * as/hc08/asmain.c (asexit),
43         * as/hc08/lkmain.c (lkexit),
44         * as/mcs51/asmain.c (asexit),
45         * as/mcs51/lkmain.c (lkexit),
46         * src/SDCCglue.c (DEFSETFUNC),
47         * src/SDCCmain.c (linkEdit, assemble),
48         * support/librarian/sdcclib.c (AddRel),
49           replaced unlink() by standard C remove()
50         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
51         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
52           gatherImplicitVariables): new, added to fix bug 608752,
53           (createFunction): added gatherImplicitVariables()
54         * src/SDCCast.h: added createRMW prototype
55         * src/SDCCsymt.h (struct symbol): added infertype
56         * support/regression/tests/bug608752.c: new, added
57
58 2006-06-10 Raphael Neider <rneider AT web.de>
59
60         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
61           multibyte dummy reads (fixes #1503234)
62
63 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
64
65         * device/include/mcs51/compiler.h: new, added header file to enable
66           creating common sfr definition header files for different compilers
67
68 2006-06-05 Raphael Neider <rneider AT web.de>
69
70         * src/pic16/{pcode.h,genarith.c}:
71           introduced pCodeOp combining any two pCodeOps (previously only
72           two register operands could be combined), removed pcop2 from
73           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
74         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
75         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
76           rewritten to use new PO_TWO_OPS
77         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
78         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
79           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
80           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
81           (pic16_get_op): embraced return arg to allow #define return(x),
82             added new case for combined opcodes
83           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
84           (pic16_pCode2str,pic16_getRegFrompCodeOp,
85            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
86
87 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
88
89         * src/SDCCval.c (checkConstantRange): added
90         * src/SDCCval.h: added checkConstantRange
91         * support/Util/SDCCerr.c,
92         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
93         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
94         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
95         * src/SDCCast.c (decorateType): added checkConstantRange,
96         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
97         can be emitted with the correct always true/false warning,
98         added optimization for double '!';
99         result of decorateType() must be assigned back to the tree, because
100         decorateType() can change the tree
101         * src/SDCCicode.c (geniCodeLogic),
102         (geniCodeAssign): replaced new checkConstantRange, added warnings,
103         (checkConstantRange): removed, it was only a fragment which never
104         emitted a warning
105         * src/SDCCsymt.c (computeType): fixed promotion for
106         "-1 < (unsigned bit) b"
107         * src/pic/ralloc.c (packRegsForAssign),
108         * src/pic16/ralloc.c (packRegsForAssign),
109         * src/hc08/ralloc.c (packRegsForAssign),
110         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
111         from mcs51
112         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
113         * support/regression/tests/constantRange.c: added
114         * support/valdiag/tests/constantRange.c: added
115         * support/valdiag/valdiag.py: added -DPORT_HOST=1
116
117 2006-06-02 Borut Razem <borut.razem AT siol.net>
118
119         * support/regression/ports/pic16/support.c: increase stack size
120           to 255 bytes
121         * support/regression/Makefile.in: sort tests by name so that the
122           resutlts can be compared on different machines / platforms
123
124 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
125
126         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
127         * src/ds390/gen.c (emitLabel): new, added,
128           (genDjnz): fixed stack overflow bug,
129           (throughout): cosmetic changes to sync with mcs51/gen.c,
130           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
131         * src/mcs51/gen.c (genEndFunction): small optimization,
132           (throughout): cosmetic changes to sync with ds390/gen.c
133
134 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
135
136         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
137           (_print_format): fixed printing pointers
138         * src/mcs51/gen.c (emitLabel, movb): new, added,
139           (genAssign): small optimization,
140           (genDjnz): fixed stack overflow bug,
141           (throughout): replaced sprintf with SNPRINTF,
142           replaced mcs51_regWithIdx with REG_WITH_INDEX,
143           replaced emitcode("mov", "b,...") with MOVB(...),
144           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
145           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
146         * src/mcs51/peeph.def: added rules 140 and 264
147         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
148           so they may get optimized into registers
149
150 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
151
152         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
153           immediately when encountered,
154           (printUsage): always use stderr even on windows
155
156 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
157
158         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
159         (processParms): fixed bug #1247551
160         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
161         parseCmdLine, main): print '--version' to stdout,
162         print 'help' to stdout if --help is given,
163         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
164         arguments are given; fixed --help
165
166 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
167
168         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
169         * support/regression/tests/bug-1493710.c: added
170
171 2006-05-27 Borut Razem <borut.razem AT siol.net>
172
173         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
174           static instead auto
175         * support/regression/ports/pic16/support.c: increase stack size
176           from default 64 bytes to 128 bytes
177         * support/regression/tests/staticinit.c,
178           support/regression/tests/float.c: regression tests fully enabled
179           for pic16 port by putting the initialized data arrays into the code
180           section
181         * support/regression/ports/pic16/spec.mk: don't link default libraries.
182           This was changed by mistake in the previous version.
183
184 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
185
186         * src/pic16/gen.c (genFunction, genEndFunction): some
187         beautifications, fixed bug with falsely restoring FSR2 in large
188         stack model, thanks to Beau E. Cox for reporting the bug
189
190 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
191
192         * debugger/mcs51/break.c,
193         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
194           use %p to print pointers, made address variables unsigned
195         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
196         * debugger/mcs51/symtab.c (parseSymbol): must return something
197         * src/mcs51/gen.c (aopForSym): small optimization,
198            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
199           (freeAsmop): added missing break,
200           (aopPut): removed parameter bvolatile, determine it inside the function,
201           (saveRegisters, unsaveRegisters): small optimization,
202           (genIpush): removed pointless check,
203           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
204           replaced sprintf with SNPRINTF,
205           replaced strcpy with strncpyz,
206           updated aopPut calls,
207           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
208         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
209
210 2006-05-24 Borut Razem <borut.razem AT siol.net>
211
212         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
213           modification of test for the pic16 port, put the array to the code
214           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
215
216 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
217
218         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
219         * support/Util/pstdint.h: added
220
221 2006-05-22 Borut Razem <borut.razem AT siol.net>
222
223         * src/regression/Makefile: removed bool2.c test, added -q linker option
224         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
225           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
226           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
227           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
228           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
229           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
230           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
231           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
232           define SUPPORT_BIT_TYPES 0, removed unused bit variables
233
234 2006-05-22 Raphael Neider <rneider AT web.de>
235
236         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
237           bug #1492360 (problematic due to generic pointers, see code)
238
239 2006-05-22 Borut Razem <borut.razem AT siol.net>
240
241         * support/regression/ports/pic16/specs.mk: removed stack size linker
242           directive
243         * support/regression/tests/array.c,
244           support/regression/tests/bitopcse.c,
245           support/regression/tests/bug-908454.c,
246           support/regression/tests/malloc.c: modified for pic16 regression test
247         * support/regression/tests/bitfields.c:
248           pic16 - excluded bitfileds of size > 8
249         * support/regression/tests/bp.c: pic16 - reduced data size
250         * support/regression/tests/bug-221100.c: pic16 - reduced data size
251         * support/regression/tests/bug-460010.c:
252           pic16 - used the absolute address the fits in memory
253         * support/regression/tests/bug-716242.c:
254           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
255         * support/regression/tests/float.c:
256           pic16 - excluded - data size too big
257         * support/regression/tests/onebyte.c:
258           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
259         * support/regression/tests/shifts.c:
260           pic16 - function names probably have to differ in first X characters
261           (gpasm limitation?)
262         * support/regression/tests/staticinit.c:
263           pic16 - excluded some tests due error: no target memory available for
264           section ".idata"
265
266 2006-05-22 Borut Razem <borut.razem AT siol.net>
267
268         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
269           second try. Thanks Stas Sergeev once more.
270
271 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
272
273         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
274           (genLeftShift, genRightShift): fixed bug 1491627
275         * src/hc08/peeph.def (rules 7, 8.x): added
276         * support/regression/tests/shifts.c (ShiftLeftByParam,
277           ShiftRightByParam, testShiftByParam): added to test variable shifting
278
279 2006-05-20 Raphael Neider <rneider AT web.de>
280
281         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
282         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
283           (allocReg): add only new registers to dynAllocRegs,
284           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
285             #1489055, #1445850, and probably #1483693
286
287 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
288
289         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
290         bug in for-loop that didn't emit the last of CONFIG and ID registers
291
292 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
293
294         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
295           with offset
296         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
297           1489016, 1434401 and 1490124
298         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
299           1489016, 1434401 and 1490124
300
301 2006-05-17 Borut Razem <borut.razem AT siol.net>
302
303         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
304           thanks Stas Sergeev
305
306 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
307
308         * device/include/mcs51/P89c51RD2.h,
309         * device/include/mcs51/P89LPC901.h,
310         * device/include/mcs51/P89LPC922.h,
311         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
312
313 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
314
315         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
316         to fix missing stack pragma in compiled binary object file,
317
318 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
319
320         * support/packihx/configure.in,
321         * support/packihx/configure: removed warning, autoconf >= 2.5x can
322         determine sizeof basic types even while cross compiling
323
324 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
325
326         * src/avr/gen.c (aopop),
327         * src/ds390/gen.c (aopOp),
328         * src/hc08/gen.c (aopOp),
329         * src/mcs51/gen.c (aopop),
330         * src/pic16/gen.c (pic16_aopOp),
331         * src/pic/gen.c (aopOp),
332         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
333         if size of operand is smaller than spill location
334
335 2006-05-12 Borut Razem <borut.razem AT siol.net>
336
337         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
338           have to have CR/LF line endings even if they are checked out on *nix
339           or on WIN32 in cygwin binmode
340
341 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
342
343         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
344         * device/include/ds80c390.h: added sfr16 definitions
345         * src/ds390/gen.c,
346         * src/ds390/gen.h,
347         * src/ds390/main.c,
348         * src/ds390/ralloc.c,
349         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
350           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
351           bit returning functions
352         * support/regression/tests/sfr16.c: enabled test on ds390
353
354 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
355
356         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
357         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
358
359 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
360
361         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
362         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
363           (cl_address_space constructor): removed expensive initialization,
364           (cl_address_space::get_cell): extended for late initialization,
365           (cl_address_space::*): use late initialization,
366           (cl_address_decoder::activate): removed expensive initialization,
367           This reduced regression test running time by 25%
368
369 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
370
371         * packihx/,
372         * configure.in,
373         * configure,
374         * sdcc.dsw,
375         * Makefile.bcc,
376         * Makefile.in,
377         * support/packihx/Makefile.in,
378         * support/packihx/clean.mk,
379         * support/packihx/Makefile.bcc,
380         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
381
382 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
383
384         * src/SDCCval.c (valNot): fix for regression test failure
385           of not.c on big endian hosts
386
387 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
388
389         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
390
391 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
392
393         * device/lib/mcs51/Makefile.in: changed string comparison operator
394           to = for POSIX compliance; == is bash extension
395
396 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
397
398         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
399           kosmonaut_pirx
400
401 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
402
403         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
404         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
405         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
406         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
407         bug report #1478657,
408
409 2006-05-05 Borut Razem <borut.razem AT siol.net>
410
411         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
412           making the html
413
414 2006-05-02 Borut Razem <borut.razem AT siol.net>
415
416         * doc/Makefile.in: removed *.ind dependency since there is no rule to
417           create *.ind, which made make to fail if invoked with -j 2
418
419 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
420
421         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
422           Hubert Sack for patch 1479782
423
424 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
425
426         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
427
428 2006-05-01 Raphael Neider <rneider AT web.de>
429
430         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
431           (create_pic): store only prefix-free device name,
432           (init_pic): check for device names with "16" prefix,
433           (list_valid_pics),
434         * src/pic/device.h (struct PIC_device),
435         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
436             stored device name,
437         * device/include/pic/pic12f{635,675,629,683}.h,
438         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
439         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
440         * device/include/pic/pic16f505.h,
441         * device/lib/pic/libdev/pic16f505.c: removed
442         * device/include/pic/pic14devices.txt: added support for pic12f
443             devices, removed unsupported non 16-bit devices
444             [above changes provided by patch from Zik Saleeba]
445         * src/pic/*, src/pic16/*, device/include/pic16/*,
446           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
447
448 2006-05-01 Borut Razem <borut.razem AT siol.net>
449
450         * configure.in, configure, doc/Makefile.in:
451           sync with nightly build makefile - latex, dvipdf and dvips
452           not needed any more
453
454 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
455
456         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
457         in the library source
458
459 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
460
461         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
462
463 2006-04-28 Raphael Neider <rneider AT web.de>
464
465         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
466         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
467           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
468         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
469
470 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
471
472         * device/lib/pic/libdev/Makefile.in,
473         * device/lib/hc08/Makefile.in,
474         * device/lib/gbz80/Makefile.in,
475         * device/lib/z80/Makefile.in,
476         * device/lib/ds390/Makefile.in,
477         * device/lib/ds400/Makefile.in: added srcdir to include search path,
478         thanks to Borut for the bug report
479         * configure.in,
480         * configure: always create doc/Makefile independent from --enable-doc
481         * Makefile.in: always install from directory doc independent from
482         --enable-doc
483         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
484         removed
485         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
486         * doc/Makefile.in: install *.txt if present
487         * device/include/Makefile.in (install): added installation of pic/*.inc
488         and pic/*.txt files again, they were erroneously removed
489
490 2006-04-28 Raphael Neider <rneider AT web.de>
491
492         * src/pic/{gen.c,main.h,pcode.c},
493         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
494             concerning signedness with casts
495
496 2006-04-28 Raphael Neider <rneider AT web.de>
497
498         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
499             definition of an interrupt handler,
500         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
501             interrupt handler stuff from picglue() to separate routine,
502           (picglue): enabled definition of intr handlers in files w/o main()
503
504 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
505
506         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
507           compilation with MSVC 2005 Express Edition (VC8)
508
509 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
510
511         * device/lib/Makefile: fixed build of gbz80 lib
512
513 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
514
515         * support/regression/tests/bug-460010.c,
516         * support/regression/tests/bug-524691.c,
517         * support/regression/tests/bug-716242.c: removed conditional defines
518           that are already in testfwk.h
519
520 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
521
522         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
523           (AccAXRsh1): added, shift right by 1,
524           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
525            AccAXLrl1
526         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
527
528 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
529
530         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
531         remove cast to same type
532         * src/SDCCast.c (decorateType): fix for RFE 1475742,
533         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
534         * as/z80/Makefile,
535         * link/z80/Makefile: removed, they have moved to
536         Makefile.in files
537         * configure,
538         * configure.in: replaced duplicate message about ucsim by missing sdcpp
539         * install-sh: fix bug #1204398 by setting umask 0022
540         * device/lib/Makefile: separate build of z80 and gbz80 lib
541
542 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
543
544         Enabled VPATH feature: changed nearly all Makefiles (149 files).
545         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
546
547         One basic decision: e.g. src/clean.mk includes further files. In order
548         to make this work there are two solutions:
549         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
550           run configure on them. This way they can use
551           'include $(srcdir)/port-clean.mk'
552         - always include clean.mk by the Makefile at the same level. To avoid
553           that `make clean` tries to include and build Makefile.dep the
554           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
555           implemented, because now even `make uninstall` doesn't create
556           Makefile.in. clean.mk could be eliminated by pasting it in
557           Makefile.in.
558
559         * debugger/mcs51/Makefile.in: build own objects from library sources
560         (SLIB, SDCC) in current directory
561
562         * configure, configure.in: renamed --disable-device-lib-build in
563         --disable-device-lib; added --enable-doc, the required tools are
564         searched by configure; added result message; the toolchain for the
565         belonging ports are now only built, if the port is enabled.
566
567         * support/regression/*: all output is written in directory gen, because
568         the fwk and ports directories don't livet in the build tree using vpath
569
570         * doc/sdccman.lyx: renamed --disable-device-lib-build to
571         --disable-device-lib, added --enable-doc, added section VPATH
572
573         * sim/ucsim/configure.in,
574         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
575         z80 are enabled by default
576
577 2006-04-24 Raphael Neider <rneider AT web.de>
578
579         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
580             to config word, "pic14_"-prefixed some extern functions
581           (pic14_emitConfigWord): emit __config directive(s) if assignment to
582             config word has been found
583         * src/pic/device.h: added prototypes
584         * src/pic/pcode.c: added "pic14_"-prefix where needed
585         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
586             fixup
587         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
588             words,
589           (pic14emitRegularMap): ignore config words,
590           (pic14createInterruptVect): moved generating __config directives away
591           (picglue): have __config directives emitted
592
593 2006-04-24 Borut Razem <borut.razem AT siol.net>
594
595         * doc/Makefile: sync with nightly build makefile
596
597 2006-04-24 Raphael Neider <rneider AT web.de>
598
599         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
600             registers that have not been assigned proper liveranges,
601             fixes #1469504 and #1474602,
602           (pCodeRegOptimizeRegUsage): fixed typo in comment
603
604 2006-04-24 Borut Razem <borut.razem AT siol.net>
605
606         * device/examples/main8051.c: deleted - it was removed from CVS
607           24.mar.2000 and after that modified 18.feb.2001, so it reappered
608           after the transition to Subversion
609         * src/SDCCalloc.h: deleted - it was removed  from CVS
610           3.feb.2001 and after that modified 18.feb.2001, so it reappered
611           after the transition to Subversion
612         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
613           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
614           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
615           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
616
617 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
618
619         * as/asx8051.dsp: added mcs51/strcmpi.h
620         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
621         * as/hc08/aslink.h: updated lnksect prototype
622         * as/hc08/asm.h,
623         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
624         * as/hc08/asmain.c,
625         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
626           (newdot): handle A_ABS
627         * as/hc08/asout.c,
628         * as/mcs51/asout.c (outarea): output address
629         * as/hc08/lkaomf51.c,
630         * as/mcs51/lkaomf51.c: disabled unused array UsageType
631         * as/hc08/m08pst.c,
632         * as/mcs51/i51pst.c,
633         * as/z80/z80pst.c: "ABS" is not A_OVR
634         * as/hc08/lkarea.c (newarea): read a_addr,
635           (lnkarea): added codemap array, sort absolute areas to the front,
636            combine all GSINITx/GSFINAL,
637           (find_empty_space, allocate_space): new functions,
638           (lnksect): return next address, handle absolute sections
639         * as/mcs51/lkarea.c (newarea): read a_addr,
640           lnksect2 prototype changed,
641           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
642           (find_empty_space, allocate_space): new, factored out of lnksect2,
643           (lnksect2): return next address, handle absolute sections
644         * as/hc08/lkhead.c,
645         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
646         * as/hc08/lklibr.c (addfile, fndsym),
647         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
648           index out of range and detect both '\' and '/'
649         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
650         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
651           regression tests (ds390 cannot return bool yet)
652         * doc/sdccman.lyx: changed version number, document changed --no-peep,
653           document critical interrupts on z80, document changed SDCC define
654         * src/asm.c (_asxxxx_mapping): fixed .org directive,
655           (_a390_mapping): added .org directive
656         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
657           (genMultOneByte): fixed warnings
658         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
659           ones
660         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
661         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
662           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
663         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
664         * src/pic16/main.c: removed newReg prototype
665         * src/pic16/pcode.c,
666         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
667           warnings
668         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
669           ones
670         * src/pic16/ralloc.c
671         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
672           to fix warnings
673         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
674           from short to PIC_OPTYPE
675         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
676         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
677           optype from short to PIC_OPTYPE
678         * src/port.h: made int_size unsigned to fix warnings
679         * src/SDCC.y: fixed warning on MSVC
680         * src/SDCCicode.c (getArraySizePtr): return unsigned int
681         * src/SDCCopt.c (convertToFcall): fixed warnings
682         * src/SDCCsymt.h: removed double prototype for genSymName
683         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
684           offset int to fix warnings
685
686 2006-04-22 Borut Razem <borut.razem AT siol.net>
687
688         * doc/sdccman.lyx, */Makefile, */Makefile.in:
689           references to CVS replaced with Subversion
690
691 2006-04-21 Borut Razem <borut.razem AT siol.net>
692
693         * doc/sdccman.lyx, */Makefile, */Makefile.in:
694           references to CVS replaced with Subversion
695
696 2006-04-19 Borut Razem <borut.razem AT siol.net>
697
698         * src/version.awk: adapted for svn
699         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
700           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
701           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
702           /binutils-avr/etc/*.vi, *.jin: removed all properties
703           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
704
705 2006-04-19 Borut Razem <borut.razem AT siol.net>
706
707         * CVS to Subversion migration completed
708
709 2006-04-18 Borut Razem <borut.razem AT siol.net>
710
711         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
712           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
713
714 2006-04-17 Borut Razem <borut.razem AT siol.net>
715
716         * device/include/Makefile.in: added pic/*.inc to the installation
717
718 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
719
720         * support/regression/collate-results.py: fixed output in case of
721         a valdiag error
722         * support/regression/generate-cases.py: fixed splitting of pathnames
723         with dots
724         * as/hc08/lklibr.c (addfile),
725         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
726
727 2006-04-11 Raphael Neider <rneider AT web.de>
728
729         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
730         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
731         * src/pic16/pcode.c (assignValnums): fixed #1460578
732
733 2006-04-11 Raphael Neider <rneider AT web.de>
734
735         * device/lib/pic/libdev/*.c,
736         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
737           fixes #1468739, enables compilation in --std-c99 mode
738         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
739
740 2006-04-11 Raphael Neider <rneider AT web.de>
741
742         * src/pic/device.c (find_device): removed debug output
743           (list_valid_pics): enabled verbose listing of supported devices
744         * device/include/stdbool.h: define bool as char for pic14/16 as well
745
746 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
747
748         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
749
750 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
751
752         * .version: bumped version to 2.5.6
753         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
754
755 2006-04-06 Raphael Neider <rneider AT web.de>
756
757         * .version: bumped version to 2.5.6 (pic14 ABI changed)
758         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
759         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
760           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
761             pic14_constructAbsMap
762           (pic14printPublics): declare absolute global symbols as global
763           (pic14createInterruptVect),
764         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
765           (newReg): assume new registers unused, use correct name in
766             hashtable (reg->name instead of name), more debugLog output
767         * src/pic/device.h (PIC_device): added fields for verbose output
768         * src/pic/device.c: moved device definition to pic14devices.txt,
769             added routines for runtime parsing of pic14devices.txt,
770             added support for second config word
771         * src/pic/main.c (_process_pragma): removed #pragma maxram,
772           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
773           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
774           (_pic14_parseOptions): moved pCodeInitRegisters here
775           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
776         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
777           (pCodeInitRegisters): rewrapped comments, perpared new approach to
778             handling the pseudo stack
779         * device/lib/Makefile.in: ignore failures in objects-pic16,
780         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
781         * device/lib/pic/NEWS: document new dependency on picXXX.lib
782         * device/lib/pic/Makefile.subdir,
783         * device/lib/pic16/Makefile.subdir: improved clean rules
784         * device/lib/pic/libdev/: NEW, pic14 device libraries
785         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
786         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
787         * device/include/Makefile.in: create subdir and install pic14 headers
788         * device/include/pic/p16f_common.inc: removed unused declarations
789         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
790             PICs from inc2h.pl v1.6,
791             replaced BIT_AT macros with struct declarations
792         * device/include/pic/pic14devices.txt: definition of supported devices,
793             all above improvements contributed by Zik Saleeba, thanks
794         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
795         * support/scripts/sdcc.nsi: also install pic14 device libraries and
796             headers
797
798 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
799
800         * device/include/mcs51/c8051f410.h: added interrupt numbers,
801         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
802           thanks to Charles Olds
803
804 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
805
806         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
807
808 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
809
810         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
811         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
812         * support/regression/bug1464657.c: added, new test
813
814 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
815
816         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
817           version number
818
819 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
820
821         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
822           --no-peep and --peep-file <file> are used don't use default rules but
823           do use the <file>
824
825 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
826
827         * src/mcs51/gen.c (genCall): fixed bug 1457608
828
829 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
830
831         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
832         changes seem to cause (trigger?) problems with the build system.
833
834 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
835
836         * src/SDCCpeeph.c (operandsLiteral): new, added,
837           (callFuncByName): inserted operandsLiteral
838         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
839
840 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
841
842         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
843         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
844
845 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
846
847         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
848           implemented patch 1120823 Thanks to Willy De la Court (normal
849           interrupts need an interrupt number now if they are made critical),
850           and enabled nesting of critical functions though not for gbz80
851           (genCritical, genEndCritical): added functions
852           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
853         * src/z80/mappings.i: added "ei" to all mappings
854
855 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
856
857         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
858         submitted by the Debian SDCC maintainer Aurelien Jarno:
859         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
860         archive with gcc 4.1 on mips and wrote the patch"
861
862 2006-03-16 Raphael Neider <rneider AT web.de>
863
864         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
865           the left operand is shorter than the result (c* = lit-c* + int),
866           fixes bug #1450796
867         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
868           OP_SYMBOL
869
870 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
871
872         * src/.version: increased version number to 2.5.5
873         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
874         linking is done manually in pic16 port's _linkEdit,
875         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
876         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
877         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
878         allocate asmop as AOP_ACC,
879         (aopForRemat): added parameter 'bool result' in function declaration,
880         (pic16_aopGet): return AOP_ACC when accessing WREG,
881         (pic16_popGetTempReg): minor modification,
882         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
883         'pic16_allocWithIdx',
884         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
885         calling function in absolute addresses,
886         (genAssign): take into account AOP_ACC asmop,
887         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
888         * src/pic16/pcoderegs.c: some debug functions and lines added,
889         * src/pic16/ralloc.c (decodeRegType): added but commented out,
890         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
891         register too,
892         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
893         call to allocReg, not by manually allocating a new one,
894         (pic16_assignRegisters): now before going through the register
895         allocating functions mark all registers as free. This eliminates some
896         side effects resulting from peephole parser done earlier in the backbone
897
898 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
899
900         * src/SDCCicode.c (geniCodeLogic),
901         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
902
903 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
904
905         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
906           (genSend): bugfix, do not allocate and free twice,
907           (shiftRLong): handle partially overlapping aops
908         * support/regression/tests/bitopcse.c: fixed warning redefined idata
909
910 2006-03-08 Borut Razem <borut.razem AT siol.net>
911
912         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
913           for pic16
914
915 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
916
917         * support/regression/tests/bug1409955.c: new, added
918         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
919         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
920           (aopForSym, aopOp): increment asmop.allocated if reused,
921           (freeAsmop): decrement asmop.allocated and check for zero instead of
922           using asmop.freed,
923           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
924           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
925            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
926            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
927            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
928            genSignedRightShift, genRightShift, genDataPointerGet,
929            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
930            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
931             in reverse order from allocation,
932           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
933             added swappedLR to keep track
934         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
935           pdata & code for GCC, z80, gbz80 & hc08
936         * support/regression/tests/zeropad.c: moved defines to testfwk.h
937
938 2006-03-08 Raphael Neider <rneider AT web.de>
939
940         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
941
942 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
943
944         * device/include/mcs51/c8051f410.h: new SiLabs mcu
945         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
946         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
947
948 2006-03-06 Borut Razem <borut.razem AT siol.net>
949
950         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
951           made the linker quiet
952
953 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
954
955         * src/pic16/gen.c (genPcall): fixed bug #1443644
956         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
957         which dumps before the function entry point a data byte which represents
958         the number of the local variables used by the specified function, added
959         'xinst' for initial support for Extended Instruction Support,
960         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
961         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
962         port->fun_prefix anymore (may change later),
963         (genFunction, genEndFunction): do not store/restore local registers for
964         _main (this should take care the --main-return command line option in
965         the future),
966         (genOr): removed some legacy pic-port instructions,
967         * src/pic16/genarith.c (genAddLit): re-enabled old code because
968         performing operations with SFR's causes data to be written more than
969         once to each SFR. Perhaps SFRs should be handled in special cases...
970         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
971         pcode.h
972         * src/pic16/main.c (_process_pragma): stack bound checking did not take
973         into account for stack starting position,
974         (struct OPTIONS pic16_optionsTable): added command line argument
975         --extended or -y for Extended Instruction Support,
976         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
977         (deassignLRs): *** perhaps the most important change, old 'for' code
978         (commented out for reference), didn't account for some registers which
979         were left marked 'not free' after a pointer operation. The change
980         reduces register usage a lot in some cases
981
982 2006-03-04 Borut Razem <borut.razem AT siol.net>
983
984         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
985           _clean
986         * support/regression/tests/bug-524697.c: decreased array size for
987           mcs51 to fit into the internal RAM
988         * support/regression/Makefile.in: a little bit more verbose
989
990 2006-03-03 Borut Razem <borut.razem AT siol.net>
991
992         * support/regression/fwk/lib/testfwk.c,
993           support/regression/fwk/include/testfwk.h: introduced function
994           _prints(), nonrecursive _printn(), call _initEmu() from main()
995         * support/regression/ports/gbz80/support.asm,
996           support/regression/ports/ucz80/support.asm,
997           support/regression/ports/z80/support.asm,
998           support/regression/ports/ds390/support.c,
999           support/regression/ports/hc08/support.c,
1000           support/regression/ports/host/support.c,
1001           support/regression/ports/mcs51/support.c,
1002           support/regression/ports/xa51/support.c: added empty _initEmu()
1003           function
1004         * support/regression/ports/pic16/gpsim.cmd,
1005           support/regression/ports/pic16/spec.mk,
1006           support/regression/ports/pic16/support.c,
1007           support/regression/Makefile.in: added pic16 regression test
1008
1009 2006-03-01 Raphael Neider <rneider AT web.de>
1010
1011         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
1012           genConstPointerGet): use safe way of generating MOVFF to cover
1013             literals as well as registers, fixes bug #1440527
1014         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
1015             dereference
1016           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
1017             more correctly, fixes bug #1232186
1018           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
1019         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
1020             gplink guess the correct processor in more cases, applied patch
1021             from Till Riedel attached to and fixing bug #1436552
1022
1023 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1024
1025         * support/regression/tests/array.c: added, contains check for #1434401
1026         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
1027
1028 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
1029
1030         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
1031         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
1032         * device/include/mcs51/c8051f326.h,
1033         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
1034         * device/include/mcs51/c8051f000.h,
1035         * device/include/mcs51/c8051f018.h,
1036         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
1037           PCON_IDLE,PCON_STOP and added sfr16 definitions
1038
1039 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1040
1041         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
1042           genGetWord): fixed bug 1409955
1043
1044 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1045
1046         * device/include/hc08/mc68hc908gp32.h,
1047         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
1048
1049 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
1050
1051         * src/SDCCast.c (constExprValue): return NULL if not a value
1052         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
1053         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
1054         * support/regression/tests/bitfields.c: enabled signed bitfield for all
1055
1056 2006-02-13 Borut Razem <borut.razem AT siol.net>
1057
1058         * src/regression/ptrarg.c: added, fails due to bug #1430967
1059         * src/regression/Makefile: ptrarg.c added, ...
1060
1061 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1062
1063         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
1064         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
1065
1066 2006-02-11 Borut Razem <borut.razem AT siol.net>
1067
1068         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
1069           print "Processor: xxx" message to stdout only if --verbose
1070
1071 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1072
1073         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
1074         * support/regression/tests/bug1426356.c: added
1075         * support/regression/tests/bitfields.c: removed 2 tests
1076
1077 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
1078
1079         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
1080         * device/include/mcs51/c8051f330.h,
1081         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
1082           PCON_IDLE,PCON_STOP and added sfr16 definitions
1083         * device/lib/_divsint.c,
1084         * device/lib/_divuint.c,
1085         * device/lib/_divulong.c,
1086         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
1087           register bank bug for small stackauto
1088
1089 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
1090
1091         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
1092
1093 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
1094
1095         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
1096         * all.dsp: corrected several bin paths
1097         * device/include/mcs51/c8051f120.h,
1098         * device/include/mcs51/c8051f300.h,
1099         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
1100           to PCON_IDLE,PCON_STOP
1101         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
1102         * device/lib/printf_large.c (output_float): fixed bug 1388703
1103         * support/regression/tests/bug1057979.c: added test for bug 1388703
1104
1105 2006-02-08 Raphael Neider <rneider AT web.de>
1106
1107         * src/pic/pcode.c (pciTRIS): fixed typo,
1108           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
1109           (LinkFlow): fixed handling of flows that end in a call,
1110           (ReuseReg): perform safety check earlier
1111         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
1112             to work with flows at the beginning of a pBlock,
1113             fixes #1426557 (Symbol not previously defined),
1114           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
1115             usage information
1116           (RemoveUnusedRegisters): update register usage info
1117         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
1118             created, reuse existing ones instead
1119         * src/pic/gen.c (genPcall): fixed #1424719
1120
1121 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
1122
1123         * link/z80/lkmain.c,
1124         * link/z80/lklex.c,
1125         * link/z80/lkdata.c,
1126         * link/z80/aslink.h: fixed build on current cygwin:
1127         replaced getline() by lk_getline()
1128
1129 2006-02-01 Borut Razem <borut.razem AT siol.net>
1130
1131         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
1132           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
1133           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
1134           src/regression/bool1.c, src/regression/bool2.c,
1135           src/regression/bool3.c, src/regression/call1.c,
1136           src/regression/compare.c, src/regression/compare10.c,
1137           src/regression/compare2.c, src/regression/compare3.c,
1138           src/regression/compare4.c, src/regression/compare5.c,
1139           src/regression/compare6.c, src/regression/compare7.c,
1140           src/regression/compare8.c, src/regression/compare9.c,
1141           src/regression/configword.c, src/regression/for.c,
1142           src/regression/inline.c, src/regression/mult1.c,
1143           src/regression/nestfor.c, src/regression/or1.c,
1144           src/regression/pointer1.c, src/regression/ptrfunc.c,
1145           src/regression/rotate1.c, src/regression/rotate2.c,
1146           src/regression/rotate3.c, src/regression/rotate4.c,
1147           src/regression/rotate5.c, src/regression/rotate6.c,
1148           src/regression/rotate7.c, src/regression/string1.c,
1149           src/regression/struct1.c, src/regression/sub.c,
1150           src/regression/sub2.c, src/regression/switch1.c,
1151           src/regression/while.c, src/regression/xor.c,
1152           src/regression/create_stc, src/regression/simulate,
1153           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1154           regression tests
1155         * src/regression/gpsim_assert.h: added
1156
1157 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1158
1159         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1160         ((void (code *) (void)) 0) ();
1161         * as/hc08/aslex.c,
1162         * as/hc08/aslink.h,
1163         * as/hc08/asm.h,
1164         * as/hc08/asmain.c,
1165         * as/hc08/lkdata.c,
1166         * as/hc08/lklex.c,
1167         * as/hc08/lkmain.c,
1168         * as/mcs51/aslex.c,
1169         * as/mcs51/aslink.h,
1170         * as/mcs51/asm.h,
1171         * as/mcs51/asmain.c,
1172         * as/mcs51/lkdata.c,
1173         * as/mcs51/lklex.c,
1174         * as/mcs51/lkmain.c,
1175         * as/z80/aslex.c,
1176         * as/z80/asm.h,
1177         * as/z80/asmain.c: fixed build on current cygwin:
1178         replaced getline() by as_getline()
1179
1180 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1181
1182         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1183         declarator in the symbol chain
1184         * src/SDCCsymt.h,
1185         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1186         parameter list for function pointers
1187         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1188         * support/regression/tests/bug-716242.c: added
1189
1190 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1191
1192         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1193         offset if possible
1194         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1195
1196 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1197
1198         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1199         inifinitely recurseable, added static
1200         * support/regression/tests/bug-1408066.c: added
1201
1202 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1203
1204         * src/SDCCicode.h,
1205         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1206         renamed, added possibility to create "postLoopLbl"-labels
1207         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1208         newiTempLoopHeaderLabel
1209         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1210         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1211         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1212         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1213         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1214         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1215         (basicInduction): fixed bug #136564, made static,
1216         (loopInduction): changed parameter of basicInduction, made static,
1217         (addPostLoopBlock): added
1218         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1219         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1220         findLoopEndSeq
1221         * support/regression/tests/bug-136564.c: added
1222         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1223         --std-sdcc99 to LIBSDCCFLAGS
1224
1225 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1226
1227         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1228         while loop
1229         * support/regression/tests/bug-1406131.c: added
1230
1231 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1232
1233         * src/SDCCast.c (decorateType): fix promotion of unary minus
1234         * src/SDCCsymt.c (computeType): beautified
1235         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1236         (valUnaryPM, valComplement): fix sign and promotion,
1237         (valNot): ANSI: result type is int (SDCC: unsigned char)
1238         * support/regression/tests/uminus.c: speedup by removing superflous
1239         test case 'int'
1240         * support/regression/tests/onebyte.c: added promotion and signedness
1241         tests for unary minus
1242         * support/regressions/tests/bug-477927.c: disable warning about
1243         uninitialized variables
1244         * support/regression/tests/not.c: added
1245
1246 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1247
1248         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1249         * src/mcs51/gen.c (gen51Code): show final register usage after
1250         fillGaps in asm with --i-code-in-asm
1251         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1252         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1253         incUsed, rliveClear, adjustIChain): made static,
1254         (setFromRange): excluded because it's unused,
1255         (findPrevUseSym, markWholeLoop): added,
1256         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1257         through all branches of predecessors enables sdcc to emit the warning
1258         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1259         (rlivePoint): made static, added parameter emitWarnings which is only
1260         true during the first run out of two,
1261         (findRecursiveSucc, findRecursivePred): removed,
1262         (computeLiveRanges): made static, added parameter emitWarnings,
1263         (dumpIcRlive): added for debugging only
1264         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1265         removed prototype of setFromRange()
1266         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1267         in call of computeLiveRanges()
1268         * support/regression/tests/bug-895992.c: added
1269         * support/regression/tests/bug-971834.c: added
1270         * support/valdiag/tests/bug-895992.c: added
1271         * support/valdiag/tests/bug-971834.c: added
1272
1273 2005-12-18 Raphael Neider <rneider AT web.de>
1274
1275         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1276           (genUnpackBits): improved code for direct operands,
1277           (genPackBits): improved code for literal assignment to bitfields
1278             and for direct destination operands (no FSR indirection),
1279             prevented redundant AND, fixes #1362800,
1280           (AccLsh): added parameter to disable masking of the result
1281         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1282           skip instructions with side-effects (like incfsz),
1283           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1284         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1285         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1286           fixes #1375263
1287
1288 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1289
1290         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1291         volatile variables as spill location
1292
1293 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1294
1295         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1296         replacing literals
1297         * support/regression/tests/bug-1376320.c: added
1298
1299 2005-12-08 Raphael Neider <rneider AT web.de>
1300
1301         * src/pic/device.c: renamed is_shared to pic14_is_shared
1302         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1303         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1304           (is_valid_identifier): added for above workaround
1305
1306 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1307
1308         * device/lib/Makefile.in: fixed to enable port-specific-objects
1309         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1310           char, thanks Hubert Sack
1311         * doc/sdccman.lyx: documented --xstack-loc,
1312           elaborated a bit more on interrupts and pitfalls,
1313           removed "setjmp/longjmp unsupported",
1314           documented some unsupported C99 features
1315         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1316         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1317           if, thanks Hubert Sack
1318         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1319         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1320           make make_library
1321         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1322           regression tests can report resource usage (rfe 700441)
1323         * support/regression/collate-results.py: report resource usage
1324         * support/regression/ports/ds390/spec.mk,
1325         * support/regression/ports/hc08/spec.mk,
1326         * support/regression/ports/mcs51/spec.mk,
1327         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1328         * support/regression/ports/ds390/uCsim.cmd,
1329         * support/regression/ports/hc08/uCsim.cmd,
1330         * support/regression/ports/mcs51/uCsim.cmd,
1331         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1332         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1333           library, use the default one
1334         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1335           building the library
1336
1337 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1338
1339         * config.dsp: added dependency on .version and configure_vc.awk
1340         * device/include/setjmp.h: updated for --stack-auto and --xstack
1341         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1342         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1343         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1344         * device/lib/libsdcc.lib: added _setjmp
1345         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1346           (decorateType): fixed bug 1372851,
1347           (optimizeGetHbit): fixed warning
1348         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1349           array initialisation
1350         * support/regression/tests/bug1057979.c: added test for bug 1358192
1351         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1352
1353 2005-12-03 Borut Razem <borut.razem AT siol.net>
1354
1355         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1356           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1357
1358 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1359
1360         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1361         createIval): implement symbol independant "flexible array member",
1362         (createIvalCharPtr): implemented flexible array initialisation with a
1363         string
1364         * src/SDCCsymt.c (copyStruct): removed,
1365         (getSize): fixed misleading comment,
1366         (getAllocSize): removed, the additional allocation size is now in
1367         sym->flexArrayLength,
1368         (checkStructFlexArray): new, syntax checks for flexible array members,
1369         (compStructSize): added syntax checks for "flexible array members"
1370         (copyStruct): removed,
1371         (copyLinkChain): removed inefficient fix for bug 770487
1372         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1373         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1374         symbol->flexArrayLength
1375         * src/SDCCerr.c,
1376         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1377         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1378         * support/regression/tests/structflexarray.c: added
1379         * support/valdiag/tests/structflexiblearray.c: added
1380
1381 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1382
1383         * src/SDCCast.c (decorateType): fixed bug 1368489
1384         * support/Util/SDCCerr.c,
1385         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1386
1387 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1388
1389         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1390           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1391
1392 2005-11-27 Borut Razem <borut.razem AT siol.net>
1393
1394         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1395           support/cpp2/mkdeps.h: added command line option
1396           -obj-ext=<extension> to SDCPP to define object file externion, used
1397           for generation of make dependencies (-M)
1398         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1399
1400 2005-11-26 Borut Razem <borut.razem AT siol.net>
1401
1402         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1403           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1404           added pic and pic16 libraries
1405
1406 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1407
1408         * device/include/float.h: Corrected typo in prototype of __fsgt
1409
1410 2005-11-25 Borut Razem <borut.razem AT siol.net>
1411
1412         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1413           added creation of model-mcs51-stack-auto libraries
1414
1415 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1416
1417         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1418         and fields-list too
1419         * src/SDCCast.c (createIvalArray): removed obsolete comment
1420
1421 2005-11-24 Borut Razem <borut.razem AT siol.net>
1422
1423         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1424           added missing device/lib/mcs51/crt*.asm sources
1425
1426 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1427
1428         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1429
1430 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1431
1432         * device/lib/_fs2schar.c,
1433         * device/lib/_fs2sint.c,
1434         * device/lib/_fs2slong.c: optimized inline asm
1435
1436 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1437
1438         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1439           Better handling of floats between -1.0 and 0.0.
1440
1441 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1442
1443         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1444           (the missing "if"s prohibited removal of redundant labels)
1445
1446 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1447
1448         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1449           Properly convert floats between -1.0 and 0.0 to long, int, and char
1450           types (max integer value of negative floats tends to zero).
1451         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1452           Removed changes made so to work properly with floats between
1453           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1454           and _fs2char.c
1455
1456 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1457
1458         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1459         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1460         (genCast) cosmetic change
1461         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1462         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1463         from mcs51
1464         * support/regression/tests/bitfields (testSignedBitfields): added
1465
1466 2005-11-18 Borut Razem <borut.razem AT siol.net>
1467
1468         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1469         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1470           introduced SILENT option to make building of pic16 libraries less
1471
1472 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1473
1474         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1475           Now they work properly with floats between -1.0 and 0.0
1476         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1477
1478 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1479
1480         * src/SDCCicode.c (printOperand): added missing else
1481
1482 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1483
1484         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1485         reformatted for better readability
1486         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1487         signed bitfields
1488
1489 2005-11-17 Borut Razem <borut.razem AT siol.net>
1490
1491         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1492           introduced SILENT option to make building of pic16 libraries less
1493           verbose - used for nightly snapshot build
1494         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1495           available on Win32 platforms.
1496         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1497           medium, large, pic and pic16
1498
1499 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1500
1501         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1502           printf("%f"...) sets fraction to zero.
1503
1504 2005-11-16 Raphael Neider <rneider AT web.de>
1505
1506         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1507           fixes #1357221
1508         * src/pic/gen.c (genIfx): implemented for CARRY bit
1509         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1510           to generic pointers, fixes #1357332,
1511           (pic16_movLit2f): NEW,
1512           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1513
1514 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1515
1516         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1517
1518 2005-11-11 Raphael Neider <rneider AT web.de>
1519
1520         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1521         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1522           compute pointer's type from operand,
1523           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1524           improved single bit reads, fixes bug #1353379
1525
1526 2005-11-09 Borut Razem <borut.razem AT siol.net>
1527
1528         * support/scripts/sdcc.nsi: added lib/pic to the package
1529
1530 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1531
1532         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1533
1534 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1535
1536         * support/regression/tests/bug1348008.c: added
1537         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1538         * support/regression/tests/bug1337835.c: updated comment
1539
1540 2005-11-06 Borut Razem <borut.razem AT siol.net>
1541
1542         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1543           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1544           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1545           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1546           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1547           dynamic construction of cl_error_class and derivates - 2.nd try
1548
1549 2005-11-05 Borut Razem <borut.razem AT siol.net>
1550
1551         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1552           bug, which caused Bus Errors on sparc solaris
1553
1554 2005-11-04 Borut Razem <borut.razem AT siol.net>
1555
1556         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1557           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1558           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1559           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1560           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1561           and derivates to resolve the initialization problem on OSX
1562
1563 2005-11-02 Borut Razem <borut.razem AT siol.net>
1564
1565         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1566           corrected typo - #include <winsock2.h>
1567
1568 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1569
1570         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1571           (_asxxxx_mapping): added org directive for future enhancements
1572
1573 2005-11-01 Borut Razem <borut.razem AT siol.net>
1574
1575         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1576           enabled sockets on WIN32
1577         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1578
1579 2005-10-31 Borut Razem <borut.razem AT siol.net>
1580
1581         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1582           WIN32 backslash path delimiters should be escaped when used in C strings
1583         * support/regression/tests/bitfields.c: exclude failing assertions for
1584           __CYGWIN32__ and __MINGW32__ hosts
1585
1586 2005-10-30 Borut Razem <borut.razem AT siol.net>
1587
1588         * src/SDCCutil.c: corrected double comparison typo
1589
1590 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1591
1592         * device/lib/medium/Makefile: added for new memory model medium
1593         * device/include/asm/mcs51/features.h: updated for medium/pdata
1594         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1595           added Multiply & Accumulate sbit's and MAC0_PAGE define
1596         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1597         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1598         * device/lib/_mullong.c: update for medium model
1599         * device/lib/incl.mk: added medium model
1600         * doc/sdccman.lyx: documented medium model
1601         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1602         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1603         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1604         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1605           (allocParms): set SCLS and OCLS to pdata for medium model
1606         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1607           for pdata,
1608           (powof2): return <0 if not power of 2
1609         * src/avr/gen.c (genBitWise): use updated powof2
1610         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1611           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1612           (shiftLLeftOrResult): use B if necessary
1613         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1614         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1615         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1616         * support/regression/Makefile.in: added test-mcs51-medium
1617         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1618
1619 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1620
1621         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1622         specifier unsigned
1623         * device/lib/time.c (mktime): fixed bug 1334315
1624
1625 2005-10-28 Raphael Neider <rneider AT web.de>
1626
1627         * device/include/pic/p16f_common.inc: added common declarations
1628         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1629
1630 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1631
1632         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1633           (aopPutUsesAcc): added to predict accumulator use,
1634           (assignResultValue): save acc if necessary,
1635           (genMinusDec): store result if indirectly addressed,
1636           (genDivOneByte):  save acc if necessary,
1637           (movLeft2Result): bugfix if left already in acc,
1638           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1639             attention to accumulator use (esp. pdata),
1640           (genReceive): receive pdata correctly
1641         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1642         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1643
1644 2005-10-27 Raphael Neider <rneider AT web.de>
1645
1646         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1647
1648 2005-10-27 Raphael Neider <rneider AT web.de>
1649
1650         * .version: changed version to 2.5.4
1651         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1652         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1653           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1654             arithmetics support routines
1655         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1656         * device/lib/Makefile.in: also create installdir for pic
1657
1658         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1659           pic14 port as well
1660         * src/pic/device.c (dump_sfr): rewritten to delegate register
1661           placement to the linker (use `extern sym' rather than sym EQU addr),
1662           (validAddress): fixed to check last specified address
1663         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1664           (popGetLit): truncate literal value to 8 bit,
1665           (popGet): moved assert to more appropriate place
1666           (popGetExternal): create pCode operand from and mark the according
1667             symbol as being `extern'
1668           (popGetAddr): added sanity check on immediate's offset, provide
1669             GPOINTER tag on demand
1670           (aopPut): fixed for immediates,
1671           (mov2w_op): move operand's address or contents to WREG (depending on
1672             operand type), safer variant of mov2w,
1673           (movwf,call_libraryfunc): NEW, handy abbreviations,
1674           (get_argument_pcop,get_return_val_pcop,pass_argument,
1675           get_returnvalue): interface for accessing function parameters and
1676             return values,
1677           (assignResultValuei,genRet): use new parameter/return value interface
1678           (pic14_getDataSize): back to old version handling generic pointers,
1679           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
1680             provided implementation and/or fixed old one,
1681           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
1682             calls, removed legacy 8051 reference code
1683           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
1684           (loadSignToC): NEW, move the operands sign bit to CARRY,
1685           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
1686             genRightShiftSigned, accepts negative shift counts,
1687           (setup_fsr): load FSR and adjust IRP (indirect memory access),
1688           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
1689             generic pointers, __data pointers and __code pointers,
1690           (genUnpackBits,genPackBits): rewritten to work with generic pointers
1691             and signed bitfields, limit bitfields to 8 bit,
1692           (genDataPointerGet): fixed number of bytes read,
1693           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
1694           (genPointerGet,genPointerSet): fixed handling of __code pointers,
1695             pointers to constant data are no longer assumed to point to __code
1696             space, removed invalid pointer types,
1697           (bitpatternFromVal): retrieve the PICs representation of an integer
1698             or float literal,
1699           (genDataPointerSet): fixed assigning to po_immediate operands,
1700           (genGenPointerSet): implemented as library call,
1701           (genIfx): fixed incorrect condition,
1702           (genAddrOf): limit generic pointers' addresses to 2 bytes,
1703             provide GPOINTER tag according to destination's storage class,
1704           (genCast): added code to handle casting to generic pointers, added
1705             sign-/zero extension of the result
1706           (aop_isLitLike,op_isLitLike): fixed handling of immediates
1707         * src/pic/gen.h: added macros to access IRP bit in STATUS register
1708         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
1709           extend the result
1710         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
1711           address/register resides in the shared banks
1712           (emitSymbolToFile): improved to handle global and `pinned' symbols,
1713             put all variables into separate sections (have the linker arrange
1714             them)
1715           (picglue): put init code and interrupt handlers in separate sections
1716         * src/pic/main.c: added port specific options table, modified to PORT
1717           structure to make GPOINTERs 3 byte, added pic14_options
1718           (_pic14_do_link): private linking routine (update paths to libraries,
1719             add libsdcc.lib by default)
1720         * src/pic/main.h: declare pic14_options
1721         * src/pic/pcode.c: fixed instructions i/o relations,
1722           (RegCond): reverted to correct version,
1723           (newpCodeOpLit): truncate literals to 8 bit,
1724           (genericPrint): added debug output,
1725           (getRegFromInstruction): fixed for various operand types, simplified
1726           (BuildFlow): fixed broken handling of isntructions with labels
1727           (LinkFlow): start at last instruction in flow (skip trailing comments),
1728             pass the flow on to the next instruction after CALL
1729           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
1730           (insertPCodeInstruction): fixed inserting after a skip instruction,
1731           (DoBankSelect): fixed for labeled instructions
1732           (OptimizepBlock): honor --nopeep switch
1733           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
1734         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
1735         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
1736           (pCodeOptime2pCodes): allow disabling this optimization via
1737             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
1738             but is still buggy), started implementation of a dataflow based
1739             pCode optimization (CSE + dead code elimination)
1740           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
1741         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
1742           names are independant of the stack location and therefore portable across
1743           devices
1744
1745 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1746
1747         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
1748           (selectSpil): fixed bug 1337835 by not spilling bit variables
1749         * support/regression/tests/bug1337835.c: added test for this bug
1750         * src/mcs51/peeph.def: restart after rule 3.c,
1751           addded rules 263.x to optimize loading constants
1752
1753 2005-10-26 Raphael Neider <rneider AT web.de>
1754
1755         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
1756         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
1757           (genAssign): emit warning when casting literals to generic pointer
1758             type, also applies when taking the address of a fixed variable,
1759           (genCast): improved casting to generic pointers
1760         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
1761           extern variables, added verbose error message
1762         * device/include/pic16/{string.h,errno.h}: added #pragma library c
1763
1764 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
1765
1766         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
1767         carry must be complemented too
1768         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
1769         could be emitted by genMinus
1770         * src/SDCCval.c (constVal): fixed bug 1305065
1771
1772 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
1773
1774         * src/SDCCast.c (addCast): added promotion for bit variables
1775         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
1776         promotion casts + optimisation
1777         (optimizeGetWord): fix warning 'i' might be used uninitialized
1778         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
1779         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
1780
1781 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
1782
1783         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
1784         all chars are promoted to int; promotion should be handled in SDCCast.c
1785
1786 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1787
1788         * device/lib/_strcmp.c: Fixed bug 1326457
1789
1790 2005-10-11 Raphael Neider <rneider AT web.de>
1791
1792         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
1793         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
1794
1795 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
1796
1797         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
1798         * support/regression/tests/sfr16.c: added test for the sfr32 bug
1799
1800 2005-10-04 Raphael Neider <rneider AT web.de>
1801
1802         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
1803           device/lib/pic16/pics.all: added pic18f1320
1804         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
1805
1806 2005-09-30 Raphael Neider <rneider AT web.de>
1807
1808         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
1809         * src/pic16/devices.inc: NEW, provides device descriptions
1810         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
1811
1812 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
1813
1814         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
1815           GETHBIT
1816
1817 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
1818
1819         * doc/sdccman.lyx: updated Highest Order Bit documentation,
1820           documented Any Order Bit, Higher Order Byte and Higher Order Word
1821         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
1822         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
1823           (optimizeGetAbit): new, to get any bit, not only the high bit,
1824           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
1825           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
1826           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
1827           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
1828             RIGHT_OP: also try GETBYTE, GETWORD optimization,
1829             GETABIT, GETBYTE, GETWORD: decorate them,
1830           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
1831           (ast_print): added GETABIT, GETBYTE, GETWORD
1832         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
1833         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
1834           (geniCodeBinary): new generic binary icode,
1835           (ast2iCode): added GETABIT, GETBYTE, GETWORD
1836         * src/port.h: updated comment for PORT.hasExtBitOp
1837         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
1838           (genGetByte): new, to get a single byte,
1839           (genGetWord): new, to get a word from a long,
1840           (gen51Code): added GETABIT, GETBYTE, GETWORD
1841         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
1842
1843 2005-09-23 Raphael Neider <rneider AT web.de>
1844
1845         * configure.in, configure: have device/lib/pic configured
1846         * device/lib/Makefile.in: added model-pic14
1847         * device/lib/clean.mk: added pic/ to clean rule
1848         * device/lib/pic: added rudimentary pic14 library providing support
1849           functions for multiplication/division/generic pointer access
1850         * src/SDCCopt.c (convilong): mark support functions as extern
1851           for pic14 port as well
1852         * src/pic/gen.c (genMult): added assertions,
1853           (genpic14Code): emit warning on unhandled iCodes
1854         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
1855         * src/pic/pcode.c (pCodeOpCopy),
1856         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
1857           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
1858           SFR_REGISTER}), made safe for future extensions
1859         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
1860           instructions even if preceeded by SKIP instructions (also remove
1861           them); removed unused code
1862         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
1863           prevents leaving parts of the structure uninitialized after copying
1864
1865 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
1866
1867         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
1868           ago by me
1869         * support/regression/tests/addsub.c: added test for the bug
1870
1871 2005-09-21 Raphael Neider <rneider AT web.de>
1872
1873         * device/include/pic16/pic18f1220.h,
1874           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
1875         * device/lib/pic16/Makefile.rules: added missing opening paren
1876         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
1877           are provided in genutils.c,
1878           (genUminusFloat,genUminus,genCmpEq): added asserts on different
1879           operand/result sizes,
1880           (genCmp): assert on NULL pointers first, then check deref'ed values
1881         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
1882           result size
1883
1884 2005-09-18 Raphael Neider <rneider AT web.de>
1885
1886         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
1887           as these are now unused,
1888           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
1889         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
1890           local, avoids uninitialized pointer dereference on r->name
1891         * src/pic16/ralloc.c (newReg): fixed indentation
1892
1893 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
1894
1895         * src/SDCCval.c (constVal): fixed bug 730366
1896         * support/Util/SDCCerr.c,
1897         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
1898
1899 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
1900
1901         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
1902
1903 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
1904
1905         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
1906
1907 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
1908
1909         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
1910           (hex2dec): made hex_digit unsigned char, removed ascii dependance
1911         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
1912           (hex2dec): made hex_digit unsigned char, removed ascii dependance
1913         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
1914         * packihx/packihx.c (hexDigit): made c unsigned char
1915         * as/mcs51/lklibr.c (fndsym),
1916         * link/z80/lkgb.c (gb),
1917         * link/z80/lklibr.c (fndsym),
1918         * link/z80/lkrloc.c (relr),
1919         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
1920         * src/SDCC.lex (checkCurrFile, process_pragma),
1921         * src/SDCCglue.c (spacesToUnderscores),
1922         * src/SDCCmain.c (setParseWithComma, processFile),
1923         * src/asm.c (tvsprintf, printCLine),
1924         * src/avr/gen.c (emitcode, aopPut),
1925         * src/ds390/gen.c (emitcode),
1926         * src/hc08/gen.c (emitcode, emitinline),
1927         * src/mcs51/gen.c (emitcode, genInline),
1928         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
1929           tokenizeLineNode),
1930         * src/pic/ralloc.c (debugLog),
1931         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
1932           tokenizeLineNode),
1933         * src/pic16/ralloc.c (debugLog),
1934         * src/z80/main.c (_process_pragma):
1935            made all ctype.h function calls safe
1936         * src/SDCCopt.c: include math.h for fabs
1937         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
1938           and used them throughout the code to make ctype.h function calls safe
1939         * src/ds390/main.c (asmLineNodeFromLineNode),
1940         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
1941         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
1942            unsigned char*
1943         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
1944           (newpCodeAsmDir): made ctype.h function calls safe
1945         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
1946           pic16_emitcode):  made lbp unsigned char*
1947         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
1948           (pic16_newpCodeAsmDir): made ctype.h function calls safe
1949         * src/xa51/gen.c (emitcode),
1950         * src/z80/gen.c (_emit2): made lbp unsigned char*
1951         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
1952            char*
1953
1954 2005-09-05 Raphael Neider <rneider AT web.de>
1955
1956         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
1957           access bank splitpoint
1958
1959 2005-09-05 Raphael Neider <rneider AT web.de>
1960
1961         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
1962
1963 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
1964
1965         * .version: changed to version 2.5.3
1966         * doc/sdccman.lyx: changed version to 2.5.3,
1967           documented --codeseg and --constseg and pragma codeseg and constseg,
1968           documented bit parameters (reentrant) and bit returning
1969         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
1970            currFunc->recvSize, but is this ok for all ports?
1971           (ast2iCode): result of ~ on unsigned char must be cast to int for
1972            bool to work
1973         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
1974           function pointers in bit space
1975         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
1976           (processFuncArgs): call port.reg_parm() with reentrancy info
1977         * src/port.h,
1978         * src/avr/main.c,
1979         * src/ds390/main.c,
1980         * src/hc08/main.c,
1981         * src/pic/main.c,
1982         * src/pic16/main.c,
1983         * src/xa51/main.c,
1984         * src/z80/main.c: port.reg_parm prototype extended with
1985           "bool reentrant" parameter
1986         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
1987           options.stackAuto for allocating bit register parameters
1988         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
1989           (genSend): set BitBankUsed if it is,
1990           (selectRegBank): factored out of genCall for use in genPcall,
1991           (genCall): removed redundant dtype assignmen, use selectRegBank,
1992           (genPcall): handle returning in Carry properly, save in F0 if needed,
1993           (genReceive): handle bit register parameters
1994         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
1995           (mcs51_assignRegisters): enable bit registers for all reentrant
1996            functions and don't set BitBankUsed unconditionally
1997         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
1998         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
1999         * support/regression/tests/funptrs.c: added tests for BOOL and for return
2000
2001 2005-08-27 Borut Razem <borut.razem AT siol.net>
2002
2003         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
2004         ppc-osx (Darwin) does not support -u option. It seems that it is
2005         supported only on Linux - GNU cp
2006
2007 2005-08-25 Borut Razem <borut.razem AT siol.net>
2008
2009         * sim/ucsim/gui.src/serio.src/Makefile.in,
2010           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
2011           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2012           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
2013           install and strip, since the strip at /usr/ccs/bin should be used
2014           on solaris
2015
2016 2005-08-24 Borut Razem <borut.razem AT siol.net>
2017
2018         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
2019
2020 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
2021
2022         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
2023         ffffffffu
2024
2025 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
2026
2027         * as/mcs51/aslink.h: completed lkrloc.c prototypes
2028         * as/mcs51/lkmain.c (link_main): fixed warning
2029         * device/include/stdbool.h: ds390 has no advanced bit support yet
2030         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
2031         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
2032         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
2033           and updated their macros
2034         * src/SDCCval.c (constVal): updated comment for renamed b_long
2035
2036 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
2037
2038         * as/mcs51/asdata.c: changed ctype['['] to BINOP
2039         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
2040           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
2041           (oprio): set priority for '['
2042         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
2043            and adb_24_bit
2044         * as/mcs51/asm.h: added defines R_BIT and S_BIT
2045         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
2046         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
2047         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
2048           added overlayable BIT_BANK area
2049         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
2050           (summary2): explain 'T' in legenda
2051         * as/mcs51/lkrloc.c: replaced old K&R style,
2052           (relr): added R_BIT processing,
2053           (errmsg): added "Bit-addressable relocation error",
2054           (adb_bit): added for converting from byte- to bit-addressable space,
2055           (adb_24_bit): added for converting from byte- to bit-addressable space
2056         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
2057            used in reentrant functions now even as return value
2058         * device/lib/_gptrput.c (_gptrput): removed obsolete code
2059         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
2060           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
2061         * src/SDCCglobl.h: added indicator BitBankUsed
2062         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
2063            the bit registers b0-b7
2064         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
2065           (geniCodeCast): fixed bug 1263853,
2066           (geniCodeLogicAndOr): put result in bool or char,
2067           (geniCodeReceive): added parameter func for accessing the return type,
2068           (geniCodeFunctionBody): pass func to geniCodeReceive
2069         * src/SDCCmain.c: added indicator BitBankUsed
2070         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
2071         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
2072           (checkSClass): don't put automatic bool/bit on stack,
2073           (checkFunction): removed check on function cannot return bit
2074         * src/SDCCsymt.h: added newBoolLink prototype
2075         * src/mcs51/gen.c (rb1regs): added bit registers,
2076           (movc): created for assigning to carry,
2077           (pushReg, popReg): created for pushing registers,
2078           (sameRegs): check both AOP_REG and AOP_CRY types,
2079           (aopOp): handle bit registers,
2080           (aopPut): optimization no self-assign,
2081           (saveRegisters): push reg->base (bits) only once for bit registers,
2082            and use pushReg,
2083           (unsaveRegisters): pop reg->base only once and use popReg,
2084           (assignResultValue): added parameter func and return in carry for bits,
2085           (genIpush): optimization no reload in A if not changed,
2086           (genSend): bit parameters in reentrant functions are passed in bit
2087            registers by first assigning to bits in B, then save registers and
2088            copy B to bits,
2089           (genCall): handle returning in Carry properly, save it in F0 if needed,
2090           (genPcall): updated assignResultValue call, this is not safe yet for bit
2091            returning function !!!
2092           (genFunction): don't generate equ's for bit registers and use pushReg,
2093           (genEndFunction): take care of bit returning functions and use popReg,
2094           (genRet): return bit in Carry,
2095           (genIfx): optimize bit registers and other directly addressable bits,
2096           (genReceive): updated assignResultValue call
2097         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
2098           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
2099            registers when using stack-auto
2100         * src/mcs51/ralloc.c (_G): added allBitregs,
2101           (regs8051): added the bit registers,
2102           (createStackSpil): use macro IS_BIT,
2103           (getRegBit): added to allocate a bit register, else spill,
2104           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
2105           (updateRegUsage): factored out to ease stepping while debugging,
2106           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
2107            also allocate bit registers,
2108           (fillGaps): handle bit registers,
2109           (findAllBitregs): added to create bit vector with all bit registers,
2110           (mcs51_allBitregs): returns this bit vector,
2111           (mcs51_assignRegisters): when using stack-auto use bit registers for
2112            passing parameters and creating local variables
2113         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
2114
2115 2005-08-22 Borut Razem <borut.razem AT siol.net>
2116
2117         * device/lib/Makefile.in: replaced find option -or with -o
2118           to make it run on solaris
2119
2120 2005-08-22 Raphael Neider <rneider AT web.de>
2121
2122         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
2123           fixes #1265442 (crash on Solaris)
2124
2125 2005-08-20 Borut Razem <borut.razem AT siol.net>
2126
2127         * configure, configure.in: added tests for libsocket and libnsl libraries,
2128           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
2129           from support/regression/Makefile.in
2130         * support/regression/Makefile.in: added
2131         * device/lib/pic16/Makefile.common.in: force make to use bash shell
2132         * sim/ucsim/libtool: regenerated on sparc-solaris
2133         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2134           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
2135           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
2136           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
2137           sparc-solaris, which doesn't use GNU ld linker
2138         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
2139         * as/Makefile: find on sparc-solaris does not support -maxdepth option
2140
2141 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2142
2143         * src/mcs51/peeph.def: updated comments
2144
2145 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2146
2147         * device/lib/_gptrget.c,
2148         * device/lib/_gptrput.c: slightly shorter
2149         * doc/sdccman.lyx: incremented version
2150         * src/mcs51/peeph.def: moved peephole comments to the line of first
2151           change to better keep line correlation, reanimated 186.e
2152         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2153
2154 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2155
2156         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2157           David Saxton with quotes around file name.
2158
2159 2005-08-15 Borut Razem <borut.razem AT siol.net>
2160
2161         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2162           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2163           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2164           make tests run on x86_64 platform
2165
2166 2005-08-13 Raphael Neider <rneider AT web.de>
2167
2168         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2169           as it might be executed DURING a build (parallel make is wonderful)
2170
2171 2005-08-13 Raphael Neider <rneider AT web.de>
2172
2173         * device/lib/Makefile.in (port-specific-objects-pic16):
2174           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2175         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2176           dependency
2177         * device/lib/pic16/Makefile.rules: build subdirs before creating
2178           the library, removed builddir rule, create $(builddir) early in
2179           recurse rule, use empty recurse rule for leaf directories
2180         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2181           mkdir errors (race condition), removed duplicate suffix "hex"
2182           from clean rules
2183         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2184         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2185           prevents mkdir -p from aborting on Alpha
2186
2187 2005-08-12 Raphael Neider <rneider AT web.de>
2188
2189         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2190           db-statements in order to allow for arrays of pointers in code
2191           sections to be placed without interspersed 0-padding, fixes
2192           bug #1256215
2193         * (emitStatistics): fixed division by zero for pic18f1220
2194         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2195           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2196         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2197         * (pic16_pCodeConstString): keep track of already emitted string
2198           literals to prevent "duplicate definitions of symbol _str_NR"
2199         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2200           debug message
2201         * device/lib/Makefile.in: ignore failing PIC16 library builds
2202         * device/lib/pic16/Makefile: do not build if gputils are missing
2203         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2204
2205 2005-08-10 Raphael Neider <rneider AT web.de>
2206
2207         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2208           my last commit)
2209
2210 2005-08-10 Raphael Neider <rneider AT web.de>
2211
2212         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2213           Rokas' patch to add the new fixed point type "__fixed16x16"
2214         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2215           functions for __fixed16x16 arithmetics
2216         * device/lib/pic16: reimplemented the build system to support
2217           a separate build directory, better handling of libio (create
2218           the library in a separate subdir for each architecture) and
2219           easier configuration (centralized in Makefile.common)
2220
2221 2005-08-07 Raphael Neider <rneider AT web.de>
2222
2223         * src/pic16/gen.c (genrshTwo): fixed sign extension
2224         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2225         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2226           added T0CONbits
2227         * device/include/pic16/pic18f4220.h: NEW, header for
2228           pic18f4220 and pic18f4320
2229         * device/include/pic16/pic18fregs.h: added new devices,
2230           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2231         * device/include/pic16/signal.h: resolved name clashes
2232           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2233           to also allow testing for interrupt enable bits, added
2234           comments on how to use the macros
2235         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2236         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2237           register definitions for the devices
2238         * device/lib/pic16/pics.all: added new devices
2239         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2240           allocated memory
2241         * device/lib/pic16/libc/stdlib/memfree: do not count
2242           the block header as free memory
2243         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2244           simplified and added missing end-of-blocklist-marker
2245           (reported by Peter Onion, fixes #1252814)
2246         * (_mergeHeapBlock): fixed loop condition
2247         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2248           len==0, restructured code
2249         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2250           up a bit, reduced bitfield accesses, prevent endless loops
2251           in case of heap corruption
2252         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2253           "unreferenced arguments/must return a value" warnings
2254         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2255           replaced BAUDREG with SPBRG
2256         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2257           device/lib/pic16/debug/gstack/gstack.c: replaced
2258           _naked, _asm, _endasm with __naked, __asm, __endasm
2259
2260 2005-08-05 Raphael Neider <rneider AT web.de>
2261
2262         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2263           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2264
2265 2005-08-05 Borut Razem <borut.razem AT siol.net>
2266
2267         * device/lib/Makefile.in: added missing ';'
2268         * configure: removed ^M characters
2269
2270 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2271
2272         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2273           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2274           License
2275
2276 2005-08-04 Borut Razem <borut.razem AT siol.net>
2277
2278         * configure.in: pic16 libraries build 2nd try - enable running
2279           configure in device/lib/pic16
2280         * configure: regenerated from configure.in
2281         * device/lib/Makefile.in: create $(PORT)/bin directory
2282
2283 2005-08-03 Raphael Neider <rneider AT web.de>
2284
2285         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2286           to get/set values via pointers
2287         * (genUnpackBits,genPackBits): changed detection of
2288           ptr->bitfield vs. sym.bitfield, fixed access via generic
2289           pointers, removed dead (wrong) code for multibyte bitfields
2290         * (genNearPointerGet, genGenPointerGet): removed useless code,
2291           fixed bitfield detection, fixes #1250594
2292         * (genNearPointerSet): removed useless code
2293         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2294           and introduced macro pic16_emitpcode that conditionally emits
2295           the origin of the following pCode (useful for debugging SDCC)
2296         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2297         * (createDefmap): fixed handling of LFSR for --optimize-df
2298
2299 2005-08-02 Borut Razem <borut.razem AT siol.net>
2300
2301         * device/lib/Makefile.in: pic16 libraries build enabled since
2302           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2303
2304 2005-08-02 Raphael Neider <rneider AT web.de>
2305
2306         * src/pic16/gen.c (genPackBits): removed deprecated warning
2307         * (genGenPointerSet): fixed bitfield detection
2308
2309 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2310
2311         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2312
2313 2005-07-31 Raphael Neider <rneider AT web.de>
2314
2315         * device/lib/pic16/libdev/pic18f458.c,
2316           device/include/pic16/pic18f458.h: added missing T0CONbits
2317
2318 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2319
2320         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2321
2322 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2323
2324         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2325
2326 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2327
2328         * device/include/mcs51/at89c51ed2.h: added.
2329
2330 2005-07-23 Raphael Neider <rneider AT web.de>
2331
2332         * src/pic/gen.h: added emitpcode macro for debugging
2333         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2334           and replace by macro adding debug information on demand
2335         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2336         * (gencjne): tried to fix; replaced with correct (slower) code
2337         * (gen{Unp,P}ackBits): fixed single bit access
2338         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2339         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2340           previous instruction
2341         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2342           register has to be handled with care (forbidding movement
2343           of assignments/uses, removing assignments completely, ...)
2344         * (pCodeOptime2pCodes): make use of regIsSpecial
2345         * added lots of debugging output (commented out)
2346         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2347           from being reused as result UNLESS it is known to work
2348
2349 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2350
2351         * support/Util/dbuf.h: include <stddef.h> for size_t
2352         * .version: changed to version 2.5.2
2353
2354 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2355
2356         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2357
2358 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2359
2360         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2361           (genModOneByte): removed needless psha/pula
2362
2363 2005-07-22 Raphael Neider <rneider AT web.de>
2364
2365         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2366           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2367         * src/pic/gen.c (resolveIfx): do not "invent" labels
2368         * (genSkipc): changed to positive logic
2369         * (genSkipCond): removed as no longer needed
2370         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2371           backport from PIC16
2372         * (genLeftShift): check operands are in different registers
2373         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2374           INCF does not update CARRY...
2375         * src/pic/main.c: fixed _linkCmd
2376         * src/pic/pcode.c (unlinkpCode): added inactive code
2377         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2378           alive (do not assign result and operand overlapping registers)
2379
2380 2005-07-22 Raphael Neider <rneider AT web.de>
2381
2382         * src/pic/device.c (dump_sfr): replaced register declaration with
2383           call to emitSymbolToFile() to avoid duplicate symbols
2384         * (assignRelocatableRegisters): do not declare external symbols
2385         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2386           right (take size of type, not etype)
2387         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2388         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2389         * (packRegsForAccUse): disabled assignment of WREG as
2390           the result reg to prevent occurence of just fixed #1235003,
2391           fixes #1242954
2392         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2393           symbols (avoids duplicate symbols in .asm file)
2394         * (pic14emitRegularMap): use emitSymbolToFile()
2395         * src/pic/gen.c (aopOp): fixed spillLocation handling
2396         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2397         * (genDataPointerSet): removed unneccessary variables/output
2398
2399 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2400
2401         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2402         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2403
2404 2005-07-21 Raphael Neider <rneider AT web.de>
2405
2406         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2407           architecture cannot handle them efficiently, fixes bug #1235003
2408         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2409           check for empty sets before using them (fixes bug #1232190)
2410
2411 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2412
2413         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2414           (lnksect2): generate warnings for memory overlap
2415         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2416           constseg to set the name of these segments so you can instruct the linker
2417           to place them in banks
2418         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2419         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2420           added code_seg and const_seg to options
2421         * src/SDCCglue.c (emitMaps): use options.const_seg,
2422           (createInterruptVect): put interrupt vectors in segment HOME,
2423           (glue): put HOME before static segment and put the main glue in HOME,
2424           (glue): use options.code_seg
2425         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2426         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2427           these segments so you can instruct the linker to place them in banks
2428           (linkEdit): use code_loc for HOME segment which should be the first
2429           segment in code memory now
2430         * src/SDCCmem.c: fixed more stuff like bug 1238386
2431         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2432           (changePointer): don't change function pointers to code pointers for
2433           banked functions,
2434           (compareType): added exceptional check for banked function pointers
2435         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2436         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2437           after static in code memory
2438         * src/mcs51/gen.c: added aopLiteralLong prototype,
2439           (aopForSym): use getSize for functions,
2440           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2441           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2442           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2443           the segment,
2444           (genPcall): use call for literal function pointers and generate banked
2445           calls over the one trampoline so there's only one place for the user to
2446           modify according to his/hers hardware,
2447           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2448           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2449         * src/mcs51/main.c: added keyword banked,
2450           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2451         * support/Util/SDCCerr.c,
2452         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2453           needed for passing the bank and address to the trampoline
2454         * device/lib/mcs51/crtbank.asm: added for bankswitching
2455         * device/lib/mcs51/Makefile: added crtbank
2456
2457 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2458
2459         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2460           for fields at offset 0 of a struct or union as reported
2461           on 2005-07-07 in the developer mailing list.
2462
2463 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2464
2465         * src/SDCCmem.c: fixed bug 1238386
2466
2467 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2468
2469         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2470           (patch #1144962), added peephole 300, enabled 259.x
2471         * doc/sdccman.lyx: removed screenshot and provided link instead
2472
2473 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2474
2475         * doc/sdccman.lyx: added section about debugging with ddd
2476         * doc/figures/ddd_example.eps: screenshot of debugging session
2477
2478 2005-07-04 Raphael Neider <rneider AT web.de>
2479
2480         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2481           like CODE pointers, fixes #1115683
2482         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2483           call, fixes bugs #1232211, #1228110,
2484           fixed wrong casts to pCodeFlow from pCodeInstructions
2485
2486 2005-07-04 Raphael Neider <rneider AT web.de>
2487
2488         * src/pic/gen.c (popGet): changed assert to allow for
2489           bit operands
2490         * (popGetAddr): changed signature to provide
2491           an additional index, patched all call sites
2492         * (genCmpEq): handle literal-like operands correctly
2493         * (genAddrOf): added sanity checks on __code/__data pointers
2494         * (genAssign): added handling of symbols from __code section
2495         * (gencjne): do not generate code for comparisons whose result
2496           is neither stored nor used, fixes bug #1171114
2497         * (AccLsh, AccRsh): operate on operand instead of WREG
2498         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2499           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2500           by known count
2501         * rewrote complete shift-by-literal logic, commented unused
2502           functions out
2503         * (genConstPointerGet): get multiple bytes (if result size > 1),
2504           fixed handling of non-immediate addresses
2505         * (genPointerGet): handle CODE pointers like CONST pointers
2506         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2507         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2508           operand is to be treated as a literal or not
2509         * (mov2w,genPcall,genCmpEq),
2510           src/pic/genarith.c: use aop_isLitLike() to decide between
2511           literal/register contents
2512         * (addSign): added missing offset
2513         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2514           only emit comment in debug-mode,
2515           use {aop,op}_isLitLike throughout the file
2516         * src/pic/glue.c: fix initializers for pointers (work in progress)
2517         * src/pic/pcode.c (get_op): honor index on _const symbols
2518         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2519         * (dumppBlock): added pCode size estimation
2520         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2521           check for IS_SYMOP before OP_SYMBOL'ing
2522         * fixed indentation, compacted switch-statements
2523         * (allocReg): find free register and allocate it instead of
2524           allocating new registers all the time
2525         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2526           registers as its operands (necessary only for multibyte GETs)
2527
2528 2005-07-01 Raphael Neider <rneider AT web.de>
2529
2530         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2531           debugging .asm-output macros FENTRY + FEXIT
2532         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2533           way... I wonder...
2534         * (emitpComment): NEW, printf to pCode
2535         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2536           offset handling
2537         * (popGetAddr): NEW, variant of popGet to access an immediates
2538           high(er) bytes instead of the n'th byte of memory they reference,
2539           replaced popGet with popGetAddr where neccessary
2540         * (genDataPointerGet): reactivated and fixed implementation
2541         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2542           accesses
2543         * (genDataPointerSet): fixed multibyte assignments
2544         * (genpic14Code): fixed --i-code-in-asm handling
2545         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2546         * (genPlus): fixed index-out-of-bounds error
2547         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2548         * src/pic/ralloc.c: added debugging output macro FENTRY2
2549         * (spillThis): fixed indentation, enbraced for-body for clarity
2550         * (rematStr): commented out as now unused
2551         * (regTypeNum): commented out special spill case (overwrites
2552           arbitrary values)
2553         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2554
2555 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2556
2557         * doc/sdccman.lyx: documented sfr16/sfr32,
2558           added example for using storage class with function pointers
2559         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2560
2561 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2562
2563         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2564         * device/lib/_itoa.c,
2565         * device/lib/_ltoa.c: optimized codesize
2566         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2567           but don't know how to suppress the double warning.
2568         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2569         * support/Util/SDCCerr.c,
2570         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2571
2572 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2573
2574         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2575           fixed old K&R prototypes
2576         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2577         * device/lib/_gptrget.c,
2578         * device/lib/_gptrgetc.c,
2579         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2580           also new versions for small generic pointers and banked generic pointers
2581         * src/port.h: added const_name
2582         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2583         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2584         * src/SDCCcse.c (findPrevIc): check all associative operators
2585         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2586         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2587         * src/SDCCmem.c: updated comments,
2588           set far-space to 0 for pdata, results in optimized code
2589         * src/SDCCmem.h: added macro CONST_NAME
2590         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2591           moving the info into the highest bits, see also gptrget/gptrput
2592         * src/src.dsp: added sdcc.ico to project files
2593         * src/avr/gen.c (genCast): fixed bug 0x%d
2594         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2595         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2596           relation between ptr_type and DCL_TYPE,
2597           (genCast): fixed bug 0x%d
2598         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2599           (CODE)" for const_name
2600         * src/hc08/gen.c (genCast): fixed bug 0x%d
2601         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2602           (hc08_port): added "CONST (CODE)" for const_name
2603         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2604           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2605           between ptr_type and DCL_TYPE,
2606           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2607           operand* and took AOP() inside function so sfr-ness can be checked,
2608           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2609           new prototype,
2610           (genFunction, genEndFunction): optimized stack setup,
2611           (genMinus): optimized for literals with ending zeroes (in bytes),
2612           (genCast): fixed bug 0x%d
2613         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2614           (mcs51_port): added "CONST (CODE)" for const_name
2615         * src/mcs51/peeph.def: made rule 226 more generic
2616         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2617         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2618         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2619         * src/z80/main.c (z80_port): added NULL for const_name,
2620           (gbz80_port): added NULL for const_name
2621         * support/regression/tests/bug663539.c,
2622         * support/regression/tests/sfr16.c: new tests
2623
2624 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2625
2626         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2627
2628 2005-06-24 Raphael Neider <rneider AT web.de>
2629
2630         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2631           corrected typos...
2632         * device/include/pic16/signal.h: added USBIF
2633           and SIG_USB
2634
2635 2005-06-24 Raphael Neider <rneider AT web.de>
2636
2637         * device/lib/pic16/libdev/pic18f2455.c,
2638           device/include/pic16/pic18f2455.h: NEW
2639         * device/include/pic16/pic18fregs.h,
2640           device/lib/pic16/pics.all,
2641           src/pic16/device.c: added 18f2455
2642         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2643           device/include/pic16/{pic18f[68][567].h,usart.h}:
2644           replaced MULTIPLE_USARTS define with more relaible
2645           compatibility sfrs (for USART access)
2646
2647 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2648
2649         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2650           and the output asm file line is printed on two lines.
2651
2652 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2653
2654         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2655           BGT, BLE, BHI, and BLS instructions
2656         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2657           genCmpEq): removed
2658         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2659           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2660           fixes bug #1216342
2661         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2662
2663 2005-06-15 Raphael Neider <rneider AT web.de>
2664
2665         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2666         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2667         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2668           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2669           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2670
2671 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2672
2673         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2674           Marcel Telka in bug #1215704
2675
2676 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
2677
2678         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
2679           located in shared memory bank.
2680
2681 2005-05-31 Raphael Neider <rneider AT web.de>
2682
2683         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
2684           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
2685           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
2686
2687 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
2688
2689         * device/lib/_strncpy.c: fixed the fix
2690
2691 2005-05-26 Raphael Neider <rneider AT web.de>
2692
2693         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
2694           initializers with \0, bug #1208187
2695         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
2696           intializers with \0, bug #1208187
2697
2698 2005-05-26 Raphael Neider <rneider AT web.de>
2699
2700         * src/pic16/glue.c (pic16_printIvalChar): fixed string
2701           initializers with \0, bug #1208187
2702         * src/pic16/main.c (_process_pragma): added sanity checks
2703           for stack position and size, emit warnings when appropriate
2704
2705 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
2706
2707         * device/lib/_strncpy.c: fixed not filling with \0
2708
2709 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2710
2711         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
2712           createFunction),
2713         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
2714           compound_statement),
2715         * src/SDCCsymt.h,
2716         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
2717
2718 2005-05-24 Raphael Neider <rneider AT web.de>
2719
2720         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
2721
2722 2005-05-24 Raphael Neider <rneider AT web.de>
2723
2724         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
2725           TRISE definitions, closes bug #1162453
2726
2727 2005-05-22 Raphael Neider <rneider AT web.de>
2728
2729         * src/pic16/main.c (_process_pragma): check for missing
2730           arguments to pragmas code and udata
2731         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
2732           consistency fixes to match other headers (thanks to Jim Paris)
2733         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
2734
2735 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
2736
2737         * src/SDCCicode.c (isOperandEqual): fixed missing ;
2738
2739 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
2740
2741         * support/regression/tests/bug1198642.c: new test
2742         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
2743         * src/SDCCcse.c (findPrevIc): added comment, please have a look
2744         * support/scripts/resource.h,
2745         * support/scripts/resource.rc,
2746         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
2747         * support/scripts/sdcc.ico: added 32x32 icon
2748
2749 2005-05-18 Raphael Neider <rneider AT web.de>
2750
2751         * device/lib/pic16/libdev/pic18f*.c,
2752         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
2753           keywords to "__sfr" and "__at (X)"
2754         * device/include/pic16/pic18fregs.h: added pic18f4520
2755         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
2756           #1203088 (MPLAB compatibility)
2757
2758 2005-05-17 Raphael Neider <rneider AT web.de>
2759
2760         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
2761         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
2762         * device/lib/pic16/pics.all: added new devices
2763         * src/pic16/device.c: added support for pic18f4520
2764
2765 2005-05-16 Raphael Neider <rneider AT web.de>
2766         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
2767         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
2768         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
2769           convenience function for bit access
2770
2771 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2772
2773         * device/lib/printf_large.c: fixed bug 1193299
2774         * support/regression/tests/bug1057979.c: added test %3.3s
2775
2776 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2777
2778         * device/include/mcs51/8051.h,
2779         * device/include/mcs51/8052.h: made parseable with lint
2780         * device/include/mcs51/lint.h: added include file for (sp)lint
2781         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
2782         * doc/cdbfileformat.lyx,
2783         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
2784
2785 2005-05-14 Raphael Neider <rneider AT web.de>
2786
2787         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
2788         * device/lib/pic16/libc/stdlib/itoa.c (new)
2789         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
2790         * device/lib/pic16/libio/Makefile: exclude subdir according to
2791           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
2792         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
2793         * src/pic16/gen.c (genFunction): prevent annoying warning
2794         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
2795           nameclashes on BeOS
2796         * support/cpp2/cppmain.c (cpp_output_string): new
2797         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
2798           fixes bug 1116802
2799
2800 2005-05-13 Borut Razem <borut.razem AT siol.net>
2801
2802         * src/SDCCmain.c (linkEdit): fixed bug 1195202
2803
2804 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2805
2806         * .version: changed to version 2.5.1; back to bleeding edge development
2807
2808 2005-05-11 Borut Razem <borut.razem AT siol.net>
2809
2810         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
2811           generate PDF version 1.3 documents
2812
2813 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2814
2815         * .version: changed to version 2.5.0
2816
2817 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2818
2819         * doc/sdccman.lyx: updated weblinks, index and smaller updates
2820
2821 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2822
2823         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
2824         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
2825         well as many smaller updates.
2826         * .version: changed to version 2.5.0-pre1
2827
2828 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2829
2830         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
2831
2832 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2833
2834         * support/regression/tests/bug1185672.c: added
2835         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
2836           bug 1185672
2837         * src/mcs51/gen.c (genCall): added comments, made it look safer
2838         * src/mcs51/gen.c (genEndFunction): simplified
2839
2840 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
2841
2842         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
2843
2844 2005-04-14 Borut Razem <borut.razem AT siol.net>
2845
2846         * fixed bug 1045046 - SIGSEGV with really simple code?:
2847           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
2848           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
2849
2850 2005-04-14 Borut Razem <borut.razem AT siol.net>
2851
2852         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
2853           src/pic16/device.h: temporarily disabled experimental #inline pragma
2854           for 2.5.0 release
2855
2856 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
2857
2858         * device/include/z80/stdio.h,
2859         * device/include/z80/string.h: removed these highly incomplete files so
2860           SDCC can use the default ones in device/include/
2861
2862 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2863
2864         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
2865         gcc warning.
2866         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
2867         fix sdcpp warnings.
2868
2869 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
2870
2871         * device/include/malloc.h: removed redundant __reentrant prototypes
2872         * device/lib/_mullong.c: added working xstack variant in asm (C version
2873           doesn't pass regression tests)
2874         * device/lib/bpx.c: used __data and made bpx char for mcs51
2875         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
2876           (createFunction): fixed bug with xstackPtr
2877         * src/SDCCcse.c: corrected comments
2878         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
2879           (killDeadCode, eBBlockFromiCode): removed unused code
2880         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
2881           corrected comments
2882         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
2883           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
2884           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
2885           (genModOneByte): fixed warning in MSVC
2886         * src/mcs51/main.c (): added comments
2887         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
2888
2889 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
2890
2891         * src/SDCCmain.c (linkEdit): oops, changed one line too many
2892
2893 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
2894
2895         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
2896
2897 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
2898
2899         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
2900         characters arrays of larger size than the declared one.
2901
2902 2005-04-10 Borut Razem <borut.razem AT siol.net>
2903
2904         * src/pic/gen.c (genInline),
2905           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
2906           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
2907           (findNextInstruction), (findPrevInstruction),
2908           (findInstructionUsingLabel),
2909           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
2910         * src/pic/pcode.c (findLabel): added missing '\n'
2911         * src/src.dsp: added SDCCdwarf2.c to the project
2912
2913 2005-04-09 Borut Razem <borut.razem AT siol.net>
2914
2915         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
2916
2917 2005-04-08 Raphael Neider <rneider AT web.de>
2918
2919         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
2920           into the chain after a given one) and mergeDefmapSymbols (combine
2921           defmap entries for each symbol per pcode)
2922         * (createDefmap): have defmap entries merged in the end
2923         * (defmapReplaceSymRef): split defmap entries covering two accesses to
2924           a symbol before replacing one access type's symbol, merge symbols in
2925           the end (replacement symbol might already have an entry)
2926         * (assignValnums): keep reference to written WREG intact
2927
2928 2005-04-08 Raphael Neider <rneider AT web.de>
2929
2930         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
2931           Alpha)
2932
2933 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
2934
2935         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
2936         bytes
2937
2938 2005-04-07 Raphael Neider <rneider AT web.de>
2939
2940         * device/include/pic16/usart.h: added compatibility defines for
2941           devices with more than one USART
2942         * device/include/pic16/pic18f[68][567]20.h: activated above defines
2943
2944 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2945
2946         * device/lib/Makefile.in: updated for port specific include
2947
2948 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2949
2950         * support/regression/ports/mcs51/spec.mk: added mcs51 include
2951
2952 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
2953
2954         * device/include/8051.h,
2955         * device/include/8052.h,
2956         * device/include/at89S8252.h,
2957         * device/include/at89c55.h,
2958         * device/include/at89x051.h,
2959         * device/include/at89x51.h,
2960         * device/include/at89x52.h,
2961         * device/include/mcs51reg.h,
2962         * device/include/reg51.h,
2963         * device/include/reg764.h,
2964         * device/include/regc515c.h,
2965         * device/include/sab80515.h: (re)moved these 12 files
2966         * device/include/mcs51/8051.h,
2967         * device/include/mcs51/8052.h,
2968         * device/include/mcs51/at89S8252.h,
2969         * device/include/mcs51/at89c55.h,
2970         * device/include/mcs51/at89x051.h,
2971         * device/include/mcs51/at89x51.h,
2972         * device/include/mcs51/at89x52.h,
2973         * device/include/mcs51/mcs51reg.h,
2974         * device/include/mcs51/reg51.h,
2975         * device/include/mcs51/reg764.h,
2976         * device/include/mcs51/regc515c.h,
2977         * device/include/mcs51/sab80515.h: and added them here
2978
2979 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
2980
2981         * device/include/stdarg.h: changed SDCC specific keywords to double
2982           underlined form.
2983         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
2984           mcs51 and ds390.
2985         * device/include/hc08/mc68hc908gp32.h,
2986         * device/include/hc08/mc68hc908jb8.h,
2987         * device/include/hc08/mc68hc908jkjl.h,
2988         * device/include/hc08/mc68hc908qy.h: fixed comments
2989         * device/include/mcs51/README: updated
2990         * device/include/mcs51/c8051f120.h: added PINRSF
2991         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
2992         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
2993           amidst code. Also inline is not supported.
2994
2995 2005-04-06 Raphael Neider <rneider AT web.de>
2996
2997         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
2998         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
2999           callers stack/frame pointers
3000
3001 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3002
3003         * device/include/pic16/usart.h: added, missing in previous commit,
3004         * device/include/pic16/adc.h: fixed typo,
3005         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
3006         commit,
3007         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
3008         <p18fxxx.inc>
3009         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
3010         uninitialized because a bug appears with gplink
3011         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
3012         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
3013         complains for unrecognised option
3014
3015 2005-04-05 Raphael Neider <rneider AT web.de>
3016
3017         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
3018           structs as well (using memcpy)
3019         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
3020           on ISRs (GOTO has no label)
3021         * src/pic16/device.h: added OF_OPTIMIZE_DF
3022         * src/pic16/main.c: added compiler switch --optimize-df to enable the
3023           new data flow analysis/optimization
3024         * src/pic16/pcode.c: added (prototypes for and implementation of)
3025           dataflow analysis functions, fixed pCodeInstructions' inCond and
3026           outCond values, made RCALL a branch instruction
3027         * (pic16_unlinkpCode): keep C line if possible
3028         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
3029           C line moved if possible
3030         * (pic16_getRegFrompCodeOp): NEW, improved version of...
3031         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
3032           to use new pic16_getRegFrompCodeOp (works for more SFRs)
3033         * (pic16_BuildFlow): fixed skip instructions with label (did not start
3034           new flow)
3035         * (pic16_getJumptabpCode): NEW, needed in...
3036         * (LinkFlow): fixed handling of jumptables, calls and conditional
3037           branches
3038         * (pic16_InsertCommentAfter): NEW
3039         * (pic16_pCodeReplace): made verbose and flow preserving
3040         * (AnalyzeFlow): added call to data flow analysis
3041         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
3042         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
3043         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
3044
3045 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3046
3047         * src/SDCCast.c (decorateType): fixed bug #1105626
3048
3049 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
3050
3051         * device/include/asm/pic16/features.h,
3052         * pic18f*.h headers,
3053         * device/include/pic16/adc.h,
3054         * device/include/pic16/delay.h,
3055         * device/include/pic16/i2c.h,
3056         * device/include/pic16/malloc.h,
3057         * device/include/pic16/stdio.h,
3058         * device/include/pic16/stdlib.h,
3059         * device/include/pic16/string.h,
3060         * device/lib/pic16/libc/stdio/printf_tiny.c,
3061         * device/lib/pic16/libc/stdio/printf_small.c,
3062         * device/lib/pic16/libc/stdio/strmgpsim.c,
3063         * device/lib/pic16/libc/stdio/strmmssp.c,
3064         * device/lib/pic16/libc/stdio/strmusart.c,
3065         * device/lib/pic16/libc/stdio/vfprintf.c,
3066         * device/lib/pic16/libc/stdlib/ltoa.c,
3067         * device/lib/pic16/libc/stdlib/putchar.c,
3068         * device/lib/pic16/libc/stdlib/x_ftoa.c,
3069         * device/lib/pic16/libc/stdlib/memchrpgm.c,
3070         * device/lib/pic16/libc/stdlib/memchrram.c,
3071         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
3072         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
3073         * device/lib/pic16/libio/adc/adcbusy.c,
3074         * device/lib/pic16/libio/adc/adcread.c,
3075         * device/lib/pic16/libio/adc/adcsetch.c,
3076         * device/lib/pic16/libio/usart/ubaud.c,
3077         * device/lib/pic16/libio/usart/ubusy.c,
3078         * device/lib/pic16/libio/usart/udrdy.c,
3079         * device/lib/pic16/libio/usart/uopen.c,
3080         * device/lib/pic16/libio/usart/uputc.c,
3081         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
3082         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
3083         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
3084         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
3085         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
3086         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
3087         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
3088         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
3089         specific keywords to double underlined form,
3090         * device/lib/pic16/libc/Makefile.rules,
3091         * device/lib/pic16/libsdcc/Makefile.rules,
3092         * device/lib/pic16/libm/Makefile,
3093         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
3094         to compile with C standard set in Makefile.common
3095         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
3096         rand.c and crc.c in compilation process,
3097         * device/lib/pic16/libsdcc/int/divuint.c,
3098         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
3099         `c' from signed to unsigned,
3100         * device/lib/pic16/startup/crt0.c,
3101         * device/lib/pic16/startup/crt0i.c,
3102         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
3103         keywords to double underlined form, bug fixes in _do_cinit function
3104         which prevented the correct initialization of the .idata segment,
3105         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
3106         core to enter a infinite loop
3107         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
3108
3109 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3110
3111         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
3112
3113 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3114
3115         * device/include/Makefile.in: add support for hc08 subdirectory
3116         * device/include/hc08/: new subdirectory
3117         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
3118         Lucas Loizaga, thanks!
3119         * device/include/hc08/mc68hc908qy.h,
3120         * device/include/hc08/mc68hc908gp32.h,
3121         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
3122         their own directory. Changed internal macro names to use the compiler
3123         reserved namespace. Changed SDCC specific keywords to double
3124         underlined form.
3125         * device/include/math.h,
3126         * device/include/malloc.h,
3127         * device/include/stdarg.h,
3128         * device/include/stdbool.h
3129         * device/include/string.h,
3130         * device/include/tinibios.h,
3131         * device/include/ds400rom.h,
3132         * device/include/8051.h,
3133         * device/include/8052.h,
3134         * device/include/80c51xa.h,
3135         * device/include/at89c55.h,
3136         * device/include/at89S8252.h,
3137         * device/include/at89x51.h,
3138         * device/include/at89x52.h,
3139         * device/include/ds80c390.h,
3140         * device/include/reg764.h,
3141         * device/include/regc515c.h,
3142         * device/include/sab80515.h,
3143         * device/include/mcs51/c8051f000.h,
3144         * device/include/mcs51/c8051f018.h,
3145         * device/include/mcs51/c8051f020.h,
3146         * device/include/mcs51/c8051f040.h,
3147         * device/include/mcs51/c8051f060.h,
3148         * device/include/mcs51/c8051f120.h,
3149         * device/include/mcs51/c8051f300.h,
3150         * device/include/mcs51/c8051f310.h,
3151         * device/include/mcs51/c8051f320.h,
3152         * device/include/mcs51/c8051f330.h,
3153         * device/include/mcs51/c8051f350.h,
3154         * device/include/z180.h: Changed SDCC specific keywords to double
3155         underlined form.
3156
3157 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3158
3159         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3160         18F4455,
3161         * (pic16_assignConfigWordValue): disable testing of configuration
3162         register value with config mask,
3163         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3164         function with port->fun_prefix,
3165         * (genFunction): when generating a naked interrupt function never
3166         create an absolute segment placed in interrupt vector address, place
3167         the actual interrupt function at IVA instead, when an interrupt
3168         function is generated with unspecified interrupt then do not create
3169         the absolute section,
3170         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3171         code for generating a call to generic pointer get/put function with
3172         a call to function pic16_callGenericPointer(),
3173         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3174         the call to the generic pointer get/put functions with prefixing the
3175         function name with port->fun_prefix,
3176         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3177         * src/pic16/main.c (_process_pragma): prefix function with
3178         port->fun_prefix,
3179         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3180         calling assembler, old 18Fxxxx macro is deprecated,
3181         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3182         PC_ASMDIR in while condition,
3183         * (findInstruction): add PC_ASMDIR in while condition,
3184         * (buildCallTree): prefix main with port->fun_prefix,
3185         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3186         identifier for variable with banked access in instructions BTFSS,
3187         BTFSC, BCF, BSF, BTG
3188         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3189         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3190         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3191         perform optimization when enviroment variable NO_REG_OPT is set,
3192         * (insideLRBlock): NEW, return 1 if register is inside an
3193         INF_LOCALREGS block,
3194         * (RemoveRegFromLRBlock): remove a register that is completely
3195         eliminated by register optimization, but it is still left in local
3196         register store/restore in/from stack block,
3197         * (Remove2pcodes): after removing register, check to see if it
3198         should be removed from local register store/restore in/from stack
3199         block,
3200         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3201         DUMMY_READ_VOLATILE,
3202
3203         * device/include/pic16/adc.h: minor prototype modifications and
3204         update,
3205         * device/include/pic16/malloc.h: added GPL notice various
3206         modifications,
3207         * device/include/pic16/stdint.h: NEW, standard header for ints
3208         * device/include/pic16/delay.h: NEW, header for delay functions,
3209         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3210         delay1mtcy,
3211         * device/include/pic16/signal.h: NEW, header providing helper macros
3212         for implementing signal handlers,
3213         * device/include/pic16/stdio.h: added prototypes for functions,
3214         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3215         prototypes for stdin and stdout, added macro PUTCHAR to
3216         automatically implement putchar function prototype,
3217         * device/include/pic16/usart.h: modified and updated USART library,
3218         * device/lib/pic16/libio/adc/,
3219         * device/lib/pic16/libio/i2c: some modifications to improve library
3220         performance,
3221         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3222         family of functions,
3223         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3224         family of functions and other sources,
3225         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3226         of the PIC18Fxx[28] devices,
3227         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3228         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3229         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3230         _do_cinit function, because the previous failed when local variables
3231         where not placed in the same memory bank,
3232         * device/lib/pic16/libsdcc/char/: various modifications to improve
3233         library performance,
3234         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3235         information on the new functions of the c library and more...
3236
3237 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3238
3239         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3240
3241 2005-03-26 Raphael Neider <rneider AT web.de>
3242
3243         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3244           if condition == CARRY)
3245         * (genCmp): adapted to new genSkipc semantics
3246         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3247           on rIfx (genCmp was broken)
3248
3249 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3250
3251         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3252         * src/z80/main.c (_keywords[]),
3253         * src/SDCCglobal.h (struct options),
3254         * src/SDCC.y,
3255         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3256         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3257         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3258         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3259         always available in leading double underscore form. The C99 support is
3260         mostly missing, but it's a start.
3261         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3262         reserved identifier "__data".
3263
3264 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3265
3266         * src/mcs51/peeph.def: fixed bug 1170013
3267
3268 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3269
3270         * device/include/mcs51reg.h: fixed bug 842007
3271
3272 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3273
3274         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3275         last time.
3276
3277 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3278
3279         * src/port.h (struct PORT),
3280         * src/avr/ralloc.c (avr_assignRegisters),
3281         * src/avr/main.c,
3282         * src/ds390/ralloc.c (ds390_assignRegisters),
3283         * src/ds390/main.c,
3284         * src/hc08/ralloc.c (hc08_assignRegisters),
3285         * src/hc08/main.c,
3286         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3287         * src/mcs51/main.c,
3288         * src/pic/ralloc.c (pic14_assignRegisters),
3289         * src/pic/main.c,
3290         * src/pic16/ralloc.c (pic16_assignRegisters),
3291         * src/pic16/main.c,
3292         * src/xa51/ralloc.c (xa51_assignRegisters),
3293         * src/xa51/main.c,
3294         * src/z80/ralloc.c (z80_assignRegisters),
3295         * src/z80/ralloc.h,
3296         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3297         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3298         * src/SDCCcse.h,
3299         * src/SDCCdflow.c (computeDataFlow),
3300         * src/SDCCdflow.h,
3301         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3302         * src/SDCCloop.h,
3303         * src/SDCCcflow.c (*),
3304         * src/SDCCcflow.h,
3305         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3306         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3307         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3308         immedDom() returning wrong block; probably fixes bug #1160833)
3309
3310 2005-03-20 Borut Razem <borut.razem AT siol.net>
3311
3312         * support/scripts/inc2h.pl: WIN32 port
3313
3314 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3315
3316         * device/lib/makefile.in: added abs.c and labs.c
3317
3318 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3319
3320         * device/include/stdint.h: added
3321         * device/lib/abs.c: added
3322         * device/lib/labs.c: added
3323         * device/include/stdlib.h: added abs() and labs() prototypes
3324         * device/lib/libsdcc.lib: added abs and labs
3325         * device/include/float.h,
3326         * device/lib/_fsmul.c,
3327         * device/lib/printf_fast.c,
3328         * device/lib/printf_tiny.c: updated comments
3329
3330 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3331
3332         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3333         bug #1164313
3334
3335 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3336
3337         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3338         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3339
3340 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3341
3342         * device/lib/printf_large.c: removed inline assembly for portability and
3343           readability. Use printf_fast if speed or size are more important.
3344         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3345         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3346
3347 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3348
3349         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3350         prevent compiler warning
3351
3352 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3353
3354         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3355         moved to level 0 and declared as static. Also they are explicit
3356         placed in access bank. This was necessery because some times they
3357         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3358         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3359         optimizations. Currently only compare to unsigned char is implemented,
3360         * src/pic16/gen.c: added fReturnIdx array,
3361         * (struct resolvedIfx) is moved to gen.h and made public,
3362         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3363         * (aopForSym): added an optimization to directly store in stack of
3364         the operand of a SEND iCode,
3365         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3366         but as registers instead (AOP_REG) using the fReturnIdx array,
3367         * (pic16_freeAsmop): remove the freed register from the
3368         _G.sregsAlloc field,
3369         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3370         a compare of 'WREG',
3371         * (pic16_popGetTempRegCond): changed function prototype, now
3372         function takes also a bitVector argument v which holds the current
3373         set of registers that are allocated for stack access by aopForSym,
3374         registers allocated in aopForSym for accessing stack symbols are not
3375         any more part of the functions usedRegs field,
3376         * (genCall): some times aopOp is called for a stack variable to be
3377         send, aopForSym might perform the push, if this is true make sure
3378         that genCall doesn't push the variable twice by testing _G.resDirect,
3379         * (genFunction): changed testing for unspecified interrupt number
3380         from 256 to INTNO_UNSPEC,
3381         * modified selection scheme of frame pointer generation. Previously
3382         if function did use local registers a frame pointer was generated,
3383         now a frame pointer is generated only if function has arguments
3384         (that need PLUSW2 register access), or has stack arguments, or the
3385         compiler is not instructed to omit the frame pointer,
3386         * (genEndFunction): before restoring local registers that were saved
3387         in the function preamble, also restore the registers that *might*
3388         have been allocated for stack access,
3389         * (genRet): removed some old comments,
3390         * (genCmp, the active (RN's) version): added a call to the
3391         pic16_genCmp_special function to perform the compare with a more
3392         robust and optimized way,
3393         * (genInline): a feature has been added in inline code generation,
3394         which allows a wildcard variable substitution when writing inline
3395         assembly. Code is incomplete and experimental therefore undocumented,
3396         * (genCast): changed order of aopOp for result and right to allow
3397         aopForSym to directly load the result if possible,
3398         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3399         perform an optimized compare on some selected special occasions,
3400         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3401         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3402         generate an IVT any more,
3403         * src/pic16/main.c (pic16_optionsTable): added command line option
3404         --optimize-cmp,
3405         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3406         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3407         macros,
3408         * src/pic16/NOTES: Raphael Neider added in list of active developers
3409         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3410         jumptable_end to prevent bug #,
3411         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3412         inCond and outCond fields,
3413         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3414         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3415         turn off register spilling,
3416         * (packRegsForOneUse): synced with other ports' versions although it
3417         is not used currently,
3418         * (pic16_packRegisters): added an optimization while reading
3419         structure bitfields, some registers may be saved (malloc code is
3420         decreased by 80 bytes)
3421
3422 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3423
3424         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3425         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3426         this can be optimized more?
3427
3428 2005-03-10 Raphael Neider <rneider AT web.de>
3429
3430         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3431           genNearPointerGet): (hopefully) fixed access to bitfields via
3432           pointers (p->bitN = x; and x = p->bitN; failed)
3433
3434 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3435
3436         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3437
3438 2005-03-09 Raphael Neider <rneider AT web.de>
3439
3440         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3441
3442 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3443
3444         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3445         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3446           (regTypeNum): set REG_BIT type if necessary
3447         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3448         * support/regression/tests/critical.c: check bug 1144613
3449
3450 2005-03-02 Raphael Neider <rneider AT web.de>
3451
3452         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3453
3454 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3455
3456         * src/avr/ralloc.c (serialRegAssign),
3457         * src/ds390/ralloc.c (serialRegAssign),
3458         * src/hc08/ralloc.c (serialRegAssign),
3459         * src/mcs51/ralloc.c (serialRegAssign),
3460         * src/pic/ralloc.c (serialRegAssign),
3461         * src/pic16/ralloc.c (serialRegAssign),
3462         * src/xa51/ralloc.c (serialRegAssign),
3463         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3464
3465 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3466
3467         * src/SDCCast.c (decorateType): fixed bug 1124787
3468
3469 2005-02-20 Hubert Sack <sack AT digiplan.de>
3470         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3471
3472         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3473         patch #1121755
3474
3475 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3476
3477         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3478         to keep the correct label reference count when adding/removing references
3479         to labels. A peephole file using this is appended to patch #1144962.
3480
3481 2005-02-14 Raphael Neider <rneider AT web.de>
3482
3483         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3484         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3485         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3486           retrievals of result operand's value on assignment
3487
3488 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3489
3490         * device/include/pic16/string.h: modified prototype for memccpy()
3491         to memccpy(void *, void *, char, size_t)
3492         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3493         check whether to omit frame pointer or not,
3494         * (genInline): convert all occurences of "\n" to LF in inline
3495         assembler blocks, this helps formatting the inline text,
3496         * (pic16_loadFSR0): modified prototype,
3497         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3498         removed some 8051 legacy code,
3499         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3500         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3501         before allocating temporary registers in functions,
3502
3503 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3504
3505         * support/regression/tests/bitvars.c: corrected the "fix"
3506
3507 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3508
3509         * support/regression/tests/bitvars.c,
3510         * support/regression/tests/bitwise.c,
3511         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3512
3513 2005-02-10 Raphael Neider <rneider AT web.de>
3514
3515         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3516           different size for Alpha
3517         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3518
3519 2005-02-09 Raphael Neider <rneider AT web.de>
3520
3521         * src/SDCC.lex(doPragma) : save and restore warning options as well
3522           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3523         * have #pragma less_pedantic set the errorlevel to WARNING
3524           (fixes #1117001)
3525         * (cloneOptimize) : fixed wrong malloc's size
3526         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3527           facilitate correct handling of #pragma (save|restore)
3528
3529 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3530
3531         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3532
3533 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3534
3535         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3536
3537 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3538
3539         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3540
3541 2005-02-02 Raphael Neider <rneider AT web.de>
3542
3543         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3544         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3545         * (pic16_storeForReturn): fixed to allow returning function pointers
3546         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3547         * device/include/pic16/{stddef.h,stdbool.h}: added
3548
3549 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3550
3551         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3552
3553 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3554
3555         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3556         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3557          appeared to be required
3558
3559 2005-01-31 Borut Razem <borut.razem AT siol.net>
3560
3561         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3562           include/mcs51 and include/z80 directories to the package
3563
3564 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3565
3566         * src/hc08/gen.c (genFunction): fixed bug #1112752
3567
3568 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3569
3570         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3571
3572 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3573
3574         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3575
3576 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3577
3578         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3579
3580 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3581
3582         * device/include/c8051fxxx.h: removed these 6 files
3583         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3584
3585 2005-01-26 Raphael Neider <rneider AT web.de>
3586
3587         * src/pic16/gen.c (genAssign): fixed assignment from longs
3588           in codespace (were cut to three bytes)
3589         * (genDummyRead): implemented (except for CODESPACE...),
3590           fixed bug #1108575
3591         * src/pic16/glue.c (emitStatistics): beautified
3592         * device/lib/pic16/libm/Makefile: added include path
3593
3594 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3595
3596         * src/z80/gen.c (aopPut): fixed bug #1103902
3597
3598 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3599
3600         * device/lib/expf.c: fixed bug #1095792
3601
3602 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3603
3604         * device/lib/pic16/libm: added Math library sources
3605
3606 2005-01-24 Raphael Neider <rneider AT web.de>
3607
3608         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3609           to enable upcast to pCodeOpReg2 (there is no type tag to
3610           differenciate the two and pic16_popGet2p cast into PCOR2)
3611         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3612           (sizeof(sectNames) changed to sizeof(sectName))
3613           Both patches fix segfaults under MinGW.
3614
3615 2005-01-23 Raphael Neider <rneider AT web.de>
3616
3617         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3618           Safe_[mc]?alloc()'ed variables
3619         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3620           of (byte sized) temporaries (assign them to WREG for now)
3621         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3622           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3623           this might fix SIGSEGVs on MinGW...
3624         * src/SDCCopt.c (killDeadCode): restored original behaviour
3625           (volatile operands might get thrown away though)
3626
3627 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3628
3629         * src/pic16/gen.c: fixed bug #1106975,
3630         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3631         pointer update, INTCON is saved, global interrupts are disabled and
3632         restored after updateing TOS.
3633         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3634         * added function attribute 'shadowregs' to take advantage of shadow
3635         registers,
3636         * added function attribute 'wparam' as an alternative to the wparam
3637         pragma,
3638         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3639         user declares a non-ISR function as 'shadowregs',
3640         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3641
3642 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3643
3644         * .version: bumped version number to 2.4.8
3645         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3646         pic16 port,
3647         * device/lib/pic16/libio/i2c/: I2C module support library,
3648         * device/include/pic16/i2c.h: I2C support library header,
3649         * device/lib/pic16/libc/stdio/: standard IO support sources,
3650         * (printf_small.c): printf_small() source, supports float print,
3651         * (printf_tiny.c): printf_tiny() source, does not support floats,
3652         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3653         enable global optimizations for entire library source, other
3654         Makefiles in the source tree are also modified to reflect this,
3655         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3656         function,
3657         * doc/sdccman.lyx: updated to reflect new changes,
3658         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3659         sym->onStack if-case,
3660         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3661         sbit, idata, _idata, xdata, _xdata,
3662         * added pragma library, to link an external library, (see doc),
3663         * removed command line options, --pomit-config-words, --pomit-ivt,
3664         --pleave-reset-vector,
3665         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3666         when calling assembler to reflect memory model used, also define
3667         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3668         reflect stack model used,
3669         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3670         on stack return NULL,
3671
3672 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3673
3674         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
3675           of the operands is volatile. Fixes #1020220
3676
3677 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3678
3679         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
3680         * (OptimizeRegUsage): make sure that there is really no other flow where
3681           the first pCode is used
3682
3683 2005-01-22 Raphael Neider <rneider AT web.de>
3684
3685         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
3686           to fix #1106967 (pCode->seq are not set up correctly)
3687
3688 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3689
3690         * src/SDCCglue.c (glue): make sure code area is declared before the
3691         static initialization area.
3692
3693 2005-01-21 Raphael Neider <rneider AT web.de>
3694
3695         * device/lib/Makefile.in: fixed test for pic16 install dir
3696         * device/lib/pic16/*/Makefile*: modified compile flags to enable
3697           optimizations
3698         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
3699           added --optimize-goto compiler switch and pragma wparam documentation
3700         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
3701         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
3702           and PRODH closing bug #1071770 (peephole optimizer)
3703
3704 2005-01-19 Raphael Neider <rneider AT web.de>
3705
3706         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
3707           cmdLine buffers (used when calling sdcpp...) are large enough
3708           (MAX_PATH=256 truncates arguments leading to system halts when
3709           used in MinGW...)
3710         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
3711         * (genUminus): rewritten to for efficiency
3712         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
3713           used uninitialized in some cases)
3714         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
3715           copy the third byte from the int -- now assumes 0x80 (data memory)
3716         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
3717           operands (genAddLit expects the iCode's operands to swapped as
3718           well), fixed leftover bytes (crashed for short left operands)
3719         * (pic16_genMinusDec): performance improvements, removed false
3720           PIC14 emitSKPNCs
3721         * (pic16_genMinus): fixed to cope with differently sized operands
3722         * src/pic16/glue.c (pic16_glue): added new banksel optimization
3723           for --obanksel > 1
3724         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
3725         * src/pic16/graph.[ch]: implementation of directed graphs, used by
3726           new banksel optimization
3727         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
3728           analysis for temporary registers (segfaults...)
3729         * src/pic16/peeph.def: added rule
3730
3731 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
3732
3733         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
3734         which converts a float number to its ASCII representation
3735         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
3736         functions to convert the fractional and integer part of a float to ASCII,
3737         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
3738         realloc.c): added _MALLOC_SPEC to explicit place variables in data
3739         ram
3740         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
3741         _STATMEM macros,
3742         * device/include/pic16/adc.h: added GPL info,
3743         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
3744         a pCodeOp as tested operand,
3745         * (genNearPointerGet): optimized bit testing, does not use
3746         intermediate register for bit value, test directly instead with
3747         BTFSS, BTFSC, works only for single bits,
3748         * (genpic16Code): dump the name of the iCode in the asm,
3749         * src/pic16/ralloc.c (decodeOp): removed static declaration and
3750         renamed to pic16_decodeOp,
3751         * (serialRegAssign): do not allocate a temporary register for iCode
3752         sequences that test a single bit for 1/0
3753
3754 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
3755
3756         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
3757         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
3758         access stack and frame pointers. They are initially assigned to
3759         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
3760         accessing SFRs. Updated all occurences of modification of stack or
3761         frame pointer in gen.c and pcode.c,
3762         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
3763         assigning of a literal value to pointers,
3764         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
3765         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
3766         selected
3767
3768 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
3769
3770         * doc/sdccman.lyx: update documentation about stack pragma, added
3771         some info for stack memory models
3772
3773 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3774
3775         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
3776
3777 2005-01-08 Raphael Neider <rneider AT web.de>
3778
3779         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
3780           udata sections to fix bug #1097823
3781
3782 2005-01-05 Raphael Neider <rneider AT web.de>
3783
3784         * src/pic16/gen.c (genGenericShift): added handling of differently
3785           sized left operand and result
3786
3787 2005-01-04 Raphael Neider <rneider AT web.de>
3788
3789         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
3790         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
3791           to hold the condition bit)
3792         * added new version of genCmp (old code available via #define)
3793         * added new version of genShiftLeft/genShiftRight in a generic
3794           way, now supports shifting by negative values
3795         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
3796           shiftCount (expected by genGenericShift)
3797         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
3798         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
3799           dump
3800         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
3801           is an invalid literal too...)
3802
3803 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
3804
3805         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
3806         from Raphael Neider,
3807         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
3808         for 8-bit literals. This fixes some literal operands which are sign
3809         extended to 16-bits ints when instruction needs only 8-bits.
3810
3811 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
3812
3813         * device/lib/logf.c: added mcs51 assembly version
3814         * device/lib/expf.c: added mcs51 assembly version
3815         * device/lib/_logexpf.c: new shared asm code for expf and logf
3816         * device/include/math.h: add defines for assembly math library
3817         * device/lib/Makefile.in: build new _logexpf.c
3818         * device/lib/libfloat.lib: use new _logexpf.c
3819
3820 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3821
3822         * src/pic/device.c
3823         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
3824           device types which have less than 0x7f registers.
3825
3826 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3827
3828         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
3829
3830 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
3831
3832         * device/lib/printf_fast.c: only build on supported arch.
3833         * device/lib/printf_tiny.c: only build on supported arch.
3834         * device/lib/printf_fast_f.c: only build if asm float lib
3835         * device/lib/_fsget1arg.c: only build if asm float lib
3836         * device/lib/_fsget2args.c: only build if asm float lib
3837         * device/lib/_fsnormalize.c: only build if asm float lib
3838         * device/lib/_fsreturnval.c: only build if asm float lib
3839         * device/lib/_fsrshift.c: only build if asm float lib
3840         * device/lib/_fsswapargs.c: only build if asm float lib
3841         * device/include/stdio.h: don't provide print_fast,
3842           print_fast_f, print_tiny prototypes if --xstack used
3843
3844 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
3845
3846         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
3847         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
3848           to the SOURCES
3849
3850 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
3851
3852         * device/lib/printf_fast_f.c: same as printf_fast, but
3853           with floating point enabled
3854         * device/lib/printf_fast.c: minor tweaks
3855         * device/include/stdio.h: add printf_fast_f
3856
3857 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
3858
3859         * src/SDCCmain.c: make --float-reent default for mcs51
3860         * device/lib/_fsadd.c: added mcs51 assembly version
3861         * device/lib/_fssub.c: added mcs51 assembly version
3862         * device/lib/_fsmul.c: added mcs51 assembly version
3863         * device/lib/_fsdiv.c: added mcs51 assembly version
3864         * device/lib/_fseq.c: added mcs51 assembly version
3865         * device/lib/_fsneq.c: added mcs51 assembly version
3866         * device/lib/_fsgt.c: added mcs51 assembly version
3867         * device/lib/_fslt.c: added mcs51 assembly version
3868         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
3869         * device/lib/Makefile.in: add _fscmp to build
3870         * device/lib/libfloat.lib: add _fscmp to build
3871
3872 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
3873
3874         * device/lib/_fs2slong.c: added mcs51 assembly version
3875         * device/lib/_fs2sint.c: added mcs51 assembly version
3876         * device/lib/_fs2schar.c: added mcs51 assembly version
3877         * device/lib/_fs2ulong.c: added mcs51 assembly version
3878         * device/lib/_fs2uint.c: added mcs51 assembly version
3879         * device/lib/_fs2uchar.c: added mcs51 assembly version
3880         * device/lib/_slong2fs.c: added mcs51 assembly version
3881         * device/lib/_sint2fs.c: added mcs51 assembly version
3882         * device/lib/_schar2fs.c: added mcs51 assembly version
3883         * device/lib/_ulong2fs.c: added mcs51 assembly version
3884         * device/lib/_uint2fs.c: added mcs51 assembly version
3885         * device/lib/_uchar2fs.c: added mcs51 assembly version
3886         * device/include/float.h: added #define to select asm vs c
3887
3888 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
3889
3890         * device/lib/printf_fast.c: improvements to float output
3891         * device/include/float.h: add defines for assembly float library
3892         * device/lib/_fsget1arg.c: receive 1 float arg
3893         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
3894         * device/lib/_fsnormalize.c: normalize a float
3895         * device/lib/_fsreturnval.c: return float, various helper routines
3896         * device/lib/_fsrshift.c: right shift a float's mantissa
3897         * device/lib/_fsswapargs.c: swap 2 floats
3898         * device/lib/Makefile.in: build these 6 new files for mcs51
3899         * device/lib/libfloat.lib: add these 6 files to the library
3900
3901 2004-12-26 Borut Razem <borut.razem AT siol.net>
3902
3903         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
3904           built by gcc 3.4.2
3905
3906 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
3907
3908         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
3909           and fully reentrant and register bank neutral.
3910         * device/lib/printf_fast.c: added float (not enabled by default),
3911           added compact/slower integer (also not enabled by default),
3912           improved size/speed of fast integer code, other minor changes
3913         * device/include/stdio.h, device/lib/Makefile.in,
3914           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
3915
3916 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
3917
3918         * src/pic16/pcode.c: declaring variables other than at the start of a
3919           block is not supported in C by VC6.
3920
3921 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
3922
3923         * applied a previous patch from Raphael Neider that wasn't included
3924         in the previous commits, which fixes infinite loops within jumptable
3925         improvements,
3926         * made some fixes that previous patches introduced
3927
3928 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
3929
3930         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
3931         that fixes an issue with AOP_PCODE asmop's offset,
3932         * (pic16_popCopyReg): update instance field too,
3933         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
3934         function of pic port,
3935         * (genCmp, genAnd, genAssign),
3936         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
3937
3938 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
3939
3940         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
3941         variables initial values to idata section,
3942         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
3943         variables in some functions. This utilizes parmBytes field of iCode
3944         structure to hold the offset of the variable in stack. (might be
3945         able to use the stack field too?)
3946         * applied patch from Raphael Neider # ### , # ###
3947         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
3948         variable initial values in idata section,
3949         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
3950         for static variables with initial value
3951         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
3952         applied fix in while loop from Raphael Neider.
3953
3954 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
3955
3956         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
3957         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
3958         * src/ds390/ralloc.c (serialRegAssign): spill bits
3959         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
3960         * support/Util/SDCCerr.c,
3961         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
3962         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
3963         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
3964
3965 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
3966
3967         * device/include/sdcc-lib.h: inserted LGPL, added includes
3968           asm/ds390/features.h and asm/mcs51/features.h
3969         * device/include/asm/default/features.h,
3970         * device/include/asm/gbz80/features.h,
3971         * device/include/asm/z80/features.h: added empty _AUTOMEM
3972           and _STATMEM
3973         * device/include/asm/ds390/features.h,
3974         * device/include/asm/mcs51/features.h: added files with defines for
3975           _AUTOMEM and _STATMEM indicating automatic and static storage class
3976         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
3977         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
3978         * src/SDCCicode.c (geniCodeCast),
3979         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
3980         * src/SDCCloop.c (loopInduction): removed unused variable lr
3981         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
3982           to convertToFcall to include char modulo (RFE 1065037), added check
3983           if left operand is unsigned and use abs of literal value
3984         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
3985           as it doesn't work after conversion from peephole.def to peephole.rul
3986         * src/mcs51/gen.c (toBoolean): added check for size,
3987           (genModOneByte): optimized code for signed char modulo a literal
3988           power of 2 (thanks to Hubert Sack),
3989           (genRRC): removed unnecessary "clr c",
3990           (genRLC): replaced "add a,acc" with cheaper "rlc a"
3991         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
3992           jump optimization,
3993           swapped rules 256.c and 256.d,
3994           extended 256.d by using new multiple checks (thanks Erik),
3995           added rules 256.e and 256.f,
3996           updated rule 261.a and 261.b to new generated code
3997         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
3998
3999 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4000
4001         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
4002           induction related bugs, including first part of bug #1074377
4003
4004 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
4005
4006         * applied patch from bug-report #1076292,
4007         * applied patches for genAnd and Goto-optimizations for Raphael
4008         Neider,
4009         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
4010         dump a less iCode information,
4011         * src/pic16/device.h (pic16_options_t): added field debgen,
4012         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
4013         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
4014         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
4015         puclic,
4016         * (various functions): added macros FENTRY and FENTRY2 to functions,
4017         to emit function prologue,
4018         * (various functions): fixed indentation,
4019         * (genNearPointerGet): fixed loading of FSR0,
4020         * (genPackBits): applied patch from Raphael Neider to fix updating
4021         of FSR0 and touching only the modified bits,
4022         * src/pic16/genarith.c (various functions): added macros FENTRY to
4023         emit function prologue in comments,
4024         * src/pic16/pcode.h: added functions debugf2, debugf3,
4025         * src/pic16/ralloc.c: partial fix for packForPush caused
4026         segmentation fault,
4027
4028 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4029
4030         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
4031           <stsp AT users.sourceforge.net> with reversed byte order
4032         * support/regression/tests/rotate.c: added (ds390 skips some tests)
4033
4034 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4035
4036         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
4037           bug #1074377
4038         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
4039         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
4040
4041 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4042
4043         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
4044
4045 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4046
4047         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
4048           conditions,
4049           (setFromConditionArgs): friendly operand parser for peephole rules,
4050           (operandBaseName, operandsNotRelated): new peephole condition
4051           "operandsNotRelated" -- similar to "operandsNotSame", but takes
4052           architecture specific register naming into account, handles n-way
4053           comparisons, and supports quoted literals
4054         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
4055
4056 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4057
4058         * src/mcs51/peeph.def: fixed bug #1076940
4059
4060 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4061
4062         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
4063
4064 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4065
4066         Adding support for replacing ljmps with sjmps in jumptables
4067         generated for switch statements. For now you need to set the
4068         environment variable SDCC_SJMP_JUMPTABLE to enable this.
4069         Now 4 algorithms for mcs51 jumptable generation are used:
4070         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
4071         addresses loaded pc-relative for up to 112 cases and stack-pushing
4072         target addresses loaded with offset from dptr for up to 256 cases.
4073
4074         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
4075         * src/mcs51/main.c: adapted constants for switch table generation
4076         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
4077
4078 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
4079
4080         * device/lib/printf_large.c (_print_format): fixed bug 1073386
4081         * support/regression/tests/bug1057979.c: added test for bug 1073386
4082
4083 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4084
4085         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
4086         compilers
4087
4088 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4089
4090         * src/pic16/device.h,
4091         * src/pic16/genarith.c,
4092         * src/pic16/glue.c,
4093         * src/pic16/main.c,
4094         * src/pic16/pcode.c: applied patches #1068154 and #1070213
4095
4096 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
4097
4098         Large cummulative patch for pic16 port.
4099         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
4100         to call when a stack overflow occurs,
4101         * (malloc.h): added CVS Id tag,
4102         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
4103         variable,
4104         * added libc directory. The current version of LibC contains string
4105         functions, ctype functions and macros and some functions of the
4106         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
4107         be extensively tested in the future. Standard disclaimer here.
4108         Library is not automatically build yet. But one can build it by
4109         invoking 'make' inside the libc directory.
4110         * added ADC library under libio. Preliminary version yet.
4111
4112         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
4113         * src/pic16/gen.c (aopForRemat): asmop size is filled by
4114         aopForRemat() now and not by pic16_aopOp(),
4115         * (pic16_popGetTempReg): removed warning messgae when allocating
4116         temporary registers, its a buggy feature and will be removed,
4117         * (pic16_popGet): set register instance field in AOP_CRY,
4118         * (pic16_outBitC): fixed for results in size greater than 1,
4119         * (genUminusFloat): fixed for pic16, ported code from mcs51,
4120         * (pic16_storeForReturn): optimized return of 0,
4121         * (genCmp): experimental code for new genCmp which uses PIC18's
4122         special compare&skip instructions. Initial tests fail some times
4123         with variables grater than 1 byte in size, so new code is disabled,
4124         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
4125         a single bit,
4126         * (genCast): began a fix to optimize the casting of a bit to another
4127         bit, now assigning a bitfield to another bitfield will fail, sorry,
4128         * src/pic16/main.c: disabled the use of lr-support feature,
4129         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
4130         * added some function prototypes, added function _debugf prototype,
4131         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
4132         bits with offset (case PO_GPR_BIT),
4133         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
4134         command line,
4135         * (isBankInstruction): modified to return 0 for no banking instruction,
4136         and 1 for banking instruction,
4137         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
4138         caused stop processing pCodes after a inline assembly block,
4139         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
4140         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4141         registers when it shouldn't,
4142         * src/pic16/ralloc.c (allocReg): add preliminary support for
4143         supporting a limited set of temporary registers,
4144
4145 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4146
4147         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4148           genDataPointerSet): ensure assignments always copy in MSB to LSB
4149           order,
4150           (loadRegFromAop): recognize CLRH optimization,
4151           (genFunction): optimize RECEIVE iCodes in reentrant functions
4152
4153 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4154
4155         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4156           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4157           selected.
4158         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4159         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4160           contiguous with data
4161
4162 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4163
4164         * device/lib/_gptrget.c (_gptrget),
4165         * device/lib/_gptrgetc.c (_gptrgetc),
4166         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4167           instead of sjmp to ret
4168         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4169           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4170
4171 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4172
4173         * .version: bumped version to 2.4.7
4174         * device/lib/_gptrget.c (_gptrget): is now _naked
4175         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4176         * device/lib/_gptrput.c (_gptrput): is now _naked
4177         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4178           (createFunction): fixed xstack
4179         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4180         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4181           or bit either,
4182           (geniCodeCritical): store original interrupt state in an iTemp bit
4183           var unless stack-auto
4184         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4185         * src/SDCCmain.c (setIncludePath): added include/target to search path
4186         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4187         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4188           prototype,
4189           (processFuncArgs): put bit vars in bit area
4190         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4191           unsaveRBank): fixed xstack,
4192           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4193           (genFunction, genEndFunction): fixed xstack,
4194           (genAssign): optimization don't walk backwards through mem
4195         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4196         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4197         * support/regression/Makefile: also make library (for stack-auto) when
4198           making "all" and added "test-mcs51-xstack-auto"
4199         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4200         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4201         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4202         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4203         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4204           make-library by MAKE_LIBRARY
4205         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4206           regression tests for xstack
4207         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4208         * support/regression/tests/critical.c: test for critical on mcs51
4209
4210 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4211
4212         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4213           built version of sdcc instead of installed version
4214
4215 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4216
4217         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4218         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4219           vprintf.c now
4220         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4221         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4222           WARNING: remove device/lib/build/z80/printf.o by hand when
4223           updating from previous build!
4224         * device/lib/z80/printf.c: updated comment
4225         * support/regression/tests/bug1057979.c: test all ports now
4226         * support/regression/tests/bug1065458.c: file added
4227
4228 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4229
4230         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4231           *_start and *_end symbols for static functions
4232
4233 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4234
4235         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4236           and search crt0.o in all library paths,
4237           (setIncludePath): proper handling of --nostdinc,
4238           (setLibPath): proper handling of --nostdlib
4239         * support/regression/Makefile,
4240         * support/regression/ports/ds390/spec.mk,
4241         * support/regression/ports/gbz80/spec.mk,
4242         * support/regression/ports/hc08/spec.mk,
4243         * support/regression/ports/mcs51/spec.mk,
4244         * support/regression/ports/mcs51-large/spec.mk,
4245         * support/regression/ports/mcs51-stack-auto/spec.mk,
4246         * support/regression/ports/z80/spec.mk: use include and lib files from
4247           built version of sdcc instead of installed version
4248         * doc/sdccman.lyx: fixed typo in --nostdinc
4249
4250 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4251
4252         * src/pic/pcode.c,
4253         * src/pic/device.c,
4254         * src/pic/ralloc.c,
4255         * src/pic/gen.c : added support to generate code for struct bit fields.
4256
4257 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4258
4259         * as/xa51/xa_version.h,
4260         * device/include/errno.h,
4261         * device/include/regc515c.h,
4262         * device/lib/_itoa.c,
4263         * device/lib/_ltoa.c,
4264         * device/lib/ser_ir_cts_rts.c,
4265         * sim/ucsim/xa.src/glob.cc,
4266         * sim/ucsim/xa.src/inst_gen.cc,
4267         * sim/ucsim/xa.src/xa_bit.cc,
4268         * sim/ucsim/xa.src/xa_sfr.cc,
4269         * sim/ucsim/z80.src/inst_dd.cc,
4270         * sim/ucsim/z80.src/inst_fdcb.cc,
4271         * support/scripts/keil2sdcc.pl,
4272         * src/pic16/pic16.dsp,
4273         * src/pic16/pic16a.dsp: corrected cvs line endings
4274         * device/lib/printf_large.c: fixed bug 1057979
4275         * src/pic16/gen.c: fixed non-C standard code
4276         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4277         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4278         * support/regression/ports/mcs51/support.c: reload T1 asap
4279         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4280           pdata use and clear idata startup behaviour
4281         * support/regression/tests/bug1057979.c: added
4282
4283 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4284
4285         * device/examples/ds390/ow390/ad26.h,
4286         * device/examples/ds390/ow390/cnt1d.h,
4287         * device/examples/ds390/ow390/crcutil.c,
4288         * device/examples/ds390/ow390/ownet.h,
4289         * device/examples/ds390/ow390/owsesu.c,
4290         * device/examples/ds390/ow390/swt12.h,
4291         * device/examples/ds390/ow390/swtoper.c,
4292         * device/examples/ds390/ow390/temp10.h,
4293         * device/examples/ds390/ow390/thermodl.c,
4294         * device/examples/ds390/tinitalk/tinitalk.dsp,
4295         * device/examples/ds390/tinitalk/tinitalk.dsw,
4296         * device/examples/mcs51/clock/hw.h,
4297         * device/examples/mcs51/simple2/go.bat,
4298         * device/examples/serialcomm/windows/serial.h,
4299         * device/examples/xa51/dummy.c,
4300         * device/examples/xa51/hello.c,
4301         * device/include/80c51xa.h,
4302         * device/include/at89x051.h: corrected cvs line endings
4303
4304 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4305
4306         * src/pic16/main.c (options): added command line --gstack, to trace
4307         stack over/under flows,
4308         * added pragma 'wparam' to allow passing first byte of function
4309         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4310         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4311         call to __gstack_test function and sets up the symbol as extern,
4312         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4313         * popaop): added call to pic16_testStackOverflow,
4314         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4315         wparamList list,
4316         * (genCall, genPcall): now all parameters are passed via stack
4317         except in functions that are pass to wparam pragma in which WREG is
4318         used too,
4319         * (genPcall): REENTRANT flag is checked to see if variable prototype
4320         contains reentrant keyword, don't call a non-reentrant function, via
4321         a reentrant function pointer or vice versa, functions are never
4322         passed via WREG,
4323         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4324         D.Winkler,
4325         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4326         SIGSEGV when accessing a NULL register stucture,
4327         * (pic16_printGPointerType): modified to handle UPPER modifier for
4328         function initializers, changed prototype of function to simpler one,
4329         * (pic16_printIvalFuncPtr): check to see if function is already
4330         added in externs list,
4331         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4332         optimized a move from W to SFR with a move to the same register
4333         later after a CALL,
4334         * device/lib/pic16/debug: NEW directory, contains debug features
4335         which are enabled when linking with libdebug.lib, currently command
4336         line option --gstack enables stack pointer tracing for over/under
4337         flow, corresponding sources are in debug/gstack
4338
4339 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4340
4341         * doc/sdccman.lyx: updated SDCC version,
4342         * (PIC16 port): update list of command line options,
4343         * src/pic16/device.h (structure pic16_options_t): added field gstack
4344         to enable stack overflow tracing on push/pops,
4345         * src/pic16/device.c (statistics structure): added statistics
4346         structure,
4347         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4348         pic16_dump_int_registers): increase statistics counters for each
4349         * variable which is encountered
4350         * (pic16_dump_usection): emit each .udata variable to its own udata
4351         section,
4352         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4353         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4354         parameters via stack, otherwise use old scheme,
4355         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4356         assembler output file,
4357         * src/pic16/main.c: added command line options --gstack to enable
4358         push/pop tracing for stack overflow,
4359         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4360         instructions): added size of each instruction,
4361         * (pic16_countInstruction): estimate size of instructions in
4362         the_pFile list, inline assembly blocks are not counted,
4363         * (pic16_FixRegisterBanking): trace previous register usage, when
4364         banksel optimizations is greater than 0, don't emit a redudant
4365         banksel directive,
4366
4367 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4368
4369         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4370         * src/pic16/ralloc.c : applied same fix for pic16.
4371         * src/pic/gen.c : tidied it up a little.
4372
4373 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4374
4375         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4376         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4377
4378 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4379
4380         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4381
4382 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4383
4384         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4385         non-reentrant function __modsint in the interrupt function (thus
4386         corrupting math operations during serial I/O)
4387         * device/lib/ser_ir.c: as above, changed buffersize
4388         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4389         256.c,d for zeroing
4390         * doc/Makefile: added option -t for rsync
4391
4392 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4393
4394         * src/SDCCast.h (struct ast),
4395         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4396
4397 2004-10-20 Borut Razem <borut.razem AT siol.net>
4398
4399         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4400         package
4401
4402 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4403
4404         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4405         makefile targets,
4406         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4407         support functions to replace long sequences of MOVFF's from access
4408         bank registers to stack and vice versa,
4409         * src/pic16/device.h: added new field opt_flags, where optimization
4410         flags can be set to enable certain features,
4411         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4412         * pBlock, (genFunction, genEndFunction): surroung loop for
4413         saving/loading used registers in stack with PC_INFO pCodes,
4414         INF_LREGS. Code in between can then be optimized by pCode optimizer
4415         to support function calls,
4416         * (genDataPointerSet): fixed bug which loaded float fields in
4417         structures with corrupt data,
4418         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4419         in a standard way debug info on stderr. Feature used for developing
4420         and debugging only,
4421         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4422         obsolete chunks of code,
4423         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4424         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4425         * pic16/src/pcode.c (pic16_newpCodeInfo,
4426         * (pic16_newpCodeOpLocalRegs),
4427         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4428         feature,
4429         * (pic16_pCodeConstString): printing of the initial value of a
4430         symbol as a comment is inhibited since parsing was already done by
4431         copyStr and output is corrupt,
4432         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4433
4434 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4435
4436         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4437
4438 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4439
4440         * as/mcs51/lkarea.c: removed old K&R style,
4441           (lnksect): changed check on boundary error,
4442           (lnksect2): changed check on boundary error,
4443           (lnksect2): extend XSTK to end of page if size = 1
4444         * as/mcs51/lkmain.c: removed old K&R style,
4445           (Areas51): create l_IRAM symbol
4446         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4447         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4448           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4449         * device/lib/_mullong.c: added version to be compiled with xstack
4450         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4451         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4452         * device/lib/mcs51/crtxstack.asm: fixed comment
4453         * src/SDCCglue.c: maxInterrupts defaults to 0,
4454           (emitMaps): added pdata,
4455           (createInterruptVect): (re)moved default,
4456           (glue): added pdata,
4457           (glue): moved __start__xstack to XSTK with default size 1
4458         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4459           and options.float_rent when options.stackAuto is set,
4460           (linkEdit): only write XDATA_NAME if provided on command line
4461         * src/SDCCmem.h,
4462         * src/SDCCmem.c: added pdata
4463         * src/port.h: added pdata_name to PORT
4464         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4465           (saveRegisters, unsaveRegisters): removed usage of B,
4466           (genMinus): fixed accumulator clash,
4467           (genJumpTab): added comment, this needs another look
4468         * src/mcs51/gen.c: added check for "B in use" paranoia,
4469           added pushB() and popB()
4470         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4471           chance
4472         * src/avr/main.c,
4473         * src/ds390/main.c,
4474         * src/hc08/main.c,
4475         * src/mcs51/main.c,
4476         * src/pic/main.c,
4477         * src/pic16/main.c,
4478         * src/xa51/main.c,
4479         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4480           added PSEG (PAG,XDATA) or NULL to port specifier
4481         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4482         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4483           (_mcs51_genInitStartup): removed __start__xstack equ,
4484           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4485         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4486         * src/z80/gen.c (_rleAppend): fixed warnings
4487         * support/regression/tests/zeropad.c: added pdata test
4488         * .version: bumped to 2.4.6
4489
4490 2004-10-17 Borut Razem <borut.razem AT siol.net>
4491
4492         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4493         as a part of nightly build
4494
4495 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4496
4497         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4498         WREG holds the first byte function parameters,
4499         * (aopForSym): take special case for symbols which are in FARSPACE
4500         but in CODESPACE too,
4501         * (assignResultValue): modified to take into account _G.useWreg,
4502         * (genCall): don't use wreg for parameter passing when function is
4503         declared as reentrant, too, added optimization INCF to stack
4504         pointer when stack parameter count is 1,
4505         * (genFunction, genEndFunction): refurnished and fixed to not using
4506         wreg for passing parameters when function has varargs or is
4507         reentrant, fixed bug with symbol name compare for generating
4508         functions in absolute address,
4509         * (pic16_storeForReturn): refurnished,
4510         * (genCmp): began writing a new version of the function, not ready
4511         yet, therefore it is disabled,
4512         * (genAssign): do not read code memory when assigning a function to
4513         a pointer function,
4514         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4515         array of characters, not pointer,
4516         * (pic16initialComments): in debug mode emit an .ident directive for
4517         the assembler,
4518         * (_process_pragma): emit a new warning type (internal to pic16)
4519         when setting stack to default length, emit a similar warning when
4520         placing a function at absolute address and address is not word aligned
4521         * (_pic16_parseOptions): added 'return TRUE' statement,
4522         * (_pic16_linkEdit): if compiling a source, then add the source's
4523         file object, first in the list of objects to link,
4524
4525 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4526
4527         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4528         * src/pic/main.c : removed VC warning.
4529         * src/pic/gen.c : changed comment.
4530
4531 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4532
4533         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4534         reference to a deprecated symbol _GPTRREG was causing failure to
4535         link. Thanks G. M. Gallant for the info.
4536
4537 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4538
4539         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4540         comments for Bugs item #954788.
4541
4542 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4543
4544         * src/pic16/device.c (pic16_dump_gsection,
4545         * pic16_groupRegistersInSection): handle symbols declared to be in
4546         access bank differently,
4547         * src/pic16/gen.c (struct _G): added field resDirect,
4548         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4549         send values read from stack directly to result and don't allocate
4550         temporary values,
4551         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4552         same registers,
4553         * (pic16_sameRegsOfs): NEW,
4554         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4555         free because they were not allocated from temporary pool,
4556         * pic16_popRegFromString): workaround to fix a problem with
4557         allocating variables twice or never,
4558         * (genGenPointerGet): using PRODL instead of FSR0H,
4559         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4560         instead of FSR0H,
4561         * (genAssign): take advantage of the _G.resDirect flag,
4562         * (genCast): around line 11844, use mov2f instead of directly
4563         MOVFF'ing between operands to account for literal values,
4564         * src/pic16/genutils.c: some new debug functions for gpsim have been
4565         added,
4566         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4567         float with integer part only,
4568         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4569         place variables in access bank
4570         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4571         updated sources to reflect recent changes in gen.c
4572
4573 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4574
4575         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4576         sources that searched for headers in installation path, now the
4577         device/include/pic16 is used,
4578         * src/pic16/glue.c (pic16glue),
4579         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4580         .line directives if not in debug mode, this suppresses assembler's
4581         warnings for ignored directives
4582
4583 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4584
4585         * src/port.h: made reset_regparms prototype void parameter explicit.
4586         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4587         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4588         * doc/sdccman.lyx: documented warning disabling and how to use
4589           printf_large to make it print floats.
4590         * device/include/stdbool.h: NEW
4591         * device/lib/_atof.c,
4592         * device/lib/_divuint.c,
4593         * device/lib/_divulong.c,
4594         * device/lib/expf.c,
4595         * device/lib/printf_large.c,
4596         * device/lib/sincosf.c,
4597         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4598         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4599           a completely reentrant lib.
4600
4601 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4602
4603         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4604         * device/include/pic16/stdio.h: fixed bug with colon
4605
4606 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4607
4608         * device/include/pic16/stdio.h,
4609         * device/include/pic16/stdlib.h,
4610         * device/include/pic16/math.h: NEW
4611         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4612         declared as _naked to reduce overhead
4613         * device/lib/Makefile.in (target port-specific-objects-pic16):
4614         changed * to *.* so to ignore the CVS directory,
4615         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4616         stacked variables back in stack,
4617         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4618         corruption
4619
4620 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4621
4622         * .version: bumped version number to 2.4.5
4623         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4624         * support/Util/SDCCerr.c (messages structure): added entry for
4625         W_POSSBUG2
4626
4627         Large cumulative patch for pic16 port and libraries.
4628         * device/include/pic16/sdcc-lib.h,
4629         * device/include/pic16/stdarg.h,
4630         * device/include/asm/pic16/features.h,
4631         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4632         * device/include/pic16/float.h: changes reentrant keyword with
4633         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4634         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4635         updated target build-libraries to include objects from gptr,
4636         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4637         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4638         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4639         all function headings,
4640         * src/SDCCmain.c: added global parameter userIncDirsSet,
4641         * (parseCmdLine): when option -I is encountered add directory to
4642         userIncDirsSet too,
4643         * src/version.awk: added space between control and long,
4644         * src/pic16/NOTES: added some notes for the port,
4645         * src/pic16/gen.c: added prototype for mov2fp function,
4646         * (fReturnpic16[]): properly named return value registers,
4647         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4648         * (aopForSym): added code to handle symbols with onStack flag set,
4649         symbols onStack are allocated PTRSIZE bytes,
4650         * (aopFreeAsmop): handles special case where asmops are stack objects,
4651         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4652         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4653         added argument lock to trace flaws in allocating temporary registers
4654         when developing port,
4655         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4656         * (pic16_popRegFromString): reenabled allocating a direct register
4657         from string,
4658         * (assignResultValue): various beautifications,
4659         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4660         referenced function argument,
4661         * (genIpush): reenabled to allow stacked arguments, handles only
4662         ic->parmPush iCodes,
4663         * (genCall, genPcall): major changes to allow for variable argument
4664         functions, fixed a bug with falsely restoring stack pointer after
4665         returning from call,
4666         * (genFunction): pending code for critical function,
4667         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4668         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4669         * (genNearPointerGet): fixed bug with indirect reading, was always
4670         reading from INDF0
4671         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4672         pointers,
4673         * (genAddrOf): rewrote code to take address of a stacked function parameter
4674         * (genCast): fixed casting to generic pointer type,
4675         * src/pic16/gen.h: added AOP_STA,
4676         * (struct asmop): added field stk,
4677         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
4678         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
4679         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
4680         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
4681         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
4682         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
4683         generic pointers,
4684         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
4685         and library paths,
4686         * (pic16_port structure): generic pointer size is set to 3,
4687         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
4688         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
4689         compiler warning,
4690         * src/pic16/ralloc.c (allocReg): prevent allocating register when
4691         operand is an iTemp,
4692
4693 2004-09-24 Martin Helmling <mh AT octo-soft.de>
4694
4695         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
4696         * debugger/mcs51/simi.c: addapt new syntax of s51
4697
4698 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
4699
4700         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
4701         * src/pic16/pcode.c: commented out some calls to free() in order to
4702         fix bug #989576,
4703
4704 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4705
4706         * src/SDCCicode.h,
4707         * src/SDCCicode.c (isiCodeInFunctionCall),
4708         * src/avr/ralloc.c (selectSpil),
4709         * src/pic/ralloc.c (selectSpil),
4710         * src/pic16/ralloc.c (selectSpil),
4711         * src/ds390/ralloc.c (selectSpil),
4712         * src/hc08/ralloc.c (selectSpil),
4713         * src/xa51/ralloc.c (selectSpil),
4714         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
4715         stack in the middle of a function call sequence (fixes bug #1020268)
4716         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
4717         costs associated with the minimum switch case.
4718
4719 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4720
4721         * src/SDCC.lex: fixed bug #1030549
4722
4723 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4724
4725         * src/SDCCcse.h (struct cseDef),
4726         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
4727         over a function call if the CSE is derived from a symbol whose
4728         address has been taken (fixes bug #1029883)
4729         * support/regression/tests/bug-1029883: a new regression test for
4730         this bug
4731
4732 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4733
4734         * src/hc08/gen.c (emitinline): fixed bug #1029778
4735         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
4736         to a cast object is no longer a syntax error ("fixes" bug #1030006,
4737         and starts toward RFE #905167)
4738
4739 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
4740
4741         * src/pic16/gen.c (mov2f): New function to move an operand to
4742         another without considering if it is a literal or a register,
4743         * (pic16_sameRegs): don't check if they are both AOP_REG,
4744         * (AccRsh): removed andmask=0 lines,
4745         * (genLeftShift): duplicated to be improved in future versions,
4746         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
4747         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
4748         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
4749         * (pic16initMnemonics): added initialization for POC_INFSNZW,
4750         * (insertBankSwitch): fixed inserting banksel directives algorithm
4751         for instructions that follow a skip instruction, this fixes a report
4752         for broken subtraction code generation,
4753         * src/pic16/ralloc.c (deassignLRs): do not free register if current
4754         iCode is a left op, just in case result and right share the same
4755         registers
4756
4757 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4758
4759         * src/hc08/main.c,
4760         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
4761         preservation of HX
4762         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
4763         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
4764         on 2004-09-12; it was buggy
4765
4766 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
4767
4768         * src/SDCCsymt.h: removed RESULT_CHECK
4769         * src/SDCCast.c,
4770         * src/SDCCglue.c,
4771         * src/SDCCval.c,
4772         * src/pic/glue.c,
4773         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
4774
4775 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
4776
4777         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
4778         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
4779         configuration values no more rejected by compiler, they are assigned
4780         to configuration registers with a warning message instead,
4781         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
4782         the for-loop so last conf register is emitted too,
4783         * (_pic16_initPaths): link library libsdcc.lib by default,
4784         * (_hasNativeMulFor): modified test for multiplication according to
4785         Raphael Neider's remarks. Integer multiplication is also done with
4786         support functions,
4787         * device/include/pic16/pic18fregs.h: corrected type error in while
4788         testing and including 18f6720 header file
4789
4790 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
4791
4792         * src/pic16/device.h (pic16_options): removed field use_crt,
4793         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
4794         until an optimization to handle single bits is added,
4795         * (pic16_loadFSR0): moved before genUnpackBits,
4796         * (genAnd): some white lines removed,
4797         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
4798         leave_reset flags in pic16_options when using crt modules,
4799
4800 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
4801
4802         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
4803           for bugs 898889 & 979599. Also used some safer print instructions.
4804
4805 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
4806
4807         * src/pic16/device.h (pic16_options_t): added field use_crt,
4808         crt_name, no_crt,
4809         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
4810         catch a probable future bug,
4811         * src/pic16/gen.c: aopIdx function commented out,
4812         * (genAssign): commented out old code which used aopIdx,
4813         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
4814         code, added if conditionals to take into account the --use-crt
4815         command line options,
4816         * src/pic16/main.c (pic16_optionsTable): added new command line
4817         options, --use-crt= and --no-crt,
4818         * (_pic16_linkEdit): now the proper crt object is added in the
4819         linker command line except than when --no-crt is specified,
4820         * src/pic16/pcode.c,
4821         * src/pic16/pcode.h: added some structures and functions for a new
4822         optimization scheme to compansate for instruction overhead between
4823         same iCodes, this scheme is currently under development and is not
4824         working in any way,
4825         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
4826         to && operator,
4827         * device/lib/pic16/startup/crt0i.c,
4828         * device/lib/pic16/startup/crt0iz.c: added global char variable
4829         __uflags to force the generation of an idata section
4830
4831 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
4832
4833         * doc/Makefile,
4834         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
4835         * doc/sdccman.lyx: updated sdcc version to 2.4.4
4836
4837 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4838
4839         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
4840         Frieder) and clarified the default code optimization mode
4841
4842 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4843
4844         * src/SDCC.lex (doPragma, process_pragma),
4845         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
4846         "opt_code_size", and "opt_code_balanced"
4847         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
4848         regrouped options by category, added support for category headers
4849         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
4850         and "--opt-code-size"
4851         * doc/sdccman.lyx: documented these new options and pragmas
4852         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
4853         preference into account
4854
4855 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
4856
4857         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
4858           geniCodePreDec): Fixed bug 904237 by generating a warning
4859         * src/SDCCerr.h,
4860         * src/SDCCerr.c: added warning W_SIZEOF_VOID
4861
4862 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
4863
4864         * src/pic/device.c : When no max ram set validate full memory range.
4865         * src/pic/pcode.c,
4866         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
4867
4868 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
4869
4870         * device/lib/_gptrget.c,
4871         * device/lib/_gptrput.c: updated comment
4872         * device/lib/calloc.c,
4873         * device/lib/free.c,
4874         * device/lib/malloc.c,
4875         * device/lib/realloc.c: added LGPL, made them reentrant-safe
4876         * src/SDCCcse.c (cseBBlock),
4877         * src/SDCCicode.c (printOperand, geniCodeArray),
4878         * src/SDCCicode.h (struct operand): fixed bug 868103
4879         * support/regression/tests/bug-868103.c: added
4880         * src/SDCCast.c (searchLitOp),
4881         * src/SDCCcse.h (struct cseDef),
4882         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
4883         * src/SDCCicode.h (struct operand),
4884         * src/SDCCsymt.h (struct sym_link),
4885         * src/avr/gen.c (hasInc),
4886         * src/ds390/gen.c (hasInc),
4887         * src/hc08/gen.c (genPlusIncr, hasInc),
4888         * src/mcs51/gen.c (hasInc),
4889         * src/pic16/glue.c (pic16_printIvalChar),
4890         * src/pic16/ralloc.c (regWithIdx),
4891         * src/xa51/gen.c (hasInc) : removed warnings
4892         * src/SDCCast.c (createBlock): added comment ???
4893         * src/hc08/ralloc.c: updated comments
4894
4895 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4896
4897         * doc/sdccman.lyx: updated section on switch statements, added
4898         section about semaphore locking
4899         * doc/Makefile: added option -info for latex2html
4900         * device/lib/_gptrget.c,
4901         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
4902
4903 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
4904
4905         * src/pic/device.h,
4906         * src/pic/device.c,
4907         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
4908          maxram is less than 0x100.
4909
4910 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
4911
4912         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
4913
4914 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4915
4916         * src/port.h,
4917         * src/mcs51/main.c,
4918         * src/ds390/main.c,
4919         * src/z80/main.c,
4920         * src/hc08/main.c,
4921         * src/pic/main.c,
4922         * src/pic16/main.c,
4923         * src/avr/main.c,
4924         * src/xa51/main.c
4925         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
4926         a jump table is the best form for a switch statement, including
4927         automatic insertion of missing cases to make the case range
4928         continuous. Developed in collaboration with Frieder Ferlemann.
4929
4930 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4931
4932         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
4933         accumulator result if it needs sign extension
4934
4935 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4936
4937         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
4938
4939 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4940
4941         * device/lib/gbz80/printf.c,
4942         * device/lib/z80/printf.c: removed define for NULL
4943
4944 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
4945
4946         * as/xa51/xa_link.c,
4947         * device/examples/ds390/ow390/ad26.c,
4948         * device/examples/ds390/ow390/cnt1d.c,
4949         * device/examples/ds390/ow390/counter.c,
4950         * device/examples/ds390/ow390/ds2480.h,
4951         * device/examples/ds390/ow390/ds2480ut.c,
4952         * device/examples/ds390/ow390/findtype.c,
4953         * device/examples/ds390/ow390/gethumd.c,
4954         * device/examples/ds390/ow390/owllu.c,
4955         * device/examples/ds390/ow390/ownetu.c,
4956         * device/examples/ds390/ow390/swt12.c,
4957         * device/examples/ds390/ow390/swtloop.c,
4958         * device/examples/ds390/ow390/temp.c,
4959         * device/examples/ds390/ow390/temp10.c,
4960         * device/examples/ds390/ow390/thermo21.c,
4961         * device/examples/ds390/ow390/tinilnk.c,
4962         * device/examples/ds390/ow390/tstfind.c,
4963         * device/examples/serialcomm/windows/serial.cpp,
4964         * device/examples/serialcomm/windows/test_serialcomm.cpp,
4965         * device/include/reg51.h: fixed line endings for cvs
4966
4967 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4968
4969         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
4970         packRegsForAccUse, packRegisters): new accumulator register
4971         packing algorithm
4972         * support/regression/ports/hc08/support.c (_putchar): suppress
4973         warning of unused variable
4974         * src/SDCCicode.c: added SWAP entry to codeTable
4975
4976 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
4977
4978         * device/lib/sprintf.c: forgot to add this file before previous commit
4979
4980 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
4981
4982         * src/pic16/gen.c (genPackBits): added operand right in function
4983         parameters, load result directly if p_type is POINTER (that is
4984         called by genNearPointerSet)
4985         * (genUnPackBits): added operand left in function parameters,
4986         * (genNearPointerGet, genNearPointerSet): prevent the loading of
4987         FSR0 if accessing bitfields,
4988
4989 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
4990
4991         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
4992           _print_format; updated printf, sprintf, vsprintf
4993         * device/include/asm/default/features.h: corrected comment/define
4994         * device/lib/Makefile.in: added sprintf.c
4995         * device/lib/libsdcc.lib: added sprintf module
4996         * device/lib/printf_large.c,
4997         * device/lib/vprintf.c,
4998         * device/lib/sprintf.c: totally refactored printf_large and vprintf
4999           into these 3 files
5000         * support/regression/Makefile: changed ALL_PORTS into a usefull default
5001         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
5002         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
5003           hc08 test
5004         * support/regression/tests/zeropad.c: define idata as data for hc08
5005
5006 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5007
5008         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
5009         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
5010         labels are referenced at least once (even if a reference is not found)
5011         * src/hc08/gen.c (emitcode): set isComment flag for comments
5012         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
5013         loads), rules 6a..6b (optimize jumps to return)
5014
5015 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5016
5017         * device/lib/acosf.c (acosf),
5018         * device/lib/asinf.c (asinf),
5019         * device/lib/atanf.c (atanf),
5020         * device/lib/ceilf.c (ceilf),
5021         * device/lib/cosf.c (cosf),
5022         * device/lib/coshf.c (coshf),
5023         * device/lib/cotf.c (cotf),
5024         * device/lib/fabsf.c (fabsf),
5025         * device/lib/floorf.c (floorf),
5026         * device/lib/log10f.c (log10f),
5027         * device/lib/logf.c (logf),
5028         * device/lib/sinf.c (sinf),
5029         * device/lib/sinhf.c (sinhf),
5030         * device/lib/sqrtf.c (sqrtf),
5031         * device/lib/tanf.c (tanf),
5032         * device/lib/tanhf.c (tanhf),
5033         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
5034         replaced all instances of "reentrant" in the library functions
5035         defined in math.h with this macro.
5036         * support/regression/tests/float_trans.c: reenabled test for hc08
5037
5038 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
5039
5040         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
5041         erroneously deleted
5042
5043 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5044
5045         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
5046         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
5047         multi-byte volatile operands are used
5048         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
5049         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
5050         initialization to area GSINIT0 so that it would always precede
5051         any static initializers in GSINIT
5052         * support/regression/tests/zeropad.c: fixed idata define for hc08
5053         * support/regression/tests/bug-927659.c,
5054         * support/regression/tests/float_trans.c: disabled tests for hc08
5055         pending missing library routines
5056         * .version: increased version number to 2.4.4 - hc08 port now passes
5057         regression tests
5058
5059
5060 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
5061
5062         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
5063         * Makefile.common.in,
5064         * as/Makefile,
5065         * as/hc08/Makefile.in,
5066         * as/mcs51/Makefile.in,
5067         * as/z80/Makefile.in,
5068         * debugger/mcs51/Makefile.in,
5069         * device/include/Makefile.in,
5070         * device/lib/Makefile.in,
5071         * doc/Makefile,
5072         * link/Makefile,
5073         * link/z80/Makefile.in,
5074         * packihx/Makefile.in,
5075         * sim/ucsim/main_in.mk,
5076         * sim/ucsim/avr.src/Makefile.in,
5077         * sim/ucsim/doc/Makefile.in,
5078         * sim/ucsim/gui.src/serio.src/Makefile.in,
5079         * sim/ucsim/hc08.src/Makefile.in,
5080         * sim/ucsim/s51.src/Makefile.in,
5081         * sim/ucsim/xa.src/Makefile.in,
5082         * sim/ucsim/z80.src/Makefile.in,
5083         * src/Makefile.in,
5084         * support/cpp2/Makefile.in,
5085         * support/librarian/Makefile,
5086         * support/makebin/Makefile: added DESTDIR to the install path proposed
5087         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
5088         * doc/sdccman.lyx: added DESTDIR documentation
5089
5090 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
5091
5092         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
5093         instruction for interrupt handlers, use fast returns when returning
5094         from high priority interrupts
5095
5096 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5097
5098         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
5099         code generation
5100         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
5101         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
5102         bugs, ported much of Bernhard's code from mcs51
5103         * src/mcs51/gen.c (genSend),
5104         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
5105         than one when calling a reentrant function
5106         * device/lib/_mullong.c: defined an alternate struct layout for big
5107         endian ports (hc08)
5108
5109 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5110
5111         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
5112         test
5113
5114 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5115
5116         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
5117         are sane and complete before asking the port its prefered parameter
5118         passing method (fixes bug #1017633)
5119         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
5120         and _ret3
5121
5122 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5123
5124         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
5125         problem in bitfields >= 8 bits.
5126
5127 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5128
5129         * src/SDCCsymt.c: undid changes that were not meant to be committed
5130
5131 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5132
5133         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
5134
5135 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5136
5137         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
5138           copied and wrong bit got inverted
5139
5140 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5141
5142         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5143         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5144         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5145         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5146         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5147         assignments to bitfields at known addresses
5148         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5149         reads from bitfields at known addresses
5150         * src/hc08/ralloc.c (packRegisters),
5151         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5152         genhc08Code): optimize pointer get values used as conditionals
5153         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5154         and branch
5155
5156 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5157
5158         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5159         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5160         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5161         as conditionals
5162
5163 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5164
5165         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5166
5167 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5168
5169         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5170         related problems
5171
5172 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5173
5174         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5175
5176 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5177
5178         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5179         mcs51 port
5180
5181 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5182
5183         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5184
5185 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5186
5187         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5188         cases use more compact code.
5189
5190 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5191
5192         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5193
5194 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5195
5196         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5197
5198 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5199
5200         * src/SDCCsymt.h,
5201         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5202         parameter of changePointer() from symbol* to sym_link*
5203         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5204         * src/SDCCsymt.c (compareType): void* type is castable to other
5205         pointers, but not necesarily an exact match.
5206         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5207         is no longer blindly treated as an exact match.
5208         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5209
5210 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5211
5212         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5213
5214 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5215
5216         * src/pic/gen.c,
5217         * src/pic/pcode.c,
5218         * src/pic/ralloc.h,
5219         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5220
5221 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5222
5223         * src/pic/device.c,
5224         * src/pic/device.h,
5225         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5226
5227 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5228
5229         * src/mcs51/gen.c (emitcode): fixed bug #992819
5230
5231 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5232
5233         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5234           there's no need to make it worse
5235
5236 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5237
5238         * src/mcs51/ralloc.c (deassignLR),
5239         * src/ds390/ralloc.c (deassignLR),
5240         * src/hc08/ralloc.c (deassignLR),
5241         * src/z80/ralloc.c (deassignLR),
5242         * src/pic/ralloc.c (deassignLR),
5243         * src/pic16/ralloc.c (deassignLR),
5244         * src/avr/ralloc.c (deassignLR),
5245         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5246         rlivePoint): fixed another part of bug #971834
5247
5248 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5249
5250         * src/z80/main.c: enabled "critical" keyword
5251         * src/z80/mappings.i,
5252         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5253         functions (fixes bug #979646)
5254         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5255
5256 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5257
5258         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5259           such as c:\mydir.
5260
5261 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5262
5263         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5264           doesn't disable too much optimizations
5265
5266 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5267
5268         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5269
5270 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5271
5272         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5273
5274 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5275
5276         * src/pic/gen.c tidied up tabs
5277         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5278         * src/pic/main.c tidied up tabs
5279         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5280         * src/pic/pcoderegs.c tidied up tabs
5281         * src/pic/ralloc.c tidied up tabs
5282
5283 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5284
5285         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5286         to S_FIXED for pic16 port and when symbol is not in level 0,
5287         allocate for S_REGISTER storage class and pic16 port, too,
5288         * src/pic16/device.h: prototype for checkSym,
5289         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5290         * (pic16_assignConfigWordValue): test the value and the mask to
5291         validate that the value is suitable for the configuration word,
5292         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5293         collect extern declared symbols, don't emit symbol twice, check
5294         first if symbol is in publics set first,
5295         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5296         * added command line '--fstack' which enables an experimental
5297         feature for stack access, too buggy to be used yet...
5298         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5299         * (pic16_allocDirReg): when register has storage class S_REGISTER
5300         allocate in pic16_dynAccessRegs,
5301         * device/include/pic16/pic18f????.h: modified configuration word
5302         naming convention, words started as CONFIG0H but should be CONFIG1H
5303
5304 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5305
5306         * device/include/mcs51reg.h: fixed bug 970993
5307
5308 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5309
5310         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5311         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5312         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5313         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5314         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5315         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5316           error/warning numbers,
5317           added function setWarningDisabled()
5318         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5319         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5320           _memcmp.c _memmove.c calloc.c realloc.c free.c
5321         * support/regression/tests/malloc.c: added tests for new functionality
5322         * support/regression/tests/zeropad.c: added tests for truncated initializers
5323           and initialized char arrays starting with '\x0'
5324         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5325
5326 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5327
5328         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5329
5330 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5331
5332         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5333         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5334         peephole 177.e. Thanks to anonymous
5335
5336 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5337
5338         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5339         function isn't used in the source but referenced as a
5340         variable initializer then declare it as extern in .asm file
5341
5342 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5343
5344         * .version: increased version number to 2.4.3
5345
5346         Adding version extension according to ChangeLog CVS revision
5347         * src/Makefile.in (target all): added dependency 'version.h'
5348         * (rule version.h): added rule to create version.h from ChangeLog,
5349         * (rule dep): added dependency version.h,
5350         * src/version.awk: AWK script to create version.h
5351         * src/SDCCdwarf2.c (dwWriteModule),
5352         * src/SDCCglue.c (initialComments),
5353         * src/SDCCmain.c (printVersionInfo): modified to write after
5354         version string the version extension number,
5355         * src/SDCCutil.c: included "version.h"
5356         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5357         number,
5358         * src/SDCCutil.h: added prototype for getBuildNumber
5359
5360         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5361         includeDirsSet, too,
5362         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5363         const char [] is found in function prototype...
5364
5365         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5366         moving to WREG with source is already in WREG,
5367         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5368         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5369         * (aopForSym): stack'ed symbols are partially supported, added
5370         if-clause to support symbols in FARSPACE,
5371         * (sameRegs): added test for AOP_ACC to see if registers are same,
5372         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5373         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5374         * (pic16_popRegFromString): will not allocate a new register if it
5375         doesn't find one by name, bug may have introduced...
5376         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5377         * (genIpush): revived to use pic16 port's stack,
5378         * (genAddrOf): added incomplete case for stack'ed operand,
5379         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5380         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5381         can handle multibyte operands,
5382         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5383         * (pic16initialComments): added message for MPLAB compatibility
5384         mode enabled,
5385         * src/pic16/main.h: prototype for pic16_mplab_comp,
5386         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5387         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5388         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5389         because of increased complexity of procedure,
5390         * (_process_pragma): stack pragma changed to format 'stack pos len',
5391         emit symbol '_stack_end' to conform with gplink,
5392         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5393         to search for register,
5394         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5395         PO_GPR_REGISTER,
5396         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5397         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5398         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5399         case for PO_GPR_REGISTER,
5400         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5401         dies, the new era is ahead !...
5402         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5403         pic16_dynInternalRegs,
5404         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5405         * (pic16_allocDirReg): minor optimizations and bug fixes,
5406         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5407
5408         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5409         load stack and frame pointer with address of 'stack_end' symbol
5410
5411 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5412
5413         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5414         without source code but only variable initializers
5415
5416 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5417
5418         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5419         external are not declared as extern to reduce overhead while linking
5420
5421 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5422
5423         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5424
5425 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5426
5427         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5428           Yee Keat for the patch
5429         * src/SDCCast.c (decorateType): fixed bug #979599
5430         * src/ds390/gen.h: removed local fReturnSizeDS390
5431         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5432         * src/ds390/gen.c (genAnd, genOr, genXor),
5433         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5434
5435 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5436
5437         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5438         add relFilesSet to $3, manipulate $2 to handle linking of object
5439         files without source files in command line,
5440         * device/include/pic16 (all headers): added ID location macros,
5441         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5442         entries for ID location bytes,
5443         * (pic16_assignIdByteValue): NEW,
5444         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5445         added field dumpcalltree to pic16_options_t,
5446         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5447         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5448         emitting rFalseIfx label after check_carry label,
5449         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5450         pic16_emitDIRegs), NEW
5451         * (pic16glue): dump .calltree file when option --calltree found,
5452         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5453         * (_pic16_genAssemblerPreamble): emit ID locations after
5454         configuration registers,
5455         * (pic16_linkCmd): modifications of the link command,
5456         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5457         * (pic16_pCodeInitRegisters): don't init stack registers,
5458         * (pic16_findPrevInstruction): fixed bug,
5459         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5460         bug with immediate registers,
5461         * (buildCallTree): traces stack push and pop,
5462         * (pct2): dump also stack usage for each function,
5463         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5464         * (pic16_allocDirReg): various modifications,
5465         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5466         fixed to 1,
5467
5468 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5469
5470         * src/pic16/pcode.c: removed buggy double colon
5471
5472 2004-07-01 Borut Razem <borut.razem AT siol.net>
5473
5474         * support/scripts/sdcc.nsi: added include/pic16 to setup
5475
5476 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5477
5478         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5479         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5480         target 'clean',
5481         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5482         specific command line arguments. Also added sample lkr script
5483         for placing a variable at a specific memory bank.
5484         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5485         at a specific memory bank,
5486         * (pic16_dump_isection): fixed bug which caused string literals to
5487         be omitted when dumping idata section,
5488         * (pic16_groupRegistersInSection): added code to handle registers
5489         in specific memory banks,
5490         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5491         public, all references are renamed too,
5492         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5493         AOP_DPTR2,
5494         * (pic16_storeForReturn): added case to handle when dest is WREG,
5495         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5496         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5497         pic16_rel_udata, check to see if that register is marked as being
5498         a member of a specific memory bank,
5499         * (pic16_printIvalCharPtr): added code to add string literals either
5500         to code or the idata sections,
5501         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5502         also accept the 'udata' pragma,
5503         * src/pic16/main.h: new structure types sectName and sectSym
5504         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5505         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5506         * (pic16_findPrevInstruction): fixed, it returned nothing,
5507         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5508         instruction combinations,
5509         * (pic16_FixRegisterBanking): heavily reorganised,
5510         * (pic16_AnalyzeBanking): if generating banksel directives is
5511         disabled, then don't call FixRegisterBanking at all,
5512         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5513         completely removed,
5514         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5515
5516 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5517
5518         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5519         Phuah Yee Keat <yk.phuah AT nestac.com>
5520
5521 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5522
5523         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5524         correctly the IVT even if it is relocated to some other location
5525
5526 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5527
5528         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5529         * device/include/pic16/pic18f2220.h: NEW,
5530         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5531         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5532         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5533         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5534         nodefaultlibs, ivt_loc is the location of the interrupt vector
5535         table, and nodefaultlibs signs that default libraries should not be
5536         linked in link stage,
5537         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5538         according to --ivt-loc argument,
5539         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5540         when pragma stack is found,
5541
5542 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5543
5544         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5545         256 (range check), 257 (do while), 258.a-f (bit banging
5546         f.e. on 3-wire SPI bus)
5547
5548 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5549
5550         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5551         variables used exclusively within a loop
5552
5553 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5554
5555         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5556
5557 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5558
5559         * src/SDCClrange.c (computeClash): fixed bug #971834
5560
5561 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5562
5563         * src/mcs51/gen.c (genCmp): fixed bug #975903
5564         * src/hc08/gen.c (operandsEqu),
5565         * src/ds390/gen.c (operandsEqu),
5566         * src/z80/gen.c (operandsEqu),
5567         * src/pic/gen.c (operandsEqu),
5568         * src/pic16/gen.c (operandsEqu),
5569         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5570         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5571
5572 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5573
5574         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5575
5576 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5577
5578         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5579         default case in switch statement,
5580         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5581         to eliminate problem with initialisation of pointers, but problem
5582         still exists,
5583         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5584         * (emitStaticSegment): removed various lines emitting debug info,
5585         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5586         added processor registers for utilizing EEPROM,
5587         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5588         configurable and set 8
5589
5590 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5591
5592         * .version: increased version number to 2.4.2,
5593
5594         Cumulative patch for pic16 port
5595         * src/pic16/device.c: changed scheme to dump initial values for
5596         variables in idata segment, all print_idata* functions were removed,
5597         now the pic16_printIval* will be called,
5598         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5599         * _pic16_printPointerType, pic16_printPointerType,
5600         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5601         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5602         NEW, similar to the respective functions in SDCCglue.c,
5603         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5604         way, emitting hex bytes,
5605         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5606
5607 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5608
5609         * src/avr/ralloc.c (serialRegAssign),
5610         * src/xa51/ralloc.c (serialRegAssign),
5611         * src/pic/ralloc.c (serialRegAssign),
5612         * src/pic16/ralloc.c (serialRegAssign),
5613         * src/hc08/ralloc.c (serialRegAssign),
5614         * src/z80/ralloc.c (serialRegAssign),
5615         * src/ds390/ralloc.c (serialRegAssign),
5616         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5617
5618 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5619
5620         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5621         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5622
5623 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5624
5625         Cumulative patch for pic16 port:
5626         * src/pic16/device.h (typedef PIC16_device) modified fields for
5627         defining microcontrollers,
5628         * src/pic16/device.c: added new info for all devices in Pics16 array,
5629         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5630         to be optimised out by the pCode optimiser,
5631         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5632         specially, bug reported by G.M. Gallant,
5633         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5634         as force'd so that cannot be optimised out by pCode optimiser,
5635         * src/pic16/pcode.c,
5636         * src/pic16/pcodepeeph.c,
5637         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5638         they are disabled by default, but can be enabled explicit with
5639         command argument --denable-peeps, for testing,
5640         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5641         --pomit-ivt in COMPILE_FLAGS
5642
5643 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5644
5645         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5646           compilation on MSVC
5647
5648 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5649
5650         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5651
5652 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5653
5654         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5655         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5656
5657 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5658
5659         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5660         would only assign 0x300001 register.
5661
5662 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5663
5664         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5665         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5666
5667 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5668
5669         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5670         for ds80c400
5671         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5672         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5673         added peephole 254 (left shift), 255 (jump table)
5674
5675 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
5676
5677         * device/lib/Makefile.in: removed comment line with model-pic16,
5678         * (target port-specific-objects-pic16): the libraries and objects
5679         are copied to the build directory form the device/lib/pic16/bin
5680         directory
5681
5682         Cumulative patch concerning pic16 port:
5683         * library directory has been re-organized,
5684         * added support for PIC18F1220,
5685         * added headers and library sources for chips 18f1220,18f6520,
5686         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
5687
5688         * configuration registers setting has changed, now each supported
5689         device has a complete description of the registers it uses,
5690         * all initialisations are moved to idata sections, these section
5691         can be absolute or relocatable,
5692         * fixed initialisation of codespace variables,
5693         * fixed warning about PCLATU and gpsim,
5694         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
5695         * (genAssign): use table reads when assigning from variables in codespace,
5696         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
5697         char/int variables placed in codespace,
5698         * (pic16_emitConfigRegs): NEW, emits a list with configuration
5699         registers set in .asm file, no need for --pomit-config-words anymore,
5700         * (pic16glue): some 8051 legacy segments are commented out
5701         (to be removed completely),
5702         * added support for alternative assembler and linker with --asm=
5703         and --link= command line arguments,
5704         * peepholes are disabled automatically in the port, no need to
5705         specify on command line,
5706         * port supports natively char/int/long multiplication, but converts
5707         all divisions to support functions,
5708         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
5709         to the file set in variable $2,
5710         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
5711         strings in ASCII format and not in hex,
5712         * ralloc.c (serialRegAssign): added a triplet of conditional calls
5713         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
5714         allocate proper register if iCodes aren't temporary,
5715
5716 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
5717
5718         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
5719
5720 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
5721
5722         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
5723         is commented out
5724
5725 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5726
5727         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
5728         computed address is reused
5729         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
5730         multi-byte bitfields
5731
5732 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5733
5734         * src/z80/gen.c: (genArrayInit): must check for pointers too
5735
5736 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5737
5738         * support/regression/tests/zeropad.c: never meant to commit the
5739           nestedstruct test: removed, added check for GCC version
5740
5741 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
5742
5743         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
5744         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
5745         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
5746           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
5747           bugs 928906 and 954082 half-empty initializers
5748         * src/SDCCsymt.h,
5749         * src/SDCCsymt.c (getAllocSize): added for above fix
5750         * src/z80/gen.c (genArrayInit): fixed bug 741044
5751         * support/regression/tests/zeropad.c: added tests
5752
5753 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
5754
5755         * src/pic16/device.c (pic16_dump_section): corrected bug which
5756         caused some symbols of the libraries to be misplaced
5757
5758 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5759
5760         * src/pic16/glue.c,
5761         * src/pic16/ralloc.h,
5762         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
5763         to fix conflict with pic port
5764
5765 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5766
5767         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
5768         externs configuration variables,
5769         * src/pic16/ralloc.h,
5770         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
5771         prototype in header, commented out some debug messages
5772
5773 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
5774
5775         * src/pic16/glue.c,
5776         * src/pic16/main.c,
5777         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
5778         for gpasm COFF object generation. Thanks to D. Hawkins for
5779         his patch info
5780
5781 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5782
5783         * src/ds390/main.c,
5784         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
5785         Brock for spotting this)
5786         * src/ds390/gen.c (genEndFunction),
5787         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
5788         interrupt handler and critical. Disable push/pop optimizations when
5789         peephole optimizations disabled.
5790
5791 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5792
5793         Updated pic16 library sources and headers.
5794         * device/lib/pic16/pic18f*/ ,
5795         * device/include/pic16/*.h: modified to handle structured SFR
5796         definitions
5797
5798 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5799
5800         * src/port.h (PORT structure): added hook initPaths, now each
5801         port can declare its own default search paths,
5802         which can been seen with the --print-search-dirs option,
5803         see pic16 port for example,
5804         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
5805         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
5806         * (doPrintSearchDirs): NEW, replaces in a central manner the
5807         printing of search dirs which was split in set*Paths functions,
5808         * (main): added call to port->initPaths and doPrintSearchDirs,
5809         * src/avr/main.c,
5810         * src/ds390/main.c,
5811         * src/hc08/main.c,
5812         * src/izt/i186.c,
5813         * src/izt/tlcs900h.c,
5814         * src/mcs51/main.c,
5815         * src/pic/main.c,
5816         * src/pic16/main.c: modified port structures to reflect addition of
5817         initPaths hook,
5818
5819         * src/pic16/device.c (regCompare): registers are finally sorted by name,
5820         * (pic16_dump_section): for registers in same address reserve memory once,
5821         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
5822         to no_banksel,
5823         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
5824         result is greater in size than right or left,
5825         * (pic16_genUMult8X8_8): there are some cases where the result can
5826         be 16 bits size, so handle these,
5827         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
5828         * (pic16_outBitC): modified to emit pcodes,
5829         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
5830         or not,
5831         * (genDivOneByte): implemented algorithm to divide 8-bits,
5832         * (genCmp): uncommented goto, but issues still exist,
5833         * (genAnd): fixed a bug with variables >8bits,
5834         * (genPackBits): optimization added that uses BCF/BSF to change a
5835         single bit,
5836         * (genAssign): fixed bug when assigning floating point literals,
5837         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
5838         __sdcc_gsinit_startup label,
5839         * src/pic16/main.c (_pic16_init): removed search directory
5840         initialisations,
5841         * (_pic16_initPaths): NEW, used to initialise search directories,
5842         * (_hasNativeMulFor): support functions for all except char/int
5843         multiplication, and char division,
5844         * (PIC16_port struct): modified entry for native mul support,
5845         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
5846         no_banksel option,
5847         * (buildCallTree): call to register_usage is ifdef'ed out,
5848
5849 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5850
5851         * device/include/string.h: applied Stas Sergeev's patch to make this
5852         header file compatible with the preprocessor -Wundef option
5853         * src/SDCCmain.c (main): abort compilation if preprocessor reports
5854         failure (fixes bug #941458)
5855
5856 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5857
5858         * src/SDCCopt.c (killDeadCode): fixed bug #907733
5859         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
5860         that the variable, not the function, should be static
5861         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
5862         to be consistent with non-literal case
5863
5864 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5865
5866         * src/SDCCast.c (isConformingBody): fixed bug #949967
5867         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
5868         convilong): fixed bug #952086
5869
5870 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5871
5872         * src/SDCCmem.c (allocVariables): fixed bug #955321
5873
5874 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5875
5876         * src/hc08/main.c (_hc08_genAssemblerEnd),
5877         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
5878         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
5879         completely eliminated the use of a temporary file
5880         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
5881         when more than one file linked
5882         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
5883
5884 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5885
5886         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
5887         which fixes bug #543481
5888         * support/regression/tests/bug-751703.c: fixed comments left from a
5889         cut and paste error
5890         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
5891         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
5892         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
5893         scopes
5894         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
5895         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
5896         are now changed to underscores in moduleName
5897
5898 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5899
5900         * as/mcs51/lkmem.c: better fix for bug #954173
5901
5902 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
5903         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5904
5905         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
5906         * device/include/c8051f000.h,
5907         * device/include/c8051f120.h,
5908         * device/include/c8051f300.h,
5909         * device/include/c8051f310.h,
5910         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
5911         PWM16) and detab'ed
5912
5913 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5914
5915         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
5916         and mailing lists, doc'ed --no-peep-comments, removed reference
5917         to knoppix (newest version has no LyX/LaTeX), other minor changes
5918         * src/SDCCglue.c (glue): save 2 bytes stack space with
5919         option --main-return. The ljmp could probably be avoided too
5920
5921 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5922
5923         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
5924
5925 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5926
5927         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
5928         * src/SDCCopt.c (isLocalWithoutDef),
5929         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
5930         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
5931         (credit to Maarten Brock for patch #949363, on which this is based)
5932         * support/regression/tests/bug-751703.c: some test cases of extern used
5933         within inner scopes.
5934
5935 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5936
5937         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
5938         SPEC_STRUCT
5939         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
5940         struct definitions
5941         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
5942         dwWriteLabel): fix to create valid debugger symbols even when
5943         the module name has non-alphanumeric symbols in it
5944         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
5945         when a variable's allocation has been optimized away
5946
5947
5948 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5949
5950         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
5951         * src/hc08/main.c,
5952         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
5953         * src/mcs51/main.c,
5954         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
5955         * src/ds390/main.c,
5956         * src/z80/gen.c (z80_emitDebuggerSymbol),
5957         * src/z80/main.c,
5958         * src/pic/gen.c (pic14_emitDebuggerSymbol),
5959         * src/pic/main.c,
5960         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
5961         * src/pic16/main.c,
5962         * src/avr/gen.c (avr_emitDebuggerSymbol),
5963         * src/avr/main.c,
5964         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
5965         * src/xa51/main.c,
5966         * src/SDCCdebug.c (emitDebuggerSymbol),
5967         * src/SDCCdebug.h,
5968         * src/port.h: added a debugger struct to the port struct. Added a
5969         callback for defining debugger symbols
5970
5971         * src/SDCCast.c (createLabel),
5972         * src/SDCC.y (labeled_statement): mark all compiler generated labels
5973         with isitmp = 1
5974         * src/SDCCicode.h,
5975         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
5976         iCode back to the ast for the function
5977
5978         * src/hc08/ralloc.c (hc08_assignRegisters),
5979         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
5980         unneeded fields from the regs struct.
5981         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
5982         pushReg() & pullReg() functions instead of emitcode()
5983
5984         * src/hc08/gen.c (genLabel, genhc08Code),
5985         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
5986
5987         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
5988         debugger hooks
5989
5990         * src/hc08/gen.c (genEndFunction, genhc08Code),
5991         * src/hc08/gen.h,
5992         * src/mcs51/gen.c (genEndFunction, gen51Code),
5993         * src/mcs51/gen.h,
5994         * src/ds390/gen.c (genEndFunction, gen390Code),
5995         * src/ds390/gen.h,
5996         * src/z80/gen.c (genEndFunction, genZ80Code),
5997         * src/z80/gen.h,
5998         * src/z80/z80.h,
5999         * src/pic/gen.c (genEndFunction, genpic14Code),
6000         * src/pic/gen.h,
6001         * src/pic16/gen.c (genEndFunction, genpic16Code),
6002         * src/pic16/gen.h,
6003         * src/avr/gen.c (genEndFunction, genAVRCode),
6004         * src/avr/gen.h,
6005         * src/xa51/gen.c (genEndFunction, genXA51Code),
6006         * src/xa51/gen.h,
6007         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
6008         specific code to cdbFile.c and out of the backend code generators
6009
6010         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
6011         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
6012         starting address is now 0
6013
6014         * as/hc08/asm.h,
6015         * as/hc08/m08pst.c,
6016         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
6017         assembler directive for DWARF support
6018         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
6019
6020         * src/src.dsp,
6021         * src/Makefile.in,
6022         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
6023
6024 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6025
6026         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
6027         and inappropriate peephole optimization in jump tables
6028
6029 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6030
6031         * as/hc08/m08pst.c,
6032         * src/SDCCglue.c: sdccopt works for the hc08 port now
6033
6034 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
6035
6036         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
6037
6038 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6039
6040         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
6041
6042 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6043
6044         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
6045         rules
6046         * src/SDCCmain.c,
6047         * src/SDCCglobl.h,
6048         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
6049         comments from the peephole optimizer replacement rules
6050         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
6051         symbols
6052         * src/SDCCcse.c (updateSpillLocation),
6053         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
6054         equivalents
6055         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
6056         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
6057         objects far pointers
6058
6059 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6060
6061         * src/SDCCsymt.h: a missing part of my last change
6062         * src/pic/ralloc.c (regTypeNum),
6063         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
6064
6065 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6066
6067         * src/SDCCicode.h,
6068         * src/SDCCicode.c (aggrToPtrDclType),
6069         * src/SDCCptropt.h,
6070         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
6071         ptrPseudoSymConvert),
6072         * src/pic/ralloc.c (regTypeNum),
6073         * src/pic16/ralloc.c (regTypeNum),
6074         * src/hc08/ralloc.c (regTypeNum),
6075         * src/ds390/ralloc.c (regTypeNum),
6076         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
6077         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
6078
6079 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6080
6081         * link/z80/lkmain.c (afile),
6082         * as/hc08/lkmain.c (afile),
6083         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
6084         prevent a pointer problem when a filename has no directory and
6085         no extension specified.
6086
6087 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6088
6089         * link/z80/lkmain.c (afile): allow periods in directory names
6090         * link/z80/lkmain.c (afile),
6091         * as/mcs51/lkmain.c (afile),
6092         * as/hc08/lkmain.c (afile): allow linker script file to have an
6093         extension other than ".lnk"
6094         * link/z80/lklex.c (getfid),
6095         * link/z80/lkmain.c (parse),
6096         * as/mcs51/lklex.c (getfid),
6097         * as/mcs51/lkmain.c (parse),
6098         * as/hc08/lklex.c (getfid),
6099         * as/hc08/lkmain.c (parse): Support comments in the linker script
6100         file on lines by themselves and after filenames
6101
6102 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6103
6104         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
6105
6106 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6107
6108         * src/z80/peeph-z80.def: removed some peephole rules that don't
6109         work with multibyte arithmetic (fixed bug #937126)
6110         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
6111         to registers and not global variables
6112         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
6113         geniCodePreInc, geniCodePostDec, geniCodePreDec,
6114         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
6115         checking for assignments not internally generated (fixed bug #931895)
6116         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
6117         structure member (fixed bug #930072)
6118
6119 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6120
6121         * src/SDCCmain.c (linkEdit),
6122         * src/hc08/main.c (_hc08_parseOptions),
6123         * as/hc08/Makefile.in,
6124         * as/hc08/aslink.h,
6125         * as/hc08/asm.h,
6126         * as/hc08/m08pst.c,
6127         * as/hc08/lkrloc.c (relr, rele),
6128         * as/hc08/lkarea.c (lnkarea)
6129         * as/hc08/lkmain.c (afile, parse),
6130         * as/hc08/lkelf.c: support for ELF output
6131         * as/hc08/lks19.c (s19),
6132         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
6133
6134 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6135
6136         * as/mcs51/lkihx.c: Fixed bug #899105.
6137
6138 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6139
6140         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6141         .dsp files from Unix to DOS.
6142
6143 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6144
6145         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6146         function pointers; we have been compliant for several months now.
6147         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6148         change that was accidently commented out
6149         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6150         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6151         bug #922319
6152
6153 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6154
6155         * src/hc08/gen.c: output of all of the internal debugging information
6156         is now controlled by the D() macro; it is disabled by default
6157
6158 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6159
6160         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6161         harder to keep the same registers during a CAST iCode
6162         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6163         long via int can be done in a single cast, if the signedness is
6164         correct.
6165         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6166         putchar() in tinibios.c in ds390's library
6167
6168 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6169
6170         * src/SDCCast.c (decorateType): fixed bug #898889,
6171         cast result of a literal complement too
6172         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6173         fixed check for bitfields
6174
6175 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6176
6177         * src/SDCCicode.c (geniCodeLogic): made it static,
6178         (geniCodeLogicAndOr): added in order to fix bug #905492,
6179         (ast2iCode): fixed bug #905492
6180         * support/regression/tests/bug-905492.c: added
6181         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6182         (processParms): fixed bug #927659: don't copy parms, this will clear
6183         decorated flag
6184         * support/regression/tests/bug-927659.c: added
6185
6186 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6187
6188         * src/SDCCast.c (addCast): don't cast float to char
6189         * device/lib/libsdcc.lib: added _memmove
6190
6191 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6192
6193         * device/lib/large/Makefile: fixed parallel execution by
6194         replacing `make` by `$(MAKE)`
6195
6196 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6197
6198         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6199         offsets (fixes bug #923936)
6200
6201 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6202
6203         * device/lib/small/Makefile: fixed parallel execution by
6204         replacing `make` by `$(MAKE)`
6205
6206 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6207
6208         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6209
6210 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6211
6212         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6213         * src/regression/Makefile: Regression test was not running.
6214
6215 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6216
6217         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6218         complement if possible
6219         * src/SDCCval.c (valComplement),
6220         * src/SDCCicode.c (operandOperation): fixed complement of literal
6221         * support/regression/tests/onebyte.c (testComplement): added
6222
6223 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6224
6225         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6226         return an optimized tree; actually replace actParm with the new tree
6227         * src/SDCCast.h: added some parantheses to remove side effects
6228         * support/regression/tests/bug-920866.c
6229
6230 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6231         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6232         Bit operands were not being handled properly in the pic14 port.
6233         (now src/regression/add.c passes again).
6234
6235 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6236
6237         * src/SDCC.y (labeled_statement): case and default no longer require
6238         a following statement (RFE #893037)
6239
6240 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6241
6242         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6243         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6244         disabled (fixes bug #916294)
6245         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6246         "mov a,acc"; patch provided by Lenny Story
6247         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6248
6249 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6250
6251         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6252         functions
6253         * src/ds390/gen.c (genFunction, genEndFunction),
6254         * src/ds390/ralloc.c (ds390_assignRegisters),
6255         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6256         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6257         pushed if there are parameters passed on the stack. Also, a cleaner
6258         way to decide if r0/r1 should be pushed/popped. (Together they fix
6259         bug #918693)
6260
6261 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6262
6263         * doc/sdccman.lyx,
6264         * device/lib/mcs51/crtpagesfr.asm,
6265         * device/lib/mcs51/crtxinit.asm,
6266         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6267         to avoid confusion with Si Lab's SFRPAGE register.
6268
6269 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6270
6271         * src/SDCCglue.c (emitMaps): allow public sfr variables
6272         * src/SDCCglue.c (initialComments): include compiler build date
6273         with compiler version and put the timestamp of the generated
6274         assembly file on a serperate line to be less confusing.
6275         * src/port.h: added genInitStartup hook
6276         * src/avr/main.c,
6277         * src/ds390/main.c,
6278         * src/hc08/main.c,
6279         * src/pic/main.c,
6280         * src/pic16/main.c,
6281         * src/xa51/main.c,
6282         * src/z80/main.c: genInitStartup initialize as NULL (default to
6283         historical behaviour)
6284         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6285         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6286         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6287         library instead of hard coding it into the compiler.
6288         * support/regression/ports/mcs51-stack-auto/spec.mk,
6289         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6290         * device/lib/mcs51/Makefile,
6291         * device/lib/small/Makefile,
6292         * device/lib/large/Makefile,
6293         * device/lib/mcs51/crtpagesfr.asm,
6294         * device/lib/mcs51/crtstart.asm,
6295         * device/lib/mcs51/crtxclear.asm,
6296         * device/lib/mcs51/crtxinit.asm,
6297         * device/lib/mcs51/crtclear.asm,
6298         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6299         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6300         and into user configurable files.
6301         * device/lib/clean.mk: clean mcs51 directory too
6302         * support/regression/tests/longlit.c: added static to T1 declaration
6303         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6304         accesses in the initialization code
6305
6306 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6307
6308         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6309         OSCTRIMVAL as noted in bug #916008
6310
6311 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6312
6313         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6314         in loops with multiple exits (reported as incorrect registers
6315         used by Martin Helmling in Sdcc-user list)
6316
6317 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6318
6319         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6320         made ds390 register extensions look less like error messages
6321
6322 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6323
6324         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6325         reported by Adam Wozniak in Sdcc-user list
6326
6327 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6328
6329         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6330         arithmetic optimizations, added debug output
6331
6332 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6333
6334         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6335         * sdcc.spec: updated and split sdcc into 3 rpms
6336         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6337         needed for literals of LEFT_OP and '+'
6338         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6339         introduced RESULT_TYPE_NOPROM
6340         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6341         left shift
6342         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6343         limited promotion to int only for '*'
6344         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6345
6346 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6347
6348         * src/pic16/gen.c (genSkip),
6349         (genc16bit2lit), (gencjneshort): commented out
6350         (is_LitOp): new helper function, checks operand type
6351         (genCmpEq): rewritten
6352
6353 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6354
6355         * support/regression/tests/bug-908454.c: added
6356
6357 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6358
6359         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6360         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6361         (geniCodeCast): cosmetic, don't preserve bit storage class
6362         (geniCodeLeftShift): added promotion
6363         (geniCodeLogic): fixed regression
6364         * src/SDCCsymt.c (computeTypeOr): accept bits too
6365         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6366
6367 2004-03-07  Borut Razem <borut.razem AT siol.net>
6368
6369         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6370
6371 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6372
6373         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6374         version of pic16_genPackRegisters which does not check if ic is a
6375         CAST operator,
6376         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6377         function cause string1.c regression test fails
6378
6379 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6380
6381         * sim/ucsim/configure.in,
6382         * sim/ucsim/configure,
6383         * sim/ucsim/doc/Makefile.in: use docdir
6384         * src/SDCC.y: fixed sbit atrributes
6385         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6386         * src/SDCCast.c (decorateType): |^& need special promotion handling
6387         * src/SDCCast.h,
6388         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6389         * src/SDCCsymt.h (computeType),
6390         * src/SDCCicode.c: computeType() needs op
6391         * src/SDCCsymt.c (checkTypeSanity),
6392         * doc/sddman.lyx: "plain" bitfields are unsigned
6393         * src/SDCCsymt.c (computeTypeOr): added
6394         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6395         |^& ops
6396         * src/SDCCval.c (val*): computeType() needs op
6397         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6398         * support/regression/tests/onebyte.c: added tests for |^&
6399
6400 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6401
6402         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6403         for writing icode into asm output.
6404
6405 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6406
6407         * src/pic16/device.c: added some debug lines enabled
6408         with macro DEBUG_CHECK,
6409         * src/pic16/genarith.c: more debug in genPlus,
6410         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6411         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6412         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6413         * (aopForSym): onStack symbols are re-placed in data memspace,
6414         and onStack flag is cleared,
6415         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6416         copy temporary pcodeop,
6417         * (genPcall): added warning for not updating PCLATU,
6418         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6419         always true for pic16 port,
6420         * (genMultOneWord): NEW, supports integer multiplication,
6421         * (genMult): modified to call genMultOneWord,
6422         * (ifxForOp): added warning when return NULL,
6423         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6424         flag is set before call to operandFromSymbol for implicit
6425         added structures,
6426         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6427         options.intlong_rent are set by default,
6428         * (_hasNativeMulFor): modified to allow port generation of integer
6429         multiplication,
6430         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6431         set regtype to REG_SFR for all registers, restricting seting the
6432         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6433
6434 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6435
6436         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6437         more than 500 times in the regression tests
6438
6439 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6440
6441         * support/Util/SDCCerr.h,
6442         * support/Util/SDCCerr.c,
6443         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6444         enumerator_list),
6445         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6446         for symbol conflicts.
6447         * support/valdiags/tests/enum.c,
6448         * support/valdiags/tests/tentdecl.c,
6449         * support/valdiags/tests/struct.c: expect possible error messages
6450         referring to original symbol definitions.
6451         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6452         * src/SDCCsymt.h,
6453         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6454
6455 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6456
6457         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6458
6459 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6460
6461         * src/pic16/ralloc.c (newReg): fixed bug #908929
6462
6463 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6464
6465         * src/ds390/gen.c: added missing #include "main.h"
6466
6467 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6468
6469         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6470         checking if symbol is already in set,
6471         * src/pic16/device.h: prototype for checkAddSym,
6472         * src/pic16/gen.c: (_G): added entry interruptvector,
6473         * (assignResultValue): removed some commented out lines,
6474         * (genFunction): check for ISR via sym->type, absolute section for
6475         interrupt code is created via a new pBlock, the goto instruction is
6476         placed now correctly at the interrupt vector position, changed all
6477         references from ivec to _G.interruptvector,
6478         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6479         is the interrupt is a high priority one, same for return from ISR,
6480         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6481         externs to calls of checkAddSym,
6482         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6483         pic16_pcode_verbose flag is set,
6484         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6485         * src/pic16/pcoderegs.c: message about how many registers are saved
6486         will only be emitted if pic16_pcode_verbose flag is set,
6487
6488 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6489
6490         * src/ds390/ralloc.h,
6491         * src/ds390/ralloc.c (ds390_regWithIdx),
6492         * src/ds390/gen.c (emitcode),
6493         * src/ds390/main.h,
6494         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6495         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6496         ds390operandCompare, getRegsRead, getRegsWritten,
6497         initializeAsmLineNode): customized instruction size calculation for
6498         ds390, started basis for some register optimizations
6499         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6500         corresponding assembly output
6501         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6502         missing push/pop of r0/r1. Optimized push/pops
6503
6504 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6505
6506         * src/mcs51/main.c (instructionSize): fixed ACALL size
6507         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6508
6509 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6510
6511         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6512         the sorting of rlist with NULL elements
6513         * (print_idataType, print_idata): NEW to create idata sections
6514         * src/pic16/device.h: idataSymSet new variable
6515         * src/pic16/gen.c (genFunction): fixed some bugs in string
6516         comparing, improved the absolute section creation for ISRs,
6517         added FSR0L/FSR0H in registers that are saved in an ISR,
6518         * (genInline): fixed the processing of inline snippets,
6519         now they undergo no process by the peephole optimizer
6520         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6521         are placed in idataSymSet,
6522         * (pic16emitStaticSeg): extern symbols are added in externs,
6523         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6524         switching when aboslute variables are placed in access bank memory
6525         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6526         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6527         commented out with #if,
6528         * (pic16_packRegisters): reintroduce the check for CAST because some
6529         symbols are not correctly handled,
6530         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6531         pCodeInstruction instead of pCode,
6532         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6533         pCodeAsmDir definition,
6534         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6535         directive, then the argument directive is emitted without the leading
6536         tab, hack for inline labels which must be in the first column,
6537         * (compareLabel,pic16_findNextInstruction),
6538         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6539         * (insertBankSwitch): modified for the new pCodeAsmDir,
6540
6541 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6542         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6543
6544         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6545         instance,
6546         * (pushSide): commented out with #if,
6547         * (assignResultValue): fixed some typos in saving
6548         registers,
6549         * (genPcall): FIXED and sync'ed with genCall,
6550         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6551         * (genNearPointerGet): fixed to handle some more cases,
6552         implementation scheme via table reads,
6553         * (genConstPointerGet): modified to access code memory correct,
6554         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6555         and improved to handle some cases
6556         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6557         instead of "RETLW" for init data
6558         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6559         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6560         variables are placed in access bank memory (<0x80 and >=0xf80),
6561         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6562         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6563         TBLWT_POSTDEC,TBLWT_PREINC
6564         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6565         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6566         directives
6567         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6568         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6569         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6570         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6571
6572 2004-02-29  Borut Razem <borut.razem AT siol.net>
6573
6574         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6575         support/Util/findme.h, support/Util/system.h: enhance binary relative
6576         search for lib and include by using findProgramPath()
6577
6578 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6579
6580         * src/SDCCpeeph.h,
6581         * src/SDCCpeeph.c (pcDistance),
6582         * src/port.h,
6583         * src/mcs51/ralloc.h,
6584         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6585         * src/mcs51/main.h,
6586         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6587         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6588         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6589         size calculation port specific, started basis for some register
6590         optimizations
6591         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6592         missing push/pop of r0/r1. Optimized push/pops
6593         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6594         * device/lib/_modsint.c (_modsint),
6595         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6596         and stack version so regression tests pass
6597
6598 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6599
6600         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6601         * src/SDCCast.c (decorateType): catch another small optimization
6602         with '?' operator
6603         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6604         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6605         modified to finally use computeType() all over SDCC,
6606         see Feature Request #877103
6607         * src/SDCCval.h: cosmetic
6608         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6609         valCompare(); regression tested in muldiv.c
6610         * support/regression/tests/muldiv.c (testMod): mod sign follows
6611         dividend only
6612
6613 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6614
6615         * src/SDCCast.c (decorateType): fixed bug #902362
6616         * doc/INSTALL.txt: fixed install instructions for win32
6617
6618 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6619
6620         * device/include/Makefile.in (install): fixed by replacing spaces
6621         by tabs
6622         * doc/README.txt,
6623         * doc/INSTALL.txt: updated for release
6624         * doc/sdccman.lyx: added warning for --xstack being buggy
6625
6626 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6627
6628         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6629         to eliminate build warnings.
6630         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6631
6632 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6633            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6634
6635         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6636         removed -penable-stack, added comment for stack pragma, added
6637         warning for not initializing the stack/frame registers, removed
6638         comment at interrupts section
6639
6640         Stack is made permanent, there is no ability to disable stack usage.
6641         * src/pic16/device.h,
6642         * src/pic16/device.c: removed all references to USE_STACK macro,
6643         * src/pic16/device.c (pic16_dump_section): when no elements in
6644         rlist, free rlist before return,
6645         * (pic16_dump_int_registers): NEW, internal registers are a new set
6646         of general purpose registers reused by each function,
6647         * (checkAddReg): returns 1 if registers is added to set,
6648         * (pic16_groupRegistersInSection): when a registers is of type
6649         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6650         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6651         SRCASECMP macro is moved here from device.c
6652         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6653         PO_PCLATU, PO_PRODL, PO_PRODH,
6654         * (pic16_pCodeOpType, genMinus,
6655         changed compares to "a" register, with AOP_ACC,
6656         * (pic16_genPlus): fixed some bugs and indented properly,
6657         * (pic16_addSign): changed size to size+offset in the MOVWF
6658         instruction,
6659         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6660         multiply 8-bit operand by literal, result is 8-bit,
6661         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6662         multiply 2 8-bit operand, result is 8-bit,
6663         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6664         genUMult8X*_16,
6665         * src/pic16/gen.c: changed accUse to contain WREG only,
6666         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6667         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6668         true, do not use immediate addressing any more unless sym is a
6669         pointer in codespace,
6670         * (aopForRemat): do not use immediate addressing when symbol not in
6671         codespace and when symbol's address is requested,
6672         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6673         accUse size (= 1),
6674         * (aopGet): added case for AOP_ACC and don't return "accumulator
6675         bug" but WREG instead,
6676         * (popGetTempReg): pushes contents of temporary register in stack,
6677         * (popReleaseTempReg): pops contents of temporary register from
6678         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
6679         * (pic16_popGet): separated case AOP_ACC to return register WREG
6680         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
6681         or PO_IMMEDIATE and initializes their instance/offset appropriately,
6682         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
6683         the use of immediate pointers to certain cases only.
6684
6685         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
6686         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
6687         * (assignResultValue, genCall, genRet): modified to use the new
6688         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
6689         genPcall is still broken,
6690         * (genFunction): added code to create 'A' type pBlocks when
6691         interrupt functions are generated, code not extensively tested yet,
6692         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
6693         * (genEndFunction): modified so ISRs pop stored registers from stack,
6694         * (genMultOneByte): cleanup,
6695         * (AccRsh): added flag andmask, to and result with appropriate mask,
6696         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
6697         * (genDataPointerGet): fixed and reenabled its use,
6698         * (genNearDataPointerGet): bugs fixed,
6699         * (genDataPointerSet): bugs fixed,
6700         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
6701         pic16_DumpSymbol, pic16_DumpOp,
6702         * src/pic16/genutils.h: function prototypes for the above functions,
6703         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
6704         pointers,
6705         * (pic16emitRegularMap): many many many improvements, but needs a
6706         major cleanup,
6707         * src/pic16/main.c: enable_stack in pic16_options is removed,
6708         * (_pic16_parseOptions): removed command line options -penable-stack,
6709         * (_process_pragma): emit stack symbol only when stack pragma is
6710         processed,
6711         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
6712         redirected to FSR0L/FSR0H pair,
6713         * (pic16_get_op, pic16_get_op2): modifications and improvements,
6714         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
6715         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
6716         for immediates,
6717         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
6718         * (dumpPicOptype): NEW,
6719         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
6720         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
6721         with movff instruction,
6722         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
6723         added pic16_int_regs, some packRegsFor* functions are commented out,
6724         because produce errors,
6725         * src/pic16/NOTES: minor modifications
6726
6727 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6728
6729         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
6730         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
6731         --pack-iram.
6732         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
6733         * as/mcs51/lkaomf51.c: fixed bug #895763
6734
6735 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
6736
6737         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
6738
6739 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6740
6741         * doc/sdccman.lyx: added details about the HC08 storage classes and
6742         interrupts, fixed the register usage info for z80 & gbz80
6743
6744 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
6745
6746         * doc/sdccman.lyx: added more pic16 port documentation
6747         * device/include/pic16/: added header pic18fregs.h
6748
6749 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
6750
6751         * doc/sdccman.lyx: added Vangelis' contribution
6752
6753 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6754
6755         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
6756         extend to the next CALL or PCALL, not just to the next CALL.
6757
6758 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
6759
6760         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
6761
6762 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6763
6764         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
6765         bug #895752 and a better fix for bug #716790
6766
6767 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6768
6769         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
6770
6771 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6772
6773         * doc/sdccman.lyx: minor changes, minor changed
6774
6775 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
6776
6777         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
6778         which can't handle SDCC_NEWONEBYTEOPS,
6779         (geniCodeMultiply): removed conversion from mult to shift for pic14
6780         and pic16
6781
6782 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6783
6784         * src/hc08/gen.h,
6785         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
6786         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
6787         thus fixing bug #895406
6788
6789 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
6790
6791         * device/lib/_modsint.c,
6792         * device/lib/_modslong.c: sign follows divisor only
6793         * src/hc08/gen.c (genMultOneByte): if result size is 1,
6794         signs or signedness can be ignored
6795         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
6796         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
6797         added optimization for IFX,
6798         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
6799         arguments;
6800         reenabled optimization for IFX, which was removed on 2004-01-11
6801         * src/SDCCast.h: added return type IFX
6802         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
6803         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
6804         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
6805         SDCC_OLDONEBYTEOPS selects the old behaviour
6806         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
6807         changed again and commented promotion rule
6808         * src/SDCCval.c (valDiv): promotion no longer necessary
6809         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
6810         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
6811         rewritten
6812         * support/regression/tests/onebyte.c: added
6813
6814 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
6815
6816         * gen.c (genInline): reverted to old code for assemnling inline
6817         code because of bug reported James Chadd
6818
6819 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
6820
6821         * ralloc.h: missing declarations from previous patch,
6822         seems that patch for ralloc.h was never applied, fixed
6823
6824 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6825            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
6826
6827         * pcode.c,
6828         * pcode.h,
6829         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
6830         indirect addressing. Marked FSR0 as deprecated
6831         * gen.c (pointerCode): commented out, not needed now
6832         (pic16_popGet2p): new MOVFF helper function
6833         (genGenPointerGet),
6834         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
6835         (shiftRLong): removed duplicate debugging info
6836
6837 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6838
6839         * src/ds390/gen.c (genNearPointerGet),
6840         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
6841         optimization with bits, but not bitfields.
6842         * src/ds390/ralloc.c (packRegisters),
6843         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
6844
6845 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
6846
6847         * src/SDCCcse.c (algebraicOpts): copy operands before modification
6848
6849 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6850
6851         * src/SDCCsymt.h,
6852         * src/SDCCicode.c (operandFromSymbol),
6853         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
6854         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
6855         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
6856         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
6857         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
6858         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
6859         bug #892038
6860         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
6861         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
6862         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
6863         * src/SDCCsymt.c (newSymbol),
6864         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6865         enumerator_list),
6866         * src/SDCCval.h,
6867         * src/SDCCval.c (newiList): fixed bug #885705
6868
6869 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6870
6871         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
6872         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
6873
6874 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6875
6876         * device/include/c8051f120.h,
6877         * device/include/c8051f300.h,
6878         * device/include/c8051f310.h: added/updated header files for Silicon
6879         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
6880         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
6881         in new section Submitting patches
6882
6883 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6884
6885         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
6886         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6887         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6888         genGenPointerSet),
6889         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
6890         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6891         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6892         genGenPointerSet),
6893         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
6894         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6895         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6896         genGenPointerSet),
6897         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
6898         genFarPointerGet, genCodePointerGet, genGenPointerGet,
6899         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
6900         genGenPointerSet): fixed bug #892400
6901         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
6902         to eliminate build warnings.
6903         * src/SDCCast.c (processParms),
6904         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
6905         fixed bug 751859
6906         * support/valdiag/valdiag.py: added GCC to the list of defines active
6907         when compiling with gcc
6908
6909 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6910
6911         * support/Util/SDCCerr.h,
6912         * support/Util/SDCCerr.c,
6913         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
6914         with an incomplete type (fixed bug #883734)
6915         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
6916
6917 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6918
6919         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
6920
6921 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6922
6923         * src/SDCCast.c (decorateType),
6924         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
6925         function pointer implementation
6926         * support/regression/tests/funptrs.c: added tests to verify both forms
6927         of function pointers work correctly. Added tests to verify parameters
6928         are passed in the correct order.
6929
6930 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
6931
6932         * device.c (regCompare): registers are sorted by ascending
6933         address and increasing size,
6934         * main.c (_pic16_finaliseOptions): removed the declaration
6935         of compiler macro MCU. Now a macro of the format pic18fxxxx
6936         will be defined from the command line
6937
6938 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6939             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
6940
6941         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
6942         PCOP_RLCF was overwritten!
6943         * gen.c (genSkip): commented out calls to pic16_emitcode,
6944         * (genCmpEQ): fixed "long" compares, only high word did get compared,
6945         * (genlshTwo),
6946         * (genRRC): added debugging info,
6947         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
6948         overwritten while shifting,
6949         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
6950         overwritten while shifting,
6951         * (AccLsh),
6952         * (AccRsh),
6953         * (shiftLLeftOrResult),
6954         * (shiftRLeftOrResult),
6955         * (shiftRLong),
6956         * (shiftLLong): Implemented with pic16_emitpcode
6957         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
6958         * (genLeftShift): Fixed bug, operand for shift by variable always
6959         was "and"ed with 0x0f,
6960         * (genLeftShiftLiteral),
6961         * (genrshTwo),
6962         * (genRightShiftLiteral): added debugging info,
6963         * (genrshFour): added comment,
6964         * (genRightShift): determined signedness from operand "left"
6965         instead of "result"
6966
6967 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6968
6969         * src/SDCCicode.c (geniCodeParms),
6970         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
6971         function pointers, fixed function pointer bugs #861242 and #861896
6972
6973 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6974
6975         * device/include/c8051f000.h,
6976         * device/include/c8051f120.h,
6977         * device/include/c8051f300.h: added header files for Silicon
6978         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
6979
6980 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
6981
6982         * src/SDCCast.c (processParams): added new type flow and restructured
6983         (gatherAutoInit): added new type flow
6984         (addCast): cosmetic changes
6985         (getLeftResultType): added new type flow for array indices, patch
6986         provided by Stas, see FR #877103
6987         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
6988         array index patch by Stas
6989         * src/SDCCast.h: added prototype getResultTypeFromType()
6990         * src/SDCCval.h,
6991         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
6992         * src/pic/glue.c (pic14emitStaticSeg),
6993         * src/pic16/glue.c (pic16emitStaticSeg),
6994         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
6995         for initialization of symbols
6996         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
6997         * support/Util/SDCCerr.h:
6998         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
6999         * .version: bumped version number to 2.3.8
7000         * device/include/Makefile.in (install),
7001         * doc/Makefile (install): changed to 'rm `find ...`' construct to
7002         avoid warnings
7003
7004 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
7005
7006         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
7007         Slade Rich fixed an optimization bug
7008         * src/pic/pcodepeep.c,
7009         * src/pic/pcoderegs.c
7010         * doc/Makefile (install): added test for directory
7011
7012 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7013
7014         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
7015         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
7016         * src/pic/ralloc.c (getRegPtr, getRegGpr),
7017         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
7018         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
7019         * as/mcs51/asexpr.c (term),
7020         * as/hc08/asexpr.c (term): fixed bug #887146
7021
7022 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7023
7024         * src/z80/gen.c (genMult): handle single byte result product
7025         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
7026         DUMMY_READ_VOLATILE (fixed bug #886367)
7027
7028 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7029
7030         * support/regression/tests/libmullong.c: fixed logic, on little endian
7031         hosts we ended without a mullong_wrapper()
7032
7033 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7034
7035         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
7036         virus/worm forged address usage.
7037
7038 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7039
7040         Fixed promotion, it should be done on AST level:
7041         * src/SDCCast.c (addCast): added promotion to int
7042         (decorateType): updated call to upCast()
7043         * src/SDCCicode.c (geniCodeLeftShift): removed call to
7044         usualUnaryConversions()
7045
7046 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
7047
7048         * support/regression/tests/literalop.c (mulWrapper): Added a
7049         wrapper to remove integer overflow warnings.
7050
7051         * support/regression/tests/float_trans.c: Made work on host.
7052
7053         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
7054         location of sz80.
7055
7056         * support/regression/generate-cases.py (main): Changed from inline
7057         to a main method.
7058
7059         * doc/Makefile (install): Changed to depth first to get rid of
7060         missing directory install warning.
7061
7062         * as/Makefile (install-doc): Made work on Mac.
7063
7064 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
7065
7066         * src/SDCCast.c: added an additional type flow in decorateType() of
7067         opposite direction, see feature request #860006; it's enabled at runtime
7068         by setting the environment variable SDCC_NEWTYPEFLOW
7069         * src/SDCCast.h: changed prototype of decorateType()
7070         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
7071         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
7072         'char' to 'int' can be omitted, if both operands are 'unsigned char';
7073         see feature request #877103
7074         * src/SDCCval.c: updated call of decorateType()
7075         (valBitwise): fixed bug #882876
7076         (valMinus): added promotion
7077         (valLogicAndOr): result is unsigned
7078         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
7079         * src/SDCCsymt.c (computeType),
7080         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
7081         must not cause an unsigned operation
7082         * src/pic/glue (pic14emitRegularMap),
7083         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
7084
7085 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
7086
7087         * src/pic/pcode.c (PCodeID): commented out left over debug code
7088
7089 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
7090
7091         * support/valdiag/tests/overflow.c: added shift tests
7092         * src/pic/device.c,
7093         * src/pic/gen.c,
7094         * src/pic/gen.h,
7095         * src/pic/glue.c,
7096         * src/pic/main.c,
7097         * src/pic/pcode.c,
7098         * src/pic/pcode.h,
7099         * src/pic/pcodepeep.c,
7100         * src/pic/pcoderegs.c,
7101         * src/pic/ralloc.c,
7102         * src/pic/ralloc.h: applied patch from Slade Rich;
7103         added support for multiple code pages and multiple RAM banks on the
7104         PIC 14 port. The ASM files now no longer simply assume all the
7105         code / RAM are in the same page / bank. This means the linker can
7106         safely allocate code/RAM of separate ASM files to different pages/banks.
7107         * doc/sdccman.lyx: added Slade's tips
7108         * src/mcs51/peeph.def: fixed bug #880768
7109
7110 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7111
7112         * src/hc08/ralloc.c (rematStr): fixed bug #879282
7113         * src/SDCCast.c (decorateType): fixed bug #880197
7114
7115 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
7116
7117         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
7118         getopt.h.
7119
7120         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
7121         strtof is not part of C89 and isn't included with Mac OS X.
7122
7123 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7124
7125         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
7126         shiftL2Left2Result): fixed bug #879326
7127         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
7128         (genMultOneByte): fixed bug in signed vs unsigned multiplication
7129         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
7130         address fetch for clr instruction
7131         * device/lib/hc08/_mulint.c: created optimized assembly version
7132         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
7133
7134 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
7135
7136         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
7137         proposed in FR #877103
7138
7139 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
7140
7141         * src/SDCCval.c (cheapestVal): added missing checks
7142         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7143         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7144
7145 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7146
7147         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7148         equal operands
7149
7150 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7151
7152         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7153         loaded with the linker search paths (-L arguments) and the libraries
7154         to be linked with the current source (-l arguments). Changes
7155         currently will affect only the pic16 port.
7156         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7157         include path the port specific paths and port specific libraries,
7158         * gplink command now contains the $3 argument,
7159         * src/pic16/device.h,
7160         * src/pic16/device.c,: structure PIC_device is made public and
7161         renamed to PIC16_device, the same for variable Pics which is renamed
7162         to Pics16. Updated all references to them.
7163         * src/pic16/glue.c (pic16glue): corrected bug with code
7164         initialization which bypassed the variable initializations block.
7165
7166         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7167         COMPILE_FLAGS and added the --nostdinc option
7168
7169 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7170
7171         * device/include/mc68hc908jb8.h: Register defs for another member
7172         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7173
7174 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7175
7176         Documenting changes from previous commits.
7177         * configure.in (version 1.56),
7178         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7179         when generating output files to configure the pic16 library,
7180         but now I've commented it out, since gputils aren't installed in the
7181         SF compile farm, so library won't compile
7182
7183         * device/lib/Makefile.in (version 1.56): initially I've added in
7184         target 'all' the prerequestive 'model-pic16' so it compiled the
7185         pic16 library, but now I've commented it out for the same reasons
7186         above,
7187         * added targets 'model-pic16' and 'objects-pic16' to compile the
7188         library
7189         * added target 'port-specific-objects-pic16' to handle the
7190         generated libraries and copy them into the build/ directory
7191         * added target 'clean-intermediate-pic16' to clean intermediate
7192         files into pic16 directory
7193         * in target 'installdirs' added line to create directory pic16 in
7194         the installation path
7195
7196         * device/include/Makefile.in (version 1.11): in target 'install'
7197         added lines to copy all header files to installation path,
7198         * in target 'installdirs' added line create directory for pic16
7199         headers in the installation path
7200
7201 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7202
7203         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7204          a function call
7205
7206 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7207
7208         * configure,
7209         * device/lib/configure.in,
7210         * device/lib/configure: fixed for autoconf 2.57
7211
7212 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7213
7214         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7215         option so that it actually works. Made it specific to the z80, since
7216         the gbz80 doesn't have these kinds of I/O ports.
7217
7218 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7219
7220         * device/include/z180.h,
7221         * device/lib/_memcpy.c,
7222         * device/lib/_memmove.c,
7223         * device/lib/_mulint.c,
7224         * device/lib/ser_ir.c,
7225         * device/lib/ser_ir_cts_rts.c,
7226         * device/lib/_strcmp.c,
7227         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7228         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7229         portmode; added deprecation warning for bank= and protmode= forms.
7230         Also, guard against buffer overflow.
7231         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7232
7233 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7234
7235         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7236         changed interrupt vector table generation to only emit declared vectors.
7237         * device/include/Makefile.in: added missing backslash
7238         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7239
7240 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7241
7242         Mainly changes to support compilation of the device libraries
7243         * src/pic16/device.c: stack is allocated via symbol and not
7244         via literal number. The symbol is placed in the corresponding
7245         position of the data ram
7246         * (pic16_dump_section): relocatable and absolute uninitialized
7247         data are now emitted in sorted order to reduce section naming,
7248         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7249         weren't marked as being in the access bank,
7250
7251 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7252
7253         Added portion of GNU PIC Library under the directory
7254         device/include/pic16 and device/lib/pic16. These files
7255         contain the declarations of SFRs for the PIC18Fxx2 devices.
7256         The directory is initialized via configure from toplevel.
7257
7258 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7259
7260         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7261         the spilllocations to be compared correctly
7262
7263 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7264
7265         * src/SDCCast.c (decorateType): fixed bug introduced today
7266
7267 2004-01-12  Borut Razem <borut.razem AT siol.net>
7268
7269         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7270         doc/sdccman.lyx: upper case pragmas are deprecated
7271
7272 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7273
7274         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7275         in simpler and even better code
7276
7277 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7278
7279         * src/SDCCicode.c (operandOperation): fixed bug #874819
7280         * src/SDCCast.c (decorateType): fixed
7281         char foo (unsigned long ul) { return ul > 0; }
7282
7283 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7284
7285         * doc/sdccman.lyx: Moved and added some sections, small changes
7286         all over. Telling LaTeX to be less strict with word spacing
7287         to better keep the right margin. Changed some notes about
7288         maintainance of the ports in section 3.2.1 - is it OK like this?
7289
7290 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7291
7292         SDCC source changes:
7293         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7294         convilong): modified to inform the pic16 port that builtin functions
7295         are external
7296
7297         PIC16 PORT specific changes:
7298         * src/pic16/device.c pic16_dump_equates() added,
7299         processor registers declared internally by the port are emitted in
7300         the translation as equates,
7301         * src/pic16/gen.c: inline code is passed unprocessed to the
7302         translation,
7303         * (pic16_popGetLit2): fnuction modified to take second operand as
7304         pCodeOp pointer and not as literal,
7305         * (popRegFromIdx): prefixed with pic16_,
7306         * (pic16_popCombine2): modified to receive already allocated pCode
7307         operands,
7308         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7309         * (genFunction): initializes local stack frame and pushes on stack
7310         all the registers used by this function,
7311         * (genEndFunction): restores all registers from stack and restores
7312         stack frame,
7313         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7314         improvements,
7315         * (pic16glue): changed the program startup sequence,
7316         * added new dbName code 'A' for functions placed in absolute section
7317         * src/pic16/main.c: added function attribute _naked,
7318         * added pragma 'code' to place a fnuction at an absolute address,
7319         * added command line arguments --debug-ralloc and --pcode-verbose,
7320         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7321         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7322         * (pic16_newpCodeOpLit2): modified to take the second operand as
7323         pCodeOp pointer,
7324         * (pic16_printpBlock): modified to emit each function in a separate
7325         section,
7326         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7327         UPPER for immediate operands,
7328         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7329         instruction,
7330         * src/pic16/peeph.def: all peepholes with movff are commented out,
7331         because there is a problem in the pcode peep optimizer,
7332         * src/pic16/ralloc.c: the register allocator can now reuse local
7333         function symbols for another function. This saves register usage.
7334         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7335
7336         Added file src/pic16/NOTES with information about program writing on
7337         the current port version.
7338
7339 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7340
7341         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7342         and peephole 252 (array access)
7343
7344 2004-01-09  Borut Razem <borut.razem AT siol.net>
7345
7346         * src/SDCCmain.c : fixed #872250: -l command line defined library
7347           files are scanned before standard library files
7348
7349 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7350
7351         * src/SDCCast.c (decorateType): fixed bug #874046
7352
7353 2004-01-09  Borut Razem <borut.razem AT siol.net>
7354
7355         * support/scripts/sdcc.nsi: remove previous installation
7356
7357 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7358
7359         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7360         bytes for last interrupt vector (mcs51)
7361         * sdcc.spec: fixed typo
7362
7363 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7364
7365         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7366         gen51Code): more efficient parameter receive for --model-large
7367         ("bug" #845294)
7368
7369 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7370
7371         * src/ds390/main.c,
7372         * src/z80/main.c: added missed needLinkerScript flags (more than
7373         one port structure defined in these file)
7374         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7375         bug #795325
7376
7377 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7378
7379         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7380         * src/port.h: added flag needLinkerScript in port->linker
7381         structure to inform whether to create a .lnk file or not,
7382         * src/avr/main.c,
7383         * src/ds390/main.c,
7384         * src/hc08/main.c,
7385         * src/mcs51/main.c,
7386         * src/pic/main.c,
7387         * src/pic16/main.c,
7388         * src/xa51/main.c,
7389         * src/z80/main.c: changed appropriately to configure
7390         needLinkerScript flag
7391         * src/pic/gen.c,
7392         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7393         * src/pic/glue.c: added variable udata_section_name to
7394         override default uninitialized data segment definition for
7395         devices only with SHAREBANK memory (reported from Erik Epetrich)
7396         * (pic14emitOverlay): modified to emit a commented overlay segment
7397         directive when no overlay data exist
7398         * (picglue): modified to emit uninitialized data segment
7399         according to udata_section_name
7400         * src/pic/main.c (_pic14_parseOptions): added command line
7401         options --udata-section-name=[name] to override default
7402         udata definition name
7403         * modified _linkCmd and _asmCmd to include compiler passed
7404         arguments via -W option
7405         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7406         object file from '.rel' to '.o' in port->linker structure,
7407         changed size of fptr from 2 to 3 in port structure
7408
7409 2004-01-07  Borut Razem <borut.razem AT siol.net>
7410
7411         * support/scripts/sdcc.nsi: update PATH
7412         * support/scripts/sdcc.ico: craeted
7413
7414 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7415
7416         * device/include/Makefile.in: fix install
7417         * doc/Makefile: fix install
7418
7419 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7420
7421         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7422         in bug #860505
7423         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7424         how the function variable allocation summary is displayed; also
7425         include information about variables allocated to the overlay
7426         segment
7427
7428 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7429
7430         * as/mcs51/lkmain.c: Help about -Y option
7431         * as/mcs51/lkarea.c: Fixed gcc warnings
7432
7433 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7434
7435         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7436         fixed warning
7437         * support/valdiag/tests/overflow.c: added
7438         * src/SDCCast.c (decorateType),
7439         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7440         LEFT_OP (left shift)
7441
7442 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7443
7444         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7445         (default behaviour).
7446
7447 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7448
7449         A python script to validate compiler diagnostic messages. It can be
7450         used to verify that sdcc complains about bad c source code and
7451         gives a good location of the error.
7452         * support/valdiag/Makefile,
7453         * support/valdiag/valdiag.py,
7454         * support/valdiag/tests/*
7455
7456 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7457
7458         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7459         * src/SDCCsymt.c (newEnumType),
7460         * src/SDCCsymt.h
7461         * support/Util/SDCCerr.c,
7462         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7463         enum related bugs.
7464         * support/regression/tests/enum.c: added test for enum values that
7465         require at least 2 bytes of storage.
7466
7467 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7468
7469         * src/common.h: added ifndef/define/endif macros
7470         around the header file.
7471         Bug reported from Jesus Calvino-Fraga
7472
7473 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7474
7475         * sdcc.spec: updated
7476         * device/include/Makefile.in: don't install CVS directories
7477         * device/lib/Makefile.in: added removal of CVS directories after install
7478         * doc/Makefile: fixed install, added local_icons
7479         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7480         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7481         * src/ds390/gen.c (genRightShift): fixed bug #870788
7482         * src/SDCCast.c (decorateType): fixed bug #870781
7483
7484 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7485
7486         PIC16 port related changes:
7487         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7488         added variable stackPos,
7489
7490         * gen.c: genCall, assignResultValue: added support for
7491         pushing/retrieving function parameters to/from stack,
7492         genFunction,genEndFunction: setup stack frame for the
7493         generated function,
7494         genAddrOf: will be changed according to bug 863624
7495
7496         * added files genutils.c and genutils.h which contain gen*
7497         debugged and optimised functions extracted from gen.c
7498
7499         * glue.c: added variable 'externs' which holds extern symbols,
7500         pic16emitRegularMap: is modified to properly handle relocatable
7501          symbols under the new scheme,
7502         pic16createInterruptVect: is modified
7503         pic16printPublics: is modified to emit 'global' assembler directives,
7504         added pic16_printExterns to print extern symbols,
7505         pic16glue: initializes stack/frame pointer in the beginning of
7506         the assembly output. Temporary hack, will be corrected later,
7507         because gplink yet does not support stack and SDCC does not
7508         yet support a type of crt0.o object to create the final binary.
7509
7510         * Removed many lines that contain 8051 legacy code.
7511         * The code is finally placed under a 'code' directive.
7512         * Added port specific options.
7513
7514         * _process_pragma: simplified since now we do not need *special*
7515         include file to define SFR registers. But a separate header
7516         will be needed. This will be developed later.
7517         * _pic16_parseOptions: added, parses port specific options:
7518         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7519         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7520         --preplace-udata-with=
7521
7522         * _pic16_setDefaultOptions: modified to initialize section names,
7523         but hack is temporarly out of order since it needs improvement.
7524         * _pic16_genAssemblerPreamble: configuration words are emitted by
7525         their address instead of their name. This part is incomplete and
7526         supports only the 18Fxx2 devices. Other devices will emit an error
7527         during assembly since they do not contain the same set of config
7528         registers
7529         * _pic16_genIVT: is modified,
7530
7531         * pcode.c: added definitions for some hardware registers that are needed
7532         for stack support
7533         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7534         All PCI entries are updated. Now LFSR is supported.
7535         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7536         * added pic16_newpCodeOpLit2 to support instructions with
7537         two literal arguments
7538         * pic16_pCode2str: corrected code that emits assembler instructions
7539         with two literal operands and those that have an access bit modifier
7540         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7541         this fixes a bug which caused some labels to be lost, when an
7542         assembler directive was added, i.e. banksel,
7543         * pic16_FixRegisterBanking: improved logic that causes the insertion
7544         of bank switching,
7545         * InlineFunction: functions that are called once, are not any more
7546         inlined. This can be a port option in the future,
7547
7548         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7549
7550         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7551         hold the corresponding uninitialized symbols,
7552         * pic16_allocProcessorRegister: registers have explicit marked the
7553         accessBank field,
7554         * pic16_allocInternalRegister: registers are explicit marked as
7555         not used,
7556         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7557         processing list, so bit registers were lost,
7558         *
7559
7560         * ralloc.h: added field 'accessBank' and original symbol operand
7561         in register definition,
7562         * removed the field isMapped from register definition,
7563
7564         ** Several functions have been removed from various sources:
7565         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7566         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7567         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7568         pic16_assignRelocatableRegisters
7569
7570         ** others have been introduced:
7571         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7572         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7573
7574 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7575
7576         * support/scripts/inc2h.pl: changed definition of BIT_AT
7577         to emit 'sbit at' instead of 'bit at'. This was a request.
7578
7579         PIC16 port related preliminary changes:
7580         * gen.c: prefixed function popRegFromString with
7581         pic16_ and all references to it corrected
7582         * pcode.c: all pic16_pc_* hardware registers prefixed
7583         with underscore (_),
7584         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7585         * ralloc.c: newReg(): when register is REG_SFR then
7586         set address to rIdx,
7587         pic16_allocProcessorRegister(): marks register wasUsed=0
7588         pic16_writeUsedRegs(): added a call to assign processor
7589         registers via pic16_assignFixedRegisters
7590
7591 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7592
7593         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7594         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7595         variables in unused register banks.  Also the SSEG is placed
7596         wherever there is enough space for it, and IDATA can be anywhere
7597         in internal RAM.  For now compile using -Wl-Y[stack_size].
7598         The mem file is different for this option as well, since it
7599         makes no sense of talking about DSEG lenght.
7600
7601 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7602
7603         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7604         in certain cases, e.g. when ROM assignment, patch provided
7605         from Albert den Haan.
7606
7607 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7608
7609         Many signedness and type propagation fixes:
7610         * src/SDCCicode.c: made geniCodeCast() static
7611         replaced SPEC_ by IS_ (cosmetic)
7612         (operandOperation): fixed div and mod operation
7613         (usualBinaryConversions): added support for promotion of char
7614         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7615         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7616         (geniCodeAdd): an array index will stay unsigned, even if promoted
7617         from char to int
7618         (geniCodeArray): ditto
7619         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7620         * src/SDCCsymt.c (computeType): added more support for char;
7621         promotion of char is selectable by promoteCharToInt, fixed signedness
7622         for all cases
7623         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7624         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7625         * src/SDCCval (val*): replaced signedness calculation by
7626         computeType()
7627         rearranged if-branches (cosmetic)
7628         (valShift): added warning W_SHIFT_CHANGED
7629         (valCompare): fixed problem with different types
7630         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7631         * support/regression/tests/literalop.c: added many cases
7632         * support/regression/tests/ast_constant_folding.c: changed finally to
7633         'unsigned int'
7634         * .version: new year, new version: 2.3.7
7635         * src/SDCCmain.c (main): applied patch #866468
7636         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7637         provided by Scott Bronson
7638         * doc/sdccman.lyx: updated documentation for sdcdb
7639         updated and added chapter tips
7640
7641 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7642
7643         * src/SDCCsymt.h: missing from yesterday's commits
7644
7645 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7646
7647         * src/SDCC.y (struct_or_union_specifier),
7648         * support/Util/SDCCerr.c,
7649         * support/Util/SDCCerr.h: verify that struct & union tags are used
7650         as declared.
7651
7652 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7653
7654         * src/SDCCglobl.h: missing from yesterday's commits
7655
7656 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7657
7658         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7659         sft_attributes, struct_declaration, parameter_declaration,
7660         type_name, start_block, declaration_list),
7661         * src/SDCC.lex (check_type): support redefinition of typedef names
7662
7663 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7664
7665         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7666         aligned xdata arrays. Erik helped me with the if clause.
7667
7668 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7669
7670         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7671         warning
7672
7673 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7674
7675         * src/SDCCast.h,
7676         * src/SDCCast.c (newAst_),
7677         * src/SDCCicode.h,
7678         * src/SDCCicode.c (ast2iCode, newiCode),
7679         * src/SDCCglobl.h,
7680         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
7681         expr, statement, expression_statement, selection_statement,
7682         iteration_statement, expr_opt, jump_statement): foundation for tracking
7683         sequence points
7684         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
7685         point code too)
7686
7687 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7688
7689         * support/Util/SDCCerr.c,
7690         * src/SDCCast.h,
7691         * src/SDCCast.c (createCase, createDefault, decorateType),
7692         * src/SDCClabel.c (labelUnreach),
7693         * src/SDCC.y (labeled_statement, jump_statement): More improvements
7694         to error messages.
7695         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
7696         (with thanks to Stas Sergeev)
7697         * device/include/time.h,
7698         * device/lib/time.c (CheckTime): suppress unreachable code warning
7699
7700 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7701
7702         * src/SDCCast.c (createIvalCharPtr),
7703         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
7704         bug #753752)
7705         * support/regression/tests/nullstring.c: tests for these two bugs
7706
7707 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7708
7709         * support/Util/SDCCerr.h,
7710         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
7711         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
7712         about storage class and 'at' used inside struct or union
7713         * src/SDCCBBlock.c (iCodeFromeBBlock),
7714         * src/SDCCcse.c (ifxOptimize),
7715         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
7716         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
7717         printIval, emitStaticSeg, emitOverlay),
7718         * src/SDCClabel.c (deleteIfx),
7719         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
7720         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
7721         gatherAutoInit, processParms),
7722         * support/Util/SDCCerr.h,
7723         * support/Util/SDCCerr.c (werrorfl): Support for better error location
7724         reporting for post-parse errors.
7725
7726 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7727
7728         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
7729         implicit casts via union; they don't work on big endian systems
7730         (possible fix for bug #861138)
7731
7732 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7733
7734         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
7735         * src/mcs51/main.c: fixed the fix for bug #737001
7736
7737 2003-12-15  Borut Razem <borut.razem AT siol.net>
7738
7739         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
7740
7741 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7742
7743         * support/makebin/makebin.c: put output in binary mode
7744
7745 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7746
7747         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
7748         xdata and data memory on startup. Set the environment variable
7749         SDCC_NOGENRAMCLEAR to disable this.
7750         * src/mcs51/peephole.def,
7751         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
7752         (allows non-interrupt and interrupt code to safely compete for a resource
7753         without the non-interrupt code having to disable interrupts)
7754
7755 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7756
7757         * src/SDCCicode.c (geniCodeAdd),
7758         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
7759         with valFromType if type might be a pointer and host is big endian).
7760         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
7761         types, not just integer types.
7762         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
7763         multiply defined with mismatching "at" address.
7764
7765 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7766
7767         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
7768         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
7769         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
7770         with embedded nulls (fixed bug #753752)
7771
7772 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7773
7774         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
7775         Apparently this did not see much testing (endless loop)
7776
7777 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7778
7779         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
7780
7781 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7782
7783         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
7784         gracefully handle NULL memmap pointers
7785
7786 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7787
7788         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
7789         instead of deleting the iCode when an operand is volatile
7790         * src/z80/gen.c (genDummyRead),
7791         * src/mcs51/gen.c (genDummyRead),
7792         * src/ds390/gen.c (genDummyRead),
7793         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
7794         not just IC_RIGHT
7795         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
7796         * src/SDCC.y: fixed bug #850420
7797
7798 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7799
7800         Applied z80 i/o port patch from Peter Townson and fixed some operators
7801         to better handle operands in A register.
7802         * device/include/z180.h
7803         * src/SDCC.y
7804         * src/SDCCglue.c
7805         * src/z80/gen.c
7806         * src/z80/gen.h
7807         * src/z80/main.c
7808         * src/z80/peeph-z80.def
7809         * src/z80/peeph.def
7810         * src/z80/z80.h
7811
7812 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7813
7814         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
7815
7816 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7817
7818         * device/lib/hc08/_mullong.c: Removed extra #endif
7819
7820 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7821
7822         * sim/ucsim/hc08.src/inst.cc,
7823         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
7824         carries from x to h
7825         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
7826         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
7827         * device/include/stdarg.h: fixed varargs for hc08
7828         * device/lib/Makefile.in,
7829         * device/lib/hc08/Makefile,
7830         * device/lib/hc08/_mulint.c,
7831         * device/lib/hc08/_mullong.c: fixed some endian problems
7832
7833 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7834
7835         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
7836         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
7837         * device/lib/_gptrget.c,
7838         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
7839
7840 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7841
7842         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
7843         * src/SDCCast.c (astErrors): fixed bug #846007
7844         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
7845
7846 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7847
7848         * src/SDCCast.c (decorateType): disabled a transformation I added in
7849         revision 1.188 (access to fields of a structure at an absolute address);
7850         it breaks with bitfields, extern declarations, and gcse analysis.
7851         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
7852         could be assigned through a pointer, so don't complain.
7853         * src/SDCCast.c (astErrors),
7854         * src/SDCCast.h,
7855         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
7856
7857 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
7858
7859         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
7860         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
7861         output of __config directives, since gpasm now supports them
7862         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
7863         pre-processor macro, i.e. -DMCU=p18f452
7864         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
7865         and modified to handle 'cast' icode similarly to '=' icode
7866         * src/pic16/device.h (typedef struct PIC_device): added field
7867         'extMIface' to indicate that chip has external memory interface
7868         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
7869         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
7870         18F8720
7871
7872 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7873
7874         * src/SDCC.y (pointer): fixed bug #846006
7875         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
7876         * src/SDCCast.c (decorateType): fixed bug #846009
7877         * src/ds390/peeph.def,
7878         * src/ds390/gen.c (genAnd, genOr),
7879         * src/mcs51/peeph.def,
7880         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
7881
7882 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7883
7884         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
7885         * src/SDCCdflow.c
7886         * src/SDCCcse.c
7887         * src/SDCCcse.h
7888         * src/SDCCBBlock.h
7889         * src/SDCCBBlock.c
7890
7891 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
7892
7893         fixed bug #845089
7894         * src/SDCCbitv.h,
7895         * src/SDCCbitv.c: added function to free a bitvector
7896         * src/SDCClrange.h,
7897         * src/SDCClrange.c: added function to recompute the liveranges
7898         * src/avr/ralloc.c,
7899         * src/ds390/ralloc.c,
7900         * src/hc08/ralloc.c,
7901         * src/mcs51/ralloc.c,
7902         * src/pic/ralloc.c,
7903         * src/pic16/ralloc.c,
7904         * src/xa51/ralloc.c,
7905         * src/z80/ralloc.c: recompute the liveranges after register packing
7906
7907 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
7908
7909         * src/SDCCloop.c (newInduction): fixed bug #845630
7910
7911 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7912
7913         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
7914         inadvertantly left behind from my 2003-11-12 change
7915
7916 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7917
7918         Updated headers I neglected to commit yesterday.
7919         * src/SDCClrange.h,
7920         * src/SDCCicode.h
7921
7922 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7923
7924         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
7925         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
7926         * src/SDCCopt.c (eBBlockFromiCode),
7927         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
7928         the creation of the key hash table from the sequencing so it can be used
7929         earlier (for some GCSE bug fixes still pending)
7930
7931 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7932
7933         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
7934         * support/regression/tests/addsub.c: testing genPlus shortcut
7935
7936 2003-11-15  Borut Razem <borut.razem AT siol.net>
7937
7938         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
7939
7940 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7941
7942         * src/SDCCcse.c (cseBBlock): fixed bug #527779
7943         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
7944         ordering is immaterial.
7945         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
7946
7947 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7948
7949         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
7950         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
7951         (SIGSEV) of bug #840381
7952         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
7953         unlink new file before rename if new and old filenames are the same)
7954
7955 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7956
7957         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
7958         uninitialized variables) for the mcs51. Set environment variable
7959         SDCC_GENRAMCLEAR to test.
7960         xdata initialization slightly shorter
7961
7962 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7963
7964         * src/SDCCsymt.h,
7965         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
7966         #838241 & 780691 (basicly the same bug)
7967         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
7968         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
7969
7970 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
7971
7972         * src/SDCCmain.c (linkEdit): "fix" #834252
7973
7974 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7975
7976         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
7977         * src/SDCCast.h,
7978         * src/SDCC.y: fixed bug #819403
7979
7980 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7981
7982         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
7983         the reentrant attribute.
7984         * src/hc08/gen.c (genPackBits): added missing stack readjustment
7985         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
7986         simulation
7987         * src/SDCCast.c (decorateType): fixed bug with storage class not being
7988         updated during pointer dereference; f.e. ~(((char *)1)*) was being
7989         erroneously reduced to a literal.
7990         * src/hc08/ralloc.c (packRegisters, rematStr),
7991         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
7992         some cases
7993
7994 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7995
7996         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
7997         * doc/sdccman.lyx: changed from 'article' to 'book'
7998         * doc/Makefile: readded test_suite_spec and cdbfileformat
7999
8000 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
8001
8002         * device/include/stdlib.h: include malloc.h to comply with ANSI
8003         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
8004
8005 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8006
8007         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
8008         * doc/clean.mk: also remove *.out files
8009         * doc/sdccman.lyx: some additions, larger top/bottom margins
8010
8011 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8012
8013         * src/SDCC.y: fixed bug #837365
8014         * support/regression/tests/bitopcse.c
8015         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
8016         a symbol (might be valop instead)
8017         * device/lib/Makefile.in: added errno.c to HC08SOURCES
8018         * device/lib/clean.mk: added hc08 to the cleaning list
8019
8020 2003-11-04  Borut Razem <borut.razem AT siol.net>
8021
8022         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
8023           made 2003-11-04
8024         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8025           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
8026           malloc is declared in standard stdlib.h
8027
8028 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8029
8030         * device/lib/hc08/Makefile: need to clean .rel not .o files
8031         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
8032
8033 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8034
8035         * src/port.h,
8036         * src/hc08/main.c,
8037         * src/mcs51/main.c,
8038         * src/ds390/main.c,
8039         * src/z80/main.c,
8040         * src/avr/main.c,
8041         * src/pic/main.c,
8042         * src/pic16/main.c,
8043         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
8044         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
8045         tests (which uses the port's oclsExpense function)
8046         * src/SDCC.y,
8047         * src/SDCCast.c,
8048         * src/SDCCicode.c,
8049         * src/hc08/gen.c,
8050         * src/ds390/gen.c,
8051         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
8052
8053 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8054
8055         * src/SDCCcse.c (ifxOptimize),
8056         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
8057         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
8058         deleting the IFX iCode.
8059         * src/hc08/ralloc.c: reduced unneeded slocs
8060         * src/hc08/gen.c: fixed bug in asmopToBoolean
8061
8062 2003-11-04  Borut Razem <borut.razem AT siol.net>
8063
8064         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
8065           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8066           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
8067           transferred to configure
8068
8069 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
8070
8071         Use headers defined in the C[++] standards:
8072         * sim/ucsim/gui.src/serio.src/fileio.cc
8073         * sim/ucsim/gui.src/serio.src/frontend.cc
8074         * sim/ucsim/gui.src/serio.src/main.cc
8075         * sim/ucsim/gui.src/serio.src/posix_signal.cc
8076         * support/Util/NewAlloc.c
8077         * as/hc08/lklibr.c
8078         * as/mcs51/lklibr.c
8079         * as/z80/aslist.c
8080         * as/z80/assym.c
8081
8082 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8083
8084         * Added MSVC projects for hc08 assembler and linker:
8085         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
8086         /as/hc08/link_hc08.dsp
8087
8088 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
8089
8090         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
8091
8092 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
8093
8094         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
8095
8096 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8097
8098         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
8099
8100 2003-10-31  Borut Razem <borut.razem AT siol.net>
8101
8102         * support/cpp2/cpplib.h,
8103           support/cpp2/cpplib.c,
8104           support/cpp2/cpplex.c,
8105           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
8106           to switch _asm block preprocessing on / off. Default is
8107           #pragma preproc_asm +
8108
8109 2003-10-31  Borut Razem <borut.razem AT siol.net>
8110
8111         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
8112           when outputting comment blocks (when executed with -C option) and
8113           _asm (SDCPP specific) blocks
8114
8115 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8116
8117         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
8118
8119 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
8120
8121         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
8122
8123 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
8124
8125         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
8126         * src/SDCCast.c (decorateType): fixed bug #832664
8127
8128 2003-10-31  Borut Razem <borut.razem AT siol.net>
8129
8130         * support\cpp2\cpplex.c: fixed for SDCPP:
8131           comments(when executed with -C option) and _asm blocks
8132           were included even if they where in skipped #if block.
8133           Applied solution from GCC cpp 3.3.2
8134
8135 2003-10-31  Borut Razem <borut.razem AT siol.net>
8136
8137         * src/SDCC.lex: sdcc now understands both formats:
8138           '# <line_number> <file_name>' and
8139           '#line <line_number> <file_name>'
8140         * support/cpp2/cppmain.c: sdcpp now generates the standard
8141           '# <line_number> <file_name>' instead of former
8142           '#line <line_number> <file_name>'
8143
8144 2003-10-30  Borut Razem <borut.razem AT siol.net>
8145
8146         * support/cpp2/cpphash.h,
8147         * support/cpp2/cpplib.h
8148         * support/cpp2/cpplex.c,
8149         * support/cpp2/cppmain.c,
8150         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8151
8152 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8153
8154         Fixed a number of problems revealed by bug #827883.
8155         * src/SDCCloop.c (loopInvariants): Spill location of the
8156         result operand should be recomputed if extracted from
8157         a loop. Also, don't extract assignments of an iTemp
8158         from a literal.
8159         * src/SDCCast.c (isConformingBody): loop reversal should
8160         not occur if the control variable is involved with a
8161         relational operator.
8162
8163 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8164
8165         * .version: bumped to 2.3.6 to reflect the big improvements
8166         made by Erik and Klaus. Thanks!
8167
8168 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8169
8170         Replaced the livrange code.
8171         * src/SDCClrange.c: added new LR code
8172         * src/SDCCloop.c,
8173         * src/SDCCBBlock.h: removed remainig parts from old LR code
8174         * src/ds390/ralloc.c,
8175         * src/ds390/gen.c: minor fixes to make it work with new code
8176
8177 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8178
8179         * as/hc08/asm.h,
8180         * as/hc08/lkrloc.c,
8181         * src/hc08/gen.c,
8182         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8183         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8184         (tweaked fix for bug #818696)
8185
8186 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8187
8188         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8189
8190 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8191
8192         * src/SDCCmain.c,
8193         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8194         * src/mcs51/gen.c (gencjneshort),
8195         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8196         more efficient (per Scott Bronson's suggestion)
8197
8198 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8199
8200         Extended the semantics of the critical keyword to include
8201         individual statements. See RFE #827755 and #799831
8202         * src/SDCC.y
8203         * src/SDCCicode.c
8204         * src/SDCCopt.c
8205         * src/SDCCast.c
8206         * support/Util/SDCCerr.c
8207         * support/Util/SDCCerr.h
8208         * src/mcs51/gen.c
8209         * src/ds390/gen.c
8210         * src/hc08/gen.c
8211
8212 2003-10-19  Borut Razem <borut.razem AT siol.net>
8213
8214         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8215
8216 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8217
8218         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8219         Fixed bug #818696
8220         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8221         and predecrement operand is displayed
8222
8223 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8224
8225         * src/SDCCval.c (valMinus): fixed bug #826041
8226
8227 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8228
8229         Some hc08 related updates that I missed earlier
8230         * sim/ucsim/stypes.h
8231         * support/regression/ports/hc08/spec.mk
8232
8233 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8234
8235         New target "hc08" for the Motorola 68hc08 family of micros
8236
8237         * configure
8238         * configure.in
8239         * Makefile
8240         * src/hc08/*
8241         * src/SDCCmain.c
8242         * src/port.h
8243         * sim/ucsim/hc08.src/*
8244         * sim/ucsim/configure.in
8245         * src/ucsim/configure
8246         * sim/ucsim/packages_in.mk
8247         * as/hc08/*
8248         * as/Makefile
8249         * device/include/mc68hc908qy.h
8250         * device/lib/hc08/*
8251         * device/lib/Makefile.in
8252         * support/regression/ports/hc08/*
8253         * support/regression/Makefile
8254
8255 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8256
8257         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8258         regression test
8259         * src/ds390/gen.c (genCast): fixed bug #821957
8260
8261 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8262
8263         * device/lib/logf.c: "fixed" overlay bug
8264         * support/regression/ports/host/spec.mk: added m library
8265         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8266         * support/regression/tests/float_trans: added (for Eric)
8267
8268 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8269
8270         * src/mcs51/gen.c (genCpl): fixed bug
8271         http://sf.net/mailarchive/message.php?msg_id=6263915
8272
8273 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8274
8275         * src/SDCCast.c (decorateType): added extended constant folding
8276         * src/SDCCsymt.c (computeType): cleanup
8277         * src/SDCCval.c (valShift): minor optimization
8278         * support/regression/tests/ast_constant_folding.c: added
8279
8280 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8281
8282         * src/SDCCmain.c: removed some unintended changes
8283
8284 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8285
8286         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8287         * src/z80/gen.c: fixed part of bug #817589
8288         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8289
8290 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8291
8292         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8293         * src/SDCCcflow.c
8294         * src/SDCCcse.c
8295         * src/SDCCdflow.c
8296         * src/SDCClabel.c
8297         * src/SDCClrange.c
8298         * src/SDCCmem.c
8299         * src/SDCCopt.c
8300         * src/SDCCpeeph.c
8301         * src/SDCCset.c
8302         * src/avr/ralloc.c
8303         * src/ds390/ralloc.c
8304         * src/izt/ralloc.c
8305         * src/mcs51/ralloc.c
8306         * src/pic/ralloc.c
8307         * src/pic16/ralloc.c
8308         * src/xa51/ralloc.c
8309         * src/z80/ralloc.c
8310         * src/z80/gen.c: removed unused label "release:"
8311
8312 2003-10-06  Borut Razem <borut.razem AT siol.net>
8313
8314         * src/SDCC.lex: removed definition of unused variables
8315           save_optimize and save_options
8316
8317 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8318
8319         * clean.mk: removed '=' in "-maxdepth=1"
8320         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8321         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8322
8323 2003-10-06  Borut Razem <borut.razem AT siol.net>
8324
8325         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8326           my_unput() replaced by unput()
8327
8328 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8329
8330         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8331         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8332         type-punned pointer will break strict-aliasing rules"
8333         Old LR behaviour is again default; Klaus' LR can be choosen by
8334         defining the environment variable LRKLAUS
8335         * src/SDCCBBlock.h
8336         * src/SDCCloop.c
8337         * src/SDCClrange.c
8338         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8339         * clean.mk: fixed removal of files in bin/CVS/
8340         * device/lib/clean.mk: fixed removal of directories small and large
8341         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8342         * src/SDCCicode.c,
8343         * src/SDCCval.c: removed superflous test for pedantic
8344
8345 2003-10-05  Borut Razem <borut.razem AT siol.net>
8346
8347         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8348           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8349           message "unmatched #pragma SAVE and #pragma RESTORE"
8350
8351 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8352
8353         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8354           assembly, critical functions, atomic, nojtbound)
8355
8356 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8357
8358         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8359         * src/SDCCBBlock.h
8360         * src/SDCCloop.c
8361         * src/SDCCloop.h
8362         * src/SDCClrange.c
8363
8364 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8365
8366         * src/z80/gen.h,
8367         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8368         * src/mcs51/gen.h
8369         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8370         * src/ds390/gen.h
8371         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8372         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8373         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8374
8375 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8376
8377         * src/z80/gen.c (genRet): fixed bug #524753
8378         * src/z80/gen.c (genCast): fixed internal error on cast from
8379         pointer to long
8380         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8381         fix for bug #477835 to the z80
8382         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8383         for tracking iCodes in the peephole optimizer for z80
8384
8385 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8386
8387         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8388         the other part of bug #814548
8389         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8390
8391 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8392
8393         * src/SDCCcse.c: fixed part of bug #814548
8394
8395 2003-09-28  Borut Razem <borut.razem AT siol.net>
8396
8397         * src/asm.c: rewrite of printILine() to use temporary file instead
8398           a pipe
8399         * src/xa51/main.c: commented out declaration of int rewinds
8400
8401 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8402
8403         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8404
8405 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8406
8407         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8408         * src/asm.c (printILine): Fixed bug #811015
8409
8410 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8411
8412         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8413         freeing.
8414
8415 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8416
8417         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8418         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8419         to correctly handle general case of AOP_PAIRPTR
8420         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8421
8422 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8423
8424         * src/mcs51/ralloc.c (fillGaps),
8425         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8426         register positioning bug)
8427
8428 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8429
8430         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8431
8432 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8433
8434         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8435         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8436         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8437         (ralloc doesn't intentionally do this now, but perhaps later)
8438         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8439         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8440         register positioning bugs (Fixed bug #762602 and #795325)
8441         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8442         (Fixed bug #808779)
8443         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8444         lines that --i-code-in-asm generates
8445
8446 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8447
8448         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8449         trying to fclose a FILE* that was already closed.
8450
8451 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8452
8453         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8454         of const struct should be treated as if const themselves)
8455
8456 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8457
8458         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8459
8460 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8461
8462         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8463         Unix (/n) and DOS (/r/n) line terminations.
8464
8465 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8466
8467         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8468         bug #613775
8469
8470 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8471
8472         * src/mcs51/gen.c (genFunction, genEndFunction),
8473         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8474         and restore of EA so that stack offsets to parameters are
8475         correct when using both critical and reentrant/stack-auto.
8476         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8477         size (can be triggered in error if sloc is shared between
8478         different sized objects)
8479         * device/include/float.h: fixed macros to explicitly use
8480         unsigned long where needed
8481
8482 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8483
8484         Feature req. 799831: added code to allow nesting of critical functions
8485         * src/mcs51/gen.c (genFunction, genEndFunction)
8486         * src/ds390/gen.c (genFunction, genEndFunction)
8487
8488 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8489
8490         * src/SDCCsymt.c (sclsFromPtr),
8491         * src/SDCCsymt.h,
8492         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8493         support for standard C idiom of memory mapped variables; for
8494         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8495         to xdata int at 0x1234 tempvar = 1.
8496         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8497         provided by Akiya ISHIDA
8498
8499 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8500
8501         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8502         * src/SDCCval.c (constVal): added reduction from int to char
8503         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8504         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8505         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8506         to ignore the sign
8507         * support/regression/tests/shifts.c: fixed
8508
8509 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8510
8511         * src/z80/gen.c (genXor): Fixed bug #805445
8512
8513 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8514
8515         Fixed bug #621531 (const & volatile confusion in the type chain).
8516         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8517         refer to the const or volatile state of the pointer itself.
8518
8519         * src/SDCCast.c
8520         * src/SDCCglue.c
8521         * src/SDCCicode.c
8522         * src/SDCCsymt.c
8523         * src/SDCCval.c
8524         * src/SDCC.y
8525         * src/SDCCsymt.h
8526         * src/pic/gen.c
8527         * src/pic/ralloc.c
8528         * src/pic16/gen.c
8529         * src/pic16/ralloc.c
8530         * support/regression/tests/const.c
8531
8532 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8533
8534         When checking for duplicated modules, use absolute paths
8535         instead of relative paths.  Files changed:
8536
8537         * as/mcs51/lklib.c
8538         * link/z80/lklib.c
8539
8540 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8541
8542         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8543
8544 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8545
8546         * device/include/string.h: added size_t typedef, changed
8547         prototypes to use size_t, eliminated separate reentrant and
8548         non-reentrant declarations, added _memmove declaration
8549         * device/lib/_memcpy.c: changed to use size_t instead of int,
8550         changed /4 to >>2 to avoid division library call
8551         * device/lib/_memcmp.c,
8552         * device/lib/_memset.c,
8553         * device/lib/_strncat.c,
8554         * device/lib/_strncpy.c,
8555         * device/lib/_strncmp.c: changed to use size_t instead of int
8556         * device/lib/_memmove.c: new file (fixed bug #772294)
8557         * device/lib/Makefile.in: added _memmove.c
8558         * device/lib/z80/asm_strings.s: fixed bug #772290
8559         * support/regression/tests/bitfields.c: attempt to fix host assertion
8560         failure on amd64-unknown-linux2.2
8561
8562 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8563
8564         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8565         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8566         * as/z80/asmain.c (main): fixed bug #801766
8567
8568 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8569
8570         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8571         compilers
8572
8573 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8574
8575         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8576         reported in bug #800609
8577
8578 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8579
8580         * Top header beautifications in src/pic16 directory:
8581           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8582           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8583           pcoderegs.h, ralloc.c, ralloc.h
8584         * main.c: added top header and GPL license notice
8585         * pcode.c: fixed the if-conditional warning
8586
8587 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8588
8589         * device/lib/_mullong.c: replaced int by short for gcc
8590
8591 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8592
8593         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8594         and JUMPTABLE iCodes properly now (worked by accident before)
8595         * src/mcs51/gen.c (leftRightUseAcc),
8596         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8597         iCode properly now. Use getSize instead of nRegs since a & b
8598         aren't part of the nRegs tally.
8599
8600 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8601
8602         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8603         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8604           before instructions that use the _STATUS register
8605
8606 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8607
8608         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8609         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8610         fetching of the pointer
8611         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8612         copied from genNearPointerSet()
8613         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8614         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8615         If they pop r0/r1 they must be called in the opposite order than aopOp().
8616         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8617         (resp. --stack-auto), prepared for --xstack
8618
8619 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8620
8621         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8622
8623 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8624
8625         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8626         these ports have their own __sdcc_external_start()
8627
8628 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8629
8630         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8631         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8632         type for bits was changed. It resulted in bit variables becoming
8633         global, which is not permitted in PIC 14 assembly output.
8634
8635 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8636
8637         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8638
8639 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8640
8641         Z80 and MCS51 linkers complaint if a public symbol is defined
8642         in more than one library module:
8643
8644         * as/mcs51/lklib.c
8645         * link/z80/lklib.c
8646         * as/mcs51/Makefile.in
8647
8648 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8649
8650         A few small changes that speed up the peephole optimizer.
8651
8652         * src/SDCCpeeph.c
8653
8654 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8655
8656         Try to make the peephole optimizer smarter by maintaining
8657         an association between the assembly source code and the
8658         iCodes that originated them. Put this information to use
8659         with a new peephole rule condition "notVolatile" so that
8660         the rules can be aggressive yet still safe.
8661
8662         * src/SDCCpeeph.c
8663         * src/SDCCpeeph.h
8664         * src/mcs51/gen.c
8665         * src/mcs51/peeph.def
8666
8667 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8668
8669         Fixed bug #741761
8670
8671         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8672         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8673         if the left or right operand symbols have the accuse flag set.
8674
8675 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8676
8677         Changed the type of the result of the ! (NOT) operator to char;
8678         previously it returned the same type as the source. This allows
8679         us to eliminate all the genFloatNot functions (all of its target
8680         implementations were very buggy) since !float can use the same
8681         code as !long now.
8682
8683         * src/SDCCicode.c (ast2iCode): ! returns char
8684         * src/mcs51/gen.c (genNot, genNotFloat),
8685         * src/ds390/gen.c (genNot, genNotFloat),
8686         * src/z80/gen.c (genNot, genNotFloat),
8687         * src/pic/gen.c (genNot, genNotFloat),
8688         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
8689
8690 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
8691
8692         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8693         1. Interrupt would not compile properly. Ensure PCLATH register is saved
8694            during interrupts. Ensure WSAVE is located at a shared bank address.
8695         2. Fixed page selection in some places
8696         3. Fixed BTFSS/C to where necessary use registers directly and not simply
8697            the registers name strings.
8698         4. Fixed "signed / unsigned compare" compiler warnings.
8699         5. The PIC port manages its own allocation of the general purpose
8700            registers, but makes no attempt to reuse them. As a result when
8701            compiling it soon runs out of general purpose registers. Some
8702            additional code was added to the files pcode.c and device.c to walk
8703            through the function call tree and rename the registers so that they
8704            get reused.
8705
8706         * src/pic/device.c
8707         * src/pic/gen.c
8708         * src/pic/glue.c
8709         * src/pic/pcode.c
8710         * src/pic/pcode.h
8711         * src/pic/ralloc.c
8712         * src/pic/ralloc.h
8713         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
8714         genPlus() & genMinus() when the result is the same as left or right
8715
8716 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8717
8718         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
8719
8720 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8721
8722         Made bitfield a distinct type from bit so that bitfields
8723         convert as per ANSI C and bits retain their traditional
8724         boolean style behaviour. Implemented bitfield support in
8725         the z80 port.
8726
8727         * src/SDCCsymt.h,
8728         * src/SDCCsymt.c,
8729         * src/SDCCast.c,
8730         * src/cdbFile.c,
8731         * src/mcs51/gen.c,
8732         * src/ds390/gen.c: bit v bitfield split
8733         * src/z80/gen.c: New support for bitfields
8734         * support/regression/tests/bitfields.c: reenabled z80,
8735         added more tests
8736
8737 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8738
8739         Rules 246.x, 247.x relate to bitfields, the others speed up
8740         access to xdata mapped I/O devices.
8741
8742         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
8743
8744 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8745
8746         Cleaned up genPackBits and genUnpackBits and added two helper
8747         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
8748         for literal assignments in genPackBits (thanks to Frieder for
8749         reminding me).
8750
8751         * src/mcs51/gen.c
8752         * src/ds390/gen.c
8753
8754 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8755
8756         Fixed bug #748310 (pointer to function type mishandled when the
8757         function name is omitted). Also fixed a SIGSEGV when a function
8758         attribute (reentrant, etc) is used on a non-function or on a
8759         function but misplaced before the parameter list.
8760
8761         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
8762         bug #748310
8763         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
8764         * support/Util/SDCCerr.h,
8765         * support/Util/SDCCerr.c: Added func attr misuse error msg
8766
8767 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8768
8769         Fixed bug #787649 by anonymous
8770         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
8771         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
8772
8773 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8774
8775         Fixed numerous bitfield problems.
8776
8777         * src/SDCC.y: More bitfield related error checking
8778         * src/SDCCsymt.h,
8779         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
8780         * support/Util/SDCCerr.h,
8781         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
8782         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8783         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8784         * support/regression/tests/bitfields.c: tests added
8785
8786 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8787
8788         Made the constant following the "interrupt" keyword optional. If
8789         omitted, the function will not automatically be given an entry
8790         in the interrupt vector table (similar to #pragma NOIV, but
8791         less syntacticly kludgy). The interrupt number is also now
8792         range checked. Also fixed a bug in the high order bit example
8793         in the manual.
8794
8795         * src/SDCC.y
8796         * src/SDCCmem.c
8797         * src/SDCCglue.c
8798         * src/SDCCsymt.h
8799         * support/Util/SDCCerr.c
8800         * support/Util/SDCCerr.h
8801         * doc/sdccman.lyx
8802
8803 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8804
8805         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
8806         * src/SDCCicode.c (operandOperation): rewritten some ops
8807         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
8808         * src/SDCCsymt.c (computeType): literals are handled the same way as any
8809         other type
8810         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
8811         be re-activated by defining REDUCE_LITERALS)
8812         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
8813         unsigned, but are signed by default
8814         * src/SDCCval.c (constVal): rearranged
8815         * src/SDCCval.c (valMod): preliminary fix
8816         * src/SDCCval.c (valCastLiteral): use TYPE_* types
8817         * support/regression/literalop.c: added, work in progress
8818
8819 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8820
8821         Generate warnings for useless declarations like "char data;"
8822         that don't do what new users expect.
8823
8824         * src/SDCC.y
8825         * support/Util/SDCCerr.h
8826         * support/Util/SDCCerr.c
8827
8828 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
8829
8830         * src/SDCCval.c (valMult): fix overflow detection of negative int
8831
8832 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8833
8834         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
8835
8836         Changes to support big endian targets:
8837
8838         * src/ports.h
8839         * src/SDCCglue.c
8840         * src/avr/main.c
8841         * src/ds390/main.c
8842         * src/izt/i186.c
8843         * src/mcs51/main.c
8844         * src/pic/main.c
8845         * src/pic16/main.c
8846         * src/xa51/main.c
8847         * src/z80/main.c
8848
8849 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
8850
8851         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
8852         * device/lib/time.c: fixed warning "integer overflow in expression"
8853
8854 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
8855
8856         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
8857         * src/SDCCval.c (constVal): changed default to signed; hex and octal
8858         constants are unsigned; added recognition of "u" flag for unsigned
8859         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
8860         * src/SDCCval.c (valDiv, valMod): fixed signdness
8861         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
8862         signedness of modulo, left and right shift
8863         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
8864         * support/Util/SDCCerr.h: added warning W_INT_OVL
8865         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
8866         * src/SDCCast.c (ast_print): improved output of constants
8867
8868 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8869
8870         Fixed some warnings when building with MSVC:
8871
8872         * as\mcs51\asdata.c
8873         * as\z80\asdata.c
8874         * as\mcs51\asm.h
8875         * as\z80\asm.h
8876         * link\z80\aslink.h
8877         * link\z80\lkdata.c
8878         * link\z80\lkeval.c
8879         * link\z80\lkgb.c
8880         * link\z80\lkihx.c
8881         * link\z80\lks19.c
8882         * link\z80\lksym.c
8883         * support\cpp2\cpplib.c
8884         * src\ds390\gen.c
8885         * src\mcs51\gen.c
8886
8887 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
8888
8889         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
8890
8891 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8892
8893         * support\librarian\clean.mk: Do not remove Makefile.
8894         * support\librarian\Makefile: added.
8895
8896 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8897
8898         Added librarian to MSVC build:
8899         * all.dsp
8900         * sdcc.dsw
8901         * support\librarian\librarian.dsp
8902
8903         'configure' not needed for librarian, removed:
8904         * support\librarian\configure
8905         * support\librarian\configure.in
8906         * support\librarian\config_in.h
8907         * support\librarian\Makefile.in
8908
8909         Hopefully these ones built the librarian and the rest of sdcc properly:
8910         * Makefile
8911         * Makefile.common.in
8912
8913         Messed up 'configure', so revert to previous version:
8914         * configure
8915         * configure.in
8916
8917 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
8918
8919         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
8920         there, while the mantissa of a double is "only" 53 bits wide.
8921
8922 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8923
8924         Adding sdcclib to the build.  MSVC project coming soon.
8925         Files added/changed:
8926
8927         * support\librarian\clean.mk
8928         * support\librarian\configure
8929         * support\librarian\configure.in
8930         * support\librarian\config_in.h
8931         * support\librarian\Makefile.bcc
8932         * support\librarian\Makefile.in
8933         * support\librarian\sdcclib.c
8934         * Makefile.bcc
8935         * Makefile
8936         * Makefile.common.in
8937         * configure
8938         * configure.in
8939
8940 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8941
8942         Linker now complaints if linked modules have conflicting options, for
8943         example, one compiled using --model-large and another one compiled with
8944         --model-small.  The following files were modified:
8945
8946         * as\mcs51\asdata.c
8947         * as\mcs51\aslink.h
8948         * as\mcs51\asm.h
8949         * as\mcs51\asmain.c
8950         * as\mcs51\asout.c
8951         * as\mcs51\i51pst.c
8952         * as\mcs51\lkdata.c
8953         * as\mcs51\lklibr.c
8954         * as\mcs51\lkmain.c
8955         * as\z80\asdata.c
8956         * as\z80\asm.h
8957         * as\z80\asmain.c
8958         * as\z80\asout.c
8959         * as\z80\z80pst.c
8960         * link\z80\aslink.h
8961         * link\z80\lkdata.c
8962         * link\z80\lklibr.c
8963         * link\z80\lkmain.c
8964         * src\SDCCglue.c
8965
8966 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8967
8968         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
8969         as/mcs51/lklibr.c: Generate a warning when a library is not found.
8970
8971 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
8972
8973         * src/z80/mappings.i: fix _mul[us][int,long] entries
8974
8975 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8976
8977         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
8978
8979 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
8980
8981         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
8982         * support/regression/tests/bitopcse.c: added
8983         fixed warning:
8984         * src/avr/gen.c:
8985         * src/pic/gen.c:
8986         * src/pic16/gen.c:
8987         * src/z80/gen.c:
8988         * src/xa51/gen.c:
8989
8990 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8991
8992         added support for new library format to z80, gbz80 linkers:
8993         *link/z80/aslink.h
8994         *link/z80/lklex.c
8995         *link/z80/lklib.c
8996         *link/z80/lklist.c
8997
8998 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
8999
9000         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
9001         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
9002
9003 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
9004
9005         added DUMMY_READ_VOLATILE:
9006         * src/SDCC.y:
9007         * src/avr/gen.c:
9008         * src/xa51/gen.c:
9009         * src/z80/gen.c:
9010         * src/pic/gen.c:
9011         * src/pic16/gen.c:
9012         * src/mcs51/gen.c:
9013         * src/ds390/gen.c:
9014         * src/SDCCcse.c (algebraicOpts): many improvements
9015         * src/SDCCcse.h: removed algebraicOpts()
9016         * src/SDCCicode.c (picDummyRead): added
9017
9018 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9019
9020         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
9021         "Insufficient space in data memory".
9022
9023 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9024
9025         * src/mcs51/gen.c: fixed bug #771358
9026         * src/z80/gen.c: fixed bug #759087
9027
9028 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
9029
9030         * src/pic16/glue.c: minor cleanup by Vangelis
9031
9032 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9033
9034         * device/include/regc515c.h: fixed #758477
9035         * device/lib/_gptrget.c: saving some cycles in generic pointer get
9036         * device/lib/_gptrput.c: saved a few bytes
9037         * my tab spacing is 8, yours too?)
9038         * device/lib/_ser.c: process RX bytes earlier than TX bytes
9039         * device/lib/serial.c: process RX bytes earlier than TX bytes
9040         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
9041
9042 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9043
9044         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
9045
9046 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9047
9048     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
9049
9050 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
9051
9052         * device/lib/Makefile.in: bad fix, reverted to 1.43
9053
9054 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
9055
9056         * device/lib/Makefile.in: added missing z80 object files
9057
9058 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
9059
9060         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
9061         pic16 progress by Vangelis:
9062         * src/SDCCglobl.h:
9063         * src/SDCCmain.c:
9064         * src/pic/Makefile:
9065         * src/pic:
9066         * pic/Makefile:
9067         * pic16/device.c:
9068         * pic16/device.h:
9069         * pic16/gen.c:
9070         * pic16/gen.h:
9071         * pic16/genarith.c:
9072         * pic16/glue.c:
9073         * pic16/main.c:
9074         * pic16/pcode.c:
9075         * pic16/pcode.h:
9076         * pic16/pcodepeep.c:
9077         * pic16/peeph.def:
9078
9079 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9080
9081     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
9082
9083 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9084
9085     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
9086     added gbz80 build to MSVC project.
9087     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
9088     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
9089     from 8051 stuff and setup so it links using a .lnk file.
9090
9091 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9092
9093     * support/librarian/sdcclib.c: sdcc librarian.
9094     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
9095     with sdcclib.
9096
9097 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9098
9099     * as/mcs51/lkmain.c: properly handle extensions in function afile.
9100
9101 2003-07-02  Borut Razem <borut.razem AT siol.net>
9102
9103         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
9104         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
9105         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
9106         src/xa51/main.c, src/z80/main.c:
9107         virtualization of glue() function: each port has it's own glue function,
9108         which is accessed by do_glue function pointer in PORT.general structure
9109
9110 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
9111
9112         * DS800C400 fun, improved ROM interface and tinibios.
9113
9114 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
9115
9116         * More support for DS80C400. Now includes beginning of interface to ROM.
9117
9118 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
9119
9120         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
9121
9122 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9123
9124         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
9125
9126 2003-06-19  Borut Razem <borut.razem AT siol.net>
9127
9128         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
9129
9130 2003-06-19  Borut Razem <borut.razem AT siol.net>
9131
9132         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
9133         fixed Z80 port - crt0.o: cannot open.
9134
9135 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
9136
9137         * support/Util/MySystem.c (merge_command): revert bad fix
9138
9139 2003-06-18  Borut Razem <borut.razem AT siol.net>
9140
9141         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9142
9143 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9144
9145         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9146         option --use-stdout sends errors to stdout instead of stderr.
9147
9148 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9149
9150         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9151
9152 2003-06-15  Borut Razem <borut.razem AT siol.net>
9153
9154         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9155         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9156         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9157         fixed width array of pointers replaced with sets;
9158         multiple include and lib paths ared transferred to preprocessor and linker
9159         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9160         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9161         fixed width array of pointers
9162         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9163         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9164         fixupPath(), getPathDifference()
9165         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9166         fixed width array of pointers
9167
9168 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9169
9170         * src/pic16/ralloc.c: fix warnings
9171         * src/pic16/pcode.c: fix warning
9172
9173 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9174
9175          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9176         know all the details, but essentially this set of changes enable
9177         the pic16 port to generate movff instructions and generate assembler
9178         directives,
9179         * src/SDCCmain.c:
9180         * src/pic16/gen.c:
9181         * src/pic16/glue.c:
9182         * src/pic16/pcode.c:
9183         * src/pic16/device.c:
9184         * src/pic16/main.c:
9185         * src/pic16/pcode.h:
9186         * src/pic16/pcoderegs.c:
9187         * src/pic16/ralloc.c:
9188         * src/pic16/ralloc.h:
9189
9190 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9191
9192         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9193         added option --vc, so sdcc errors and warnings are compatible with
9194         Microsoft Visual Studio.
9195
9196 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9197
9198         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9199           device/lib/libfloat.lib: added atof function.
9200
9201 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9202
9203         * doc/sdccman.lyx: updated to Lyx 1.3
9204         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9205         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9206         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9207
9208 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9209
9210         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9211
9212 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9213
9214         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9215           additions to the "related tools/documentation" section
9216
9217 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9218
9219         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9220
9221 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9222
9223         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9224         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9225
9226 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9227
9228         * doc/sdccman.lyx: fix double dash and other minor things
9229         * doc/Makefile: fix double dash
9230
9231 2003-05-28  Karl Bongers(patches from Martin Helmling)
9232         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9233           condition and ignore commands.
9234
9235 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9236
9237         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9238           is in parts still quite out of date, I did changes as far as I felt makes sense
9239           for a non-native english speaker.
9240           Please feel free to add to the manual or to correct my changes.
9241         * doc/Makefile: undid touching the date of intermediate tex files.
9242
9243 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9244
9245         * doc/sdccman.lyx: Manual has an index now
9246
9247 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9248
9249         Finalize muluint/mulsint and mululong/mulslong merging:
9250         * device/lib/_mulint.c
9251         * device/lib/_mullong.c
9252         * device/lib/gbz80/mul.s
9253         * device/lib/gbz80/stubs.s
9254         * device/lib/z80/mul.s
9255         * device/lib/z80/stubs.s
9256         * src/SDCCsymt.c (initCSupport)
9257
9258 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9259
9260         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9261         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9262           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9263           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9264           instead of /Zm500.
9265
9266 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9267
9268         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9269           the regression tests I'm not brave enough to enable 245.b, 245.c
9270         * doc/sdccman.lyx: added latex preamble for hyperref package.
9271           Using pdflatex this will give you a hyperlinked pdf file with
9272           bookmarks. (prepend '%' before /usepackage if this breaks something)
9273
9274 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9275
9276          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9277
9278 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9279
9280         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9281
9282 2003-05-21    <johan AT balder>
9283
9284         * src/SDCCglue.c (printIval): fixed bug #739934
9285
9286 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9287
9288         Applied patch from bug 737905 (renamed yylineo to mylineno):
9289         * src/altlex.c
9290         * src/SDCCast.c
9291         * src/SDCglobl.h
9292         * src/SDCC.lex
9293         * src/SDCCsymt.c
9294         * src/SDCCval.c
9295         * src/pic16/pcode.c: Cleaned warnings
9296         * src/pic16/pcodeflow.c: Cleaned warnings
9297         * src/pic16/pcoderegs.c: Cleaned warnings
9298
9299 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9300
9301         * src/pic16/pcode.c: Cleaned warnings
9302         * src/pic16/pcodepeep.c: Cleaned warnings
9303         * src/pic16/ralloc.c: Cleaned warnings
9304
9305 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9306
9307         * doc/sdccman.lyx: fixed bug 739745
9308         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9309
9310 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9311
9312         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9313         it can be defined with CFLAGS when running configure
9314         * src/SDCCmain.c: fixed compiling + linking with object files
9315
9316 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9317
9318         * configure.in: configure for pic16 port,
9319             added --disable-pic16-port
9320         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9321         * src/SDCCmain.c: linkOptions is changed to set *,
9322             added if/endif conditional macros to remove options help
9323             messages from optionsTable when a port is not configured, added
9324             support for the PIc16 port in the ports table, when executing
9325             the compiler with no port specified on command line, a default
9326             port is selected with the new macro DEFAULT_PORT which is
9327             defined in port.h, in setDefaultOptions() linkOptions is removed
9328             from initialization assignment, since now it is a set,
9329             parseCmdLine uses setParseWithComma for linkOptions, in
9330             linkEdit() linkOptions are accessed with new function indexSet()
9331             which returns the i'th item of a set variable. See SDCCset.c, in
9332             linkEdit() when calling buildCmdLine(), added linkOptions as
9333             last argument. Now users can pass arguments to gplink via the
9334             -Wl option, main() uses pic16glue() to glue up pic16 programs
9335         * src/SDCCpeeph.c: various changes to support pic16
9336         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9337             return the i'th item of the set
9338         * src/SDCCset.h: added function prototype for indexSet()
9339         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9340         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9341         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9342             added macro DEFAULT_PORT
9343         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9344         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9345             generated
9346         * src/pic16/glue.c: commented out some error producing lines
9347         * src/pic16/main.c: __config directives are commented out to stop
9348             gpasm complaining and test the linkage with gplink, _linkCmd and
9349             _asmCmd changed to be more gplink and gpasm friendly
9350         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9351             produced an error when parsed, peep rule 12 is added to utilize
9352             movff, but it is commented out since the pCode does not support
9353             yet a command with 2 address arguments
9354
9355 2003-05-18    <johan AT balder>
9356
9357         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9358         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9359 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9360
9361         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9362   Added feature to script commands from file.
9363
9364 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9365
9366         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9367         * src/SDCCutil.c: include ctype.h for win32
9368
9369 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9370
9371         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9372
9373 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9374
9375         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9376   Fixed so you can set breakpoints prior to run, run does not stop
9377   on entry now.  Add tbreak.  Other enhancements and fixes for use
9378   with ddd.
9379
9380 2003-05-12  Borut Razem <borut.razem AT siol.net>
9381
9382         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9383
9384 2003-05-11  Borut Razem <borut.razem AT siol.net>
9385
9386         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9387         the path of bin directory, so that PATH is the only env. variable, which has to be set
9388         in case of standard installation.
9389         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9390         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9391         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9392
9393 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9394
9395         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9396         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9397         temp files are in the port dir; clean the gen/test directory when
9398         generating new test.c
9399         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9400         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9401         * support/regression/tests/zeropad.c: added
9402
9403 2003-05-09    <johan AT balder>
9404
9405         * src/SDCCglue.c: fixed bug #597940
9406
9407 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9408
9409         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9410   cache sfr, optimize next,step, fix off by one sourceline,
9411   support ddd list function.
9412         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9413
9414 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9415
9416         * support/regression/HTMLgen.py: added compare_s2f()
9417         * support/regression/Makefile: redo 1.27
9418         * support/regression/generate-cases.py: redo 1.5
9419
9420 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9421
9422         * support/regression/tests/float.c: workaround 33 bit hex constant
9423         * support/regression/tests/simplefloat.c: fix division for host
9424
9425 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9426
9427         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9428         that tame's the PIC's over-aggressive optimizer.
9429
9430 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9431
9432          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9433          support for MSVC.
9434
9435 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9436
9437         Initial support for DS80C400. "Hello world" runs on TINIm400
9438         (with polled I/O).
9439
9440 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9441
9442          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9443          * Some notes on ddd usage added in debugger/README
9444          Martin Helmling adding more features and fixes for ddd GUI debugger.
9445          Code added for nexti, stepi, up, down, and other adjustments.
9446
9447 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9448
9449         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9450         * src/pic/peeph.def Added two rules to optimize carry manipulation
9451         * src/pic/* removed debug printfs
9452
9453 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9454
9455         * debugger/mcs51/cmd.c: added header newalloc.h
9456
9457 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9458
9459         * as/Makefile: new EXEEXT
9460         * as/z80/Makefile: remove trailing slash of BUILDIR
9461         * as/z80/clean.mk: new EXEEXT
9462         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9463         * support/cpp2/Makefile.in: new EXEEXT
9464         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9465
9466 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9467
9468         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9469         EXEEXT was introduced to fix all related problems with targets
9470         "clean", "install" and "uninstall"; a couple of further flaws
9471         especially with "clean" have been fixed too
9472         * as/mcs51/Makefile.in
9473         * as/mcs51/clean.mk
9474         * as/z80/Makefile
9475         * Makefile
9476         * clean.mk
9477         * debugger/mcs51/Makefile.in
9478         * debugger/mcs51/clean.mk
9479         * link/z80/Makefile
9480         * link/z80/Makefile.in
9481         * link/z80/clean.mk
9482         * link/Makefile
9483         * packihx/Makefile.in
9484         * packihx/clean.mk
9485         * sim/ucsim/Makefile
9486         * sim/ucsim/clean.mk
9487         * sim/ucsim/avr.src/Makefile.in
9488         * sim/ucsim/avr.src/clean.mk
9489         * sim/ucsim/s51.src/Makefile.in
9490         * sim/ucsim/s51.src/clean.mk
9491         * sim/ucsim/xa.src/Makefile.in
9492         * sim/ucsim/xa.src/clean.mk
9493         * sim/ucsim/z80.src/Makefile.in
9494         * sim/ucsim/z80.src/clean.mk
9495         * sim/ucsim/main_in.mk
9496         * sim/ucsim/packages_in.mk
9497         * sim/ucsim/gui.src/Makefile.in
9498         * sim/ucsim/gui.src/serio.src/Makefile.in
9499         * sim/ucsim/gui.src/serio.src/clean.mk
9500         * src/Makefile.in
9501         * src/clean.mk
9502         * support/cpp2/Makefile.in
9503         * support/cpp2/clean.mk
9504         * support/makebin/Makefile
9505         * support/makebin/clean.mk
9506         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9507         * doc/sdccman.lyx: --program-suffix no longer needed
9508
9509 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9510
9511          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9512          Martin Helmling added support for ddd GUI debugger.
9513          Code added to display assembly, set variables, and other commands
9514          to interface to ddd.
9515
9516 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9517
9518         * as/Makefile: fix target clean
9519         * as/clean.mk: fix target clean
9520         * as/z80/clean.mk: fix target clean
9521
9522 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9523
9524         * Makefile.common.in: added  AT EXEEXT AT
9525         * configure.in: removed all mingw32 stuff
9526         * configure: rebuilt from configure.in
9527         * doc/sdccman.lyx: updated section "installation"
9528         * support/scripts/sdcc_mingw32: adapted to configure
9529         * support/scripts/sdcc_cygwin_mingw32: added
9530
9531 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9532
9533         * src/pic Added object file support for the PIC port
9534         * src/pic Applied patch from Craig Franklin (this started the object file support)
9535         * src/regression Updated the PIC regression tests for object files
9536
9537 2003-04-20  Borut Razem <borut.razem AT siol.net>
9538
9539         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9540           lklex.c: In function `getfid':
9541           lklex.c:203: warning: array subscript has type `char'
9542         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9543           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9544         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9545           stack handling macros
9546
9547 2003-04-19  Borut Razem <borut.razem AT siol.net>
9548
9549         * "handling space characters in file path" task:
9550         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9551         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9552         * support/Util/MySystem.h: make it self-sufficient
9553         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9554           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9555           handling space characters in file path
9556         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9557           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9558         * support/Util/MySystem.c: handling space characters in executable's path
9559
9560 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9561
9562         * as/z80/Makefile: fix permanent rebuild of z80
9563         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9564         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9565
9566 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9567
9568         * src/SDCCopt.c: add special case optimization to replace modulo by
9569           a power of two with a bitwise AND.
9570
9571 2003-04-18    <johan AT balder>
9572
9573         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9574
9575 2003-04-17    <johan AT balder>
9576
9577         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9578         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9579
9580 2003-04-13  Borut Razem <borut.razem AT siol.net>
9581
9582         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9583         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9584           fixed mingw problem in adl_NORMALIZE_PATH
9585
9586 2003-04-12  Borut Razem <borut.razem AT siol.net>
9587
9588         * fixed "#pragma SAVE/RESTORE can not be nested":
9589         * src/SDCC.lex: reworked pragma handling functions
9590         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9591         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9592
9593 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9594
9595         * src/SDCCutil.c (pathEquivalent): defined but not used
9596         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9597         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9598         * configure: rebuilt from configure.in
9599         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9600         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9601         * device/include/Makefile.in: replace sdcc_datadir
9602         * device/lib/Makefile.in: replace sdcc_datadir
9603         * Makefile.common.in: add LDFLAGS from configure
9604         * packihx/Makefile.in: use LDFLAGS
9605         * src/Makefile.in: use LDFLAGS
9606         * support/cpp2/Makefile.in: add LDFLAGS from configure
9607         * support/makebin/Makefile: use LDFLAGS
9608         * .version: bumped version number to 2.3.5
9609
9610 2003-04-12  Borut Razem <borut.razem AT siol.net>
9611
9612         * completed "different paths" task:
9613         * src/SDCCmacro.c: fixed bug in handling quotes
9614         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9615         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9616
9617 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9618
9619         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9620
9621 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9622
9623         * ds390/gen.c ds390/peeph.def: fix bug 706781
9624
9625 2003-04-11  Borut Razem <borut.razem AT siol.net>
9626
9627         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9628
9629 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9630
9631         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9632         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9633          set - this bit used to not be set...).
9634         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9635           bad code in PIC Port
9636         * src/regression/and2.c added to test bug 609268
9637         * src/regression/Makefile added and2.c to regression test
9638
9639
9640 2003-04-08    <johan AT CP255758-A>
9641
9642         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9643         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9644         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9645
9646 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9647
9648         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9649         fix bug #487815
9650         * support/cpp2/Makefile.in: fix bug #487815
9651         * configure: rebuilt from configure.in
9652         * Makefile.common.in: docdir changed, new path suffixes
9653         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9654         * sdcc_vc_in.h: reflect changes from sdccconf.h
9655         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9656         * src/SDCCutil.h: remove BINDIR hack
9657         * doc/sdccman.lyx: update new path hierarchy
9658
9659 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9660
9661         * src/SDCCpeeph.c: added okToRemoveSLOC test
9662
9663 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9664
9665         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9666
9667 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9668
9669         * src/SDCCpeeph.c: added labelIsReturnOnly test
9670         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9671
9672 2003-04-05    <johan AT balder>
9673
9674         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
9675         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
9676         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
9677         * src/SDCCast.c: fixed a warning
9678         * src/SDCCast.h: fixed a warning
9679         * src/SDCCicode.c (operandFromAst): fixed a warning
9680
9681 2003-04-04    <johan AT balder>
9682
9683         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
9684         * src/SDCCast.c (decorateType): fixed bug #715076
9685         * src/SDCC.y: fixed bug #702907
9686
9687 2003-04-03    <johan AT balder>
9688
9689         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
9690         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
9691         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
9692         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
9693         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
9694
9695 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
9696
9697         * _decdptr.c: fix return values
9698         * _gptrget.c: fix return values
9699         * _gptrgetc.c: fix return values
9700         * _gptrput.c: fix return values
9701         * _mulint.c: fix return values
9702         * as/z80/Makefile: fix 'make -j' problem
9703
9704 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
9705
9706         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
9707         * configure.in: big cleanup, updated to autoconf 2.5x
9708         * configure: rebuilt from configure.in
9709         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9710         * sdcc_vc_in.h: reflect changes from sdccconf.h
9711         * doc/Makefile: fixed a flaw in "make install"
9712
9713 2003-04-02    <johan AT balder>
9714
9715         * src/ds390/gen.c (genCmp): no comments
9716         * src/mcs51/gen.c (genCmp): no comments
9717         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
9718         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
9719
9720 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
9721
9722         * support/regression/generate-cases.py: place generated file in given sub directory
9723         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
9724         * support/regression/Makefile: improvements for 'make -j';
9725         side effect: it's simpler and faster now
9726
9727 2003-03-31  Borut Razem <borut.razem AT siol.net>
9728
9729         * src/z80/main.c: link-{port} and as-{port} defined without path
9730         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
9731
9732 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
9733
9734         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
9735
9736 2003-03-30  Borut Razem <borut.razem AT siol.net>
9737
9738         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
9739           changed type of list parameter to set
9740         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
9741         * src/port.h: changed type of do_assemble() parameter to set
9742         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
9743           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
9744           definition of "cppoutfilename" macro with NULL value in preProcess()
9745         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
9746         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
9747         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
9748           replaced with set *binPathSet
9749         * shash_add() deallocates the item, if allready exsists, before adding the new one
9750         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
9751
9752 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
9753
9754         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
9755           a nested for loop bug in the PIC port
9756         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
9757           for loops
9758
9759 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
9760
9761         * support/Util/dbuf.h: remove C++ stuff to make it portable
9762
9763 2003-03-28  Borut Razem <borut.razem AT siol.net>
9764
9765         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
9766           literal strings in stringLiteral()
9767         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
9768         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
9769           to the project
9770
9771 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
9772
9773         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
9774
9775 2003-03-26    <johan AT balder>
9776
9777         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
9778         * src/ds390/gen.c (saveRegisters): catched symbol abuse
9779         * src/SDCCast.c (decorateType): fixed " -v < 3"
9780
9781 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
9782
9783         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
9784         Added Lenny Story's debug infrastructure changes:
9785         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
9786         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
9787         * src/cdbFile.c: added
9788         * src/SDCCdebug.c: added
9789         * src/SDCCdebug.h: added
9790         * src/SDCCast.c (createFunction)
9791         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
9792         * src/SDCCmain.c (parseCmdLine, main)
9793         * src/SDCCmem.c (redoStackOffsets)
9794         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
9795         * src/SDCCsymt.h
9796         * src/common.h
9797         * src/avr/gen.c (genAVRCode)
9798         * src/ds390/gen.c (gen390Code)
9799         * src/mcs51/gen.c (gen51Code)
9800         * src/pic/gen.c (genpic14Code)
9801         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
9802         * src/xa51/gen.c (genXA51Code)
9803         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
9804
9805 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9806
9807         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
9808         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
9809
9810 2003-03-22    <johan AT balder>
9811
9812         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
9813
9814 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
9815
9816         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
9817         * doc/cdbfileformat.lyx: added, written by Lenny Story
9818         * doc/Makefile: added cdbfileformat.lyx
9819         * doc/clean.mk: added cdbfileformat.lyx
9820
9821 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
9822
9823         * src/mcs51/peeph.def: fix bug #705773
9824
9825 2003-03-20    <johan AT balder>
9826
9827         An sfr/sbit can have an "at #" AND an initializer
9828         * src/SDCCsymt.c (checkSClass):
9829         * src/SDCCmem.c (allocGlobal):
9830         * src/SDCCmem.c (allocLocal):
9831         * src/SDCCast.c (createBlock):
9832
9833 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
9834
9835         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
9836
9837 2003-03-16    <johan AT balder>
9838
9839         Undid the hackup of const and volatile, the problem is much bigger
9840         * src/SDCC.y:1.65
9841         * src/SDCCast.c:1.171
9842         * src/SDCCglue.c:1.138
9843         * src/SDCCicode.c:1.146
9844         * src/SDCCsymt.c:1.150
9845         * src/SDCCval.c:1.65
9846
9847 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
9848
9849         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
9850         * src/ds390/gen.c (genAddrOf): fixed bug #704087
9851
9852 2003-03-13    <johan AT balder>
9853
9854         Hackup const and volatile modifiers in type chains a bit:
9855         * src/SDCC.y:1.63
9856         * src/SDCCast.c:1.169
9857         * src/SDCCglue.c:1.136
9858         * src/SDCCicode.c:1.143
9859         * src/SDCCsymt.c1.146
9860         * src/SDCCsymt.h1.59
9861         * src/SDCCval.c:1.63
9862
9863 2003-03-12    <johan AT balder>
9864
9865         * src/SDCCBBlock.h: more LRH debugging junk
9866         * src/SDCCcflow.h: more LRH debugging junk
9867         * src/SDCCloop.c: more LRH debugging junk
9868         * src/SDCC.y (struct_declaration): fixed bug #697590
9869         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
9870         * src/ds390/gen.c (aopForRemat): fixed bug #700031
9871         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
9872
9873 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9874         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
9875         test function names must now match exactly).
9876         * src/SDCCcse.c: added special case in findCheaperOp to allow
9877         extending a short integer. Makes less awful code for bug 700121 test case.
9878
9879 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9880
9881         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
9882         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
9883
9884 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9885
9886         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
9887         actually called (operandsNotEqual() was called for all
9888         operandsNotEqualX tests).
9889
9890 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
9891
9892         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
9893         with shorter literals. Fixes bug 700121.
9894
9895 2003-03-11    <johan AT balder>
9896
9897         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
9898
9899 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
9900
9901         * src/SDCCloop.c (mergeRegions): an evil beast is dead
9902         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
9903
9904 2003-03-10  Borut Razem <borut.razem AT siol.net>
9905
9906         * src/SDCCmain.c: pipe preprocessor's output
9907         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
9908         * sdcc_vc_in.h: define pclose as _pclose for WIN32
9909         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
9910         which closes all pipes in pipeSet set
9911         * src/SDCCset.c: free deleted item in function deleteSetItem()
9912         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
9913         moved from z80 to src subproject
9914         * .version: increased version number to 2.3.4
9915
9916 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
9917
9918         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
9919         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
9920         * support/regression/ports/xa51/spec.mk: fix typo
9921
9922 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
9923
9924         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
9925
9926 2003-03-09  Borut Razem <borut.razem AT siol.net>
9927
9928         * src/SDCCmain.c: pipe preprocessor's output
9929         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
9930         * sdcc_vc_in.h: define pclose as _pclose for WIN32
9931         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
9932         which closes all pipes in pipeSet set
9933         * src/SDCCset.c: free deleted item in function deleteSetItem()
9934         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
9935         moved from z80 to src subproject
9936
9937 2003-03-09  Borut Razem <borut.razem AT siol.net>
9938
9939         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
9940         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
9941         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
9942         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
9943         * src/SDCCglobl.h: unification of WIN32 native definitions
9944
9945 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9946
9947         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
9948
9949 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
9950
9951         * src/configure.in:   check for endianess (even while cross-compiling)
9952         * src/configure:      check for endianess (even while cross-compiling)
9953         * src/configure_in.h: check for endianess (even while cross-compiling)
9954         * src/avr/gen.c:        remove old endianess stuff
9955         * src/mcs51/gen.c:      remove old endianess stuff
9956         * src/ds390/gen.c:      remove old endianess stuff
9957         * src/pic/gen.c:        remove old endianess stuff
9958         * src/pic/genarith.c:   remove old endianess stuff
9959         * src/pic/glue.c:       fix endianess check
9960         * src/pic16/gen.c:      remove old endianess stuff
9961         * src/pic16/genarith.c: remove old endianess stuff
9962         * src/pic16/glue.c:     fix endianess check
9963         * src/xa51/gen.c:       remove old endianess stuff
9964         * src/z80/gen.c:        fix endianess check
9965         * src/SDCCglue.c:       fix endianess check
9966         * src/ds390/peeph.def: fix bug 700036
9967
9968 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
9969
9970         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
9971         * src/configure: find appropriate data-types on host for SDCC's int and long
9972         * src/configure.in: find appropriate data-types on host for SDCC's int and long
9973         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
9974         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
9975
9976 2003-03-07    <johan AT balder>
9977
9978         Just a big NOOP:
9979                 some minor cleanups before the big shot
9980                 OP_DEFS and OP_USES now use Kevin's protection
9981                 new option --nolabelopt
9982
9983         * src/SDCCBBlock.c:
9984         * src/SDCCast.c,:
9985         * src/SDCCcflow.c:
9986         * src/SDCCcse.c:
9987         * src/SDCCicode.c:
9988         * src/SDCCicode.h:
9989         * src/SDCClabel.c:
9990         * src/SDCCloop.c:
9991         * src/SDCCmain.c:
9992         * src/ds390/ralloc.c:
9993         * src/mcs51/ralloc.c:
9994         * src/pic/ralloc.c:
9995         * src/xa51/ralloc.c:
9996         * src/z80/ralloc.c:
9997
9998 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
9999
10000         * src/pic/pcode.c (get_op): fix 64 bit warnings
10001         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
10002         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
10003         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
10004         * support/regression/tests/malloc.c: fix 64 bit warnings
10005
10006 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
10007
10008         * src/mcs51/gen.c (genMinus): fixed bug 696436
10009
10010 2003-03-02  Borut Razem <borut.razem AT siol.net>
10011
10012         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
10013
10014 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
10015
10016         * configure.in: test for mkstemp
10017         * sdccconf_in.h: add HAVE_MKSTEMP
10018
10019 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
10020
10021         * device/include/ctype.h: removed warning while using --stack-auto
10022         * device/include/malloc.h: removed warning while using --stack-auto
10023         * device/include/string.h: removed warning while using --stack-auto
10024
10025 2003-02-23  Borut Razem <borut.razem AT siol.net>
10026
10027         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
10028         because NDEBUG is defined (see man assert)
10029         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
10030
10031 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10032
10033         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
10034         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
10035
10036 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10037
10038         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
10039         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
10040
10041 2003-02-18    <johan AT balder>
10042
10043         * as/mcs51/asmain.c (asmbl): module can start with a digit
10044         * as/z80/asmain.c (asmbl): module can start with a digit
10045
10046 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
10047
10048         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
10049         * src/asm.c: fix pipe() for Mingw32
10050
10051 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
10052
10053         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
10054         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
10055         make -V work again; --c1mode reads now from stdin
10056         * doc/sdccman.lyx: added --c1mode
10057         * support/Util/SDCCerr.c: new messages for c1 mode
10058         * support/Util/SDCCerr.h: new messages for c1 mode
10059         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
10060
10061 2003-02-15    <johan AT balder>
10062
10063         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
10064
10065 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
10066
10067         * doc/sdccman.lyx: Environment variables, -o and other minor things
10068
10069 2003-02-14    <johan AT balder>
10070
10071         * src/xa51/main.c: before anyone really tries to use it :)
10072
10073         * Install doc's in share/sdcc/doc
10074         * removed some obsolete files
10075         * Do a proper make distclean and uninstall
10076         M Makefile.common.in
10077         R sdccbuild.sh
10078         M as/Makefile
10079         M device/include/Makefile.in
10080         M device/lib/Makefile.in
10081         M doc/sdccman.lyx
10082         M link/Makefile
10083         M sim/ucsim/doc/Makefile.in
10084         M src/clean.mk
10085         R src/avr/peeph.rul
10086         R src/xa51/peeph.rul
10087         M support/cpp2/Makefile.in
10088         M support/makebin/Makefile
10089
10090
10091 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
10092
10093         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
10094
10095 2003-02-10  Borut Razem <borut.razem AT siol.net>
10096
10097         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
10098         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
10099         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
10100         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
10101         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
10102         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
10103         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
10104         src/z80/Makefile.bcc: Borland Makefile cleanup
10105         * as/z80/Makefile.bcc: Added Borland Makefile
10106         * support/cpp2/borland.h: Removed
10107
10108 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
10109
10110         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
10111         * src/SDCC.lex: new pragma NOIV
10112         * src/SDCCglobl.h: new pragma NOIV
10113         * src/SDCCmem.c: new pragma NOIV
10114
10115 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10116
10117         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
10118
10119 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10120
10121         * src/SDCCmain.c: signal handling is switched off by --debug
10122         * doc/Makefile: small fix for install; use clean.mk again
10123         * doc/clean.mk: clean *.pdf and *.html too
10124
10125 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
10126
10127         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
10128         * device/lib/printfl.c: fix a ds390 bug by making it portable
10129         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
10130         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
10131         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
10132         * debugger/mcs51/cmd.c: converted multi-line string literals
10133         * sim/ucsim/globals.cc: converted multi-line string literals
10134         * src/SDCCmain.c: introduced signal handler to remove temp files
10135         * doc/Makefile: small tweaks, implement clean
10136         * doc: removed generated files
10137
10138 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10139
10140         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10141         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10142         Address Record is not correctly generated for DS390."
10143
10144 2003-02-02  Borut Razem <borut.razem AT siol.net>
10145
10146         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10147         * as/mcs51/asm.h: fixed compilation with Borland C
10148         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10149         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10150         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10151         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10152         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10153         src/z80/Makefile.bcc: delete $(LIB) only if exist
10154         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10155
10156 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10157
10158         * device/include/malloc.h: introduced NULL
10159         * device/include/string.h: introduced NULL
10160         * device/include/stdlib.h: introduced NULL
10161         * device/lib/_memcpy.c: removed NULL
10162         * device/lib/_strcat.c: removed NULL
10163         * device/lib/_strchr.c: removed NULL
10164         * device/lib/_strcmp.c: removed NULL
10165         * device/lib/_strcpy.c: removed NULL
10166         * device/lib/_strcspn.c: removed NULL
10167         * device/lib/_strlen.c: removed NULL
10168         * device/lib/_strncat.c: removed NULL
10169         * device/lib/_strncmp.c: removed NULL
10170         * device/lib/_strncpy.c: removed NULL
10171         * device/lib/_strpbrk.c: removed NULL
10172         * device/lib/_strrchr.c: removed NULL
10173         * device/lib/_strspn.c: removed NULL
10174         * device/lib/_strstr.c: removed NULL
10175         * device/lib/_strtok.c: removed NULL
10176         * device/lib/malloc.c: removed NULL, include own header
10177
10178 2003-02-02    <johan AT balder>
10179
10180         * 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
10181         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10182         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10183         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10184         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10185         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10186
10187 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10188
10189         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10190         area 'DATA'"
10191
10192 2003-02-01    <johan AT balder>
10193
10194         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10195
10196 2003-01-31    <johan AT CP255758-A>
10197
10198         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10199
10200 2003-01-30    <johan AT balder>
10201
10202         * src/SDCCBBlock.c: automatic bug detection
10203         * src/SDCCicode.c: automatic bug detection
10204
10205 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10206
10207         * src/SDCCglobl.h:   now --xram-size 0 works
10208         * src/SDCCmain.c:    now --xram-size 0 works
10209
10210 2003-01-29    <johan AT balder>
10211
10212         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10213
10214 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10215
10216         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10217         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10218         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10219         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10220         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10221         * src/SDCCmain.c:    Added options --xram-size and --code-size
10222
10223 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10224
10225         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10226         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10227
10228 2003-01-27    <johan AT balder>
10229
10230         * src/SDCC.y: fixed bug #613764
10231
10232 2003-01-26    <johan AT balder>
10233
10234         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10235         * src/SDCCsymt.h: fixed bug #673374
10236         * src/SDCCglue.c: fixed bug #661910
10237         * src/SDCCast.c: fixed bug #458099 and 673374
10238
10239 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10240
10241         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10242         * as/mcs51/strcmpi.h: added
10243         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10244         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10245         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10246         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10247         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10248         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10249         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10250         * as/mcs51/Makefile.aslink: new module strcmpi
10251         * as/mcs51/Makefile.asx8051: new module strcmpi
10252         * as/mcs51/Makefil.bcc: new module strcmpi
10253         * as/mcs51/Makefile.in: new module strcmpi
10254         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10255
10256 2003-01-26    <johan AT balder>
10257
10258         * src/SDCCglue.c: reverted back to 1.124
10259         * src/SDCCast.c: reverted back to 1.156
10260         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10261
10262 2003-01-25    <johan AT balder>
10263
10264         * src/SDCCglue.c: A better fix for bug #661910
10265         * src/SDCCast.c: A better fix for bug #661910
10266         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10267
10268 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10269
10270         * src/Makefile.in: remove spawn.o
10271         * src/SDCCmain.c: remove spawn.h
10272         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10273         * src/spawn.c: removed
10274         * src/spawn.h: removed
10275         * support/regression/ports/ds390/spec.mk: link with -r
10276
10277 2003-01-24    <johan AT CP255758-A>
10278
10279         * src/ds390/gen.c (aopOp): fixed bug #667458
10280         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10281         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10282         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10283
10284 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10285
10286         * src/mcs51/peeph.def: better assembler identation by Frieder
10287         * src/mcs51/gen.c: better assembler identation by Frieder
10288
10289 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10290
10291         * as/z80/string.h: removed for gcc 3.2
10292         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10293         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10294
10295 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10296
10297         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10298         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10299         * support/regression/Makefile: separate temp files for ports
10300         * support/regression/generate-cases.py: separate temp files for ports
10301         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10302         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10303
10304 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10305
10306         * moved tinitalk to device/examples/ds390
10307
10308 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10309
10310         * as/mcs51/lkmem.c: rflag is for DS390
10311         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10312         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10313                          (linkEdit): move mem- and map-files the same way as ihx-files
10314         * src/z80/main.c (_setDefaultOptions): removed --generic
10315         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10316         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10317         * src/pic/glue.c (picglue): --c1mode works again
10318         * src/pic16/glue.c (pic16glue): --c1mode works again
10319         * src/asm.c (printCLine): fix #660034
10320
10321 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10322
10323         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10324         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10325         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10326         * as/mcs51/lkmem (summary): better fix for sp problem
10327         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10328         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10329         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10330                                               remove --stack-after-data
10331
10332 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10333
10334         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10335         * src/SDCCutil.c (join): ugly bug: missing '\0'
10336         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10337
10338 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10339
10340         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10341         * src/port.h: typo
10342         * src/pic/main.c (_asmCmd): gpasm supports -o
10343         * src/z80/main.c: more general macros
10344         * device/lib/Makefile.in: remove intermediate files
10345
10346 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10347
10348         * .version: Bumped version number to 2.3.3
10349         * src/SDCCBBlock.c: new option -o
10350         * src/SDCCglobl.h: new option -o
10351         * src/SDCCglue.c: new option -o
10352         * src/SDCCmain.c: new option -o
10353         * src/asm.c: new option -o
10354         * src/ds390/main.c: new option -o
10355         * src/pic/glue.c: new option -o
10356         * src/pic/pcode.c: new option -o
10357         * src/pic/ralloc.c: new option -o
10358         * src/pic16/glue.c: new option -o
10359         * src/pic16/pcode.c: new option -o
10360         * src/pic16/ralloc.c: new option -o
10361         * src/z80/main.c: new option -o
10362         * device/lib/Makefile.in: use -o
10363         * support/regression/ports/ds390/spec.mk: use -o
10364         * support/regression/ports/gbz80/spec.mk: use -o
10365         * support/regression/ports/mcs51/spec.mk: use -o
10366         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10367         * support/regression/ports/z80/spec.mk: use -o
10368         * support/regression/ports/ucz80/spec.mk: use -o
10369         * support/regression/ports/xa51/spec.mk: use -o
10370         * support/regression/fwk/lib/timeout.c: fix usage string
10371
10372 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10373         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10374
10375 2003-01-07    <johan AT balder>
10376
10377         * src/SDCCast.c (decorateType): fixed bug #600035
10378
10379 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10380         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10381         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10382         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10383         * src/pic/pcode.c: outcommented unused variable to remove warnings
10384         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10385
10386 2003-01-06    <karl AT turbobit.com>
10387         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10388    regression tests.
10389
10390 2003-01-06    <johan AT balder>
10391
10392         * src/SDCCicode.c: fixed array add
10393
10394 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10395         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10396         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10397
10398 2003-01-04    <johan AT balder>
10399
10400         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10401
10402 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10403         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10404
10405 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10406         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10407         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10408
10409 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10410         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10411
10412 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10413         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10414
10415 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10416         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10417
10418 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10419
10420     * in \sdcc\as\mcs51\ changed these files in order to create an
10421     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10422     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10423     following files to include the previous two files: aslink.dsp,
10424     Makefile.aslink, Makefile.bcc, and Makefile.in.
10425
10426     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10427     .adb instead of .cdb
10428
10429 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10430
10431         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10432         value from option --iram-size.
10433
10434 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10435
10436         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10437         dram[] array.
10438
10439 2002-09-18    <wiml AT hhhh.org>
10440
10441         * SDCClrange.h: exposed setFromRange() and setToRange()
10442         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10443           packRegsForAccUse() (bug 542397)
10444         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10445           multiple times and emitting the fetch operations more than once
10446           added aopGetUsesAcc() function to allow binary operators to
10447           fetch their operands in the correct order; made genMinus() emit
10448           compact code for X = LITERAL - Y
10449
10450 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10451         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10452         sprintf() in line 1267.
10453
10454 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10455         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10456         like ports.
10457
10458 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10459         Changes to aslink (All the changes are marked with 'JCF'):
10460
10461         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10462         summary().
10463
10464         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10465         area BSEG.  Also moves, if possible, the DATA area down into the internal
10466         ram so more space is available.
10467
10468         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10469         sflag.
10470
10471         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10472         not bytes.  Function summary() which creates a memory usage summary
10473         file with extension .mem.  Reports of overlaping stack and small stack
10474         size.  If the space for the stack is less than 16 bytes aslink trows a
10475         warning.
10476
10477         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10478         the 8051.  Option 'y' for memory summary output file.
10479
10480         Changes to sdcc (All the changes are marked with 'JCF'):
10481
10482         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10483
10484         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10485         overlaying area for it (uses RegBankUsed[4]).
10486
10487         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10488         bank zero as used by default.  By default aslink locates the stack
10489         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10490         the creation of the .mem file.  Delegates the allocation of data area
10491         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10492         the begining of the stack area to aslink.
10493
10494         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10495         glue() in SDCCglue.c creates an area for it.
10496
10497 2002-09-03  Borut Razem <borut.razem AT siol.net>
10498         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10499         sdcc/src/pic/glue.c:
10500         introduced atexit() handler for teporay files removal in case of
10501         errors, assertions, ...
10502
10503 2002-08-29  Borut Razem <borut.razem AT siol.net>
10504         * sdcc/support/cpp2/auto-host_vc_in.h:
10505         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10506         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10507         Maybe there is a similar problem with BORLANDC? It should be checked!
10508
10509         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10510         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10511         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10512         was not executed, and the compiler (cl) launched a warning:
10513         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10514
10515 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10516         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10517
10518 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10519         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10520
10521         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10522           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10523           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10524           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10525           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10526           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10527           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10528         - added Release configuration in VS projects
10529         - review of compiler an linker options
10530         - VC .exe files are generated in bin_vc directory, not to interfere
10531           with binaries generated from other projects (cygwin, mingw, bcc ...)
10532
10533         * sdcc/src/yacc.dsp: added
10534
10535         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10536         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10537         and insert the version number definitions from .version
10538
10539         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10540
10541         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10542         added - genarate auto-host.h using auto-host_vc_in.h as template
10543
10544         * sdcc/sdcc_vc.h,
10545         removed from CVS, generated automatically
10546
10547 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10548         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10549
10550 2002-08-11  Borut Razem <borut.razem AT siol.net>
10551         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10552
10553 2002-08-10  Borut Razem <borut.razem AT siol.net>
10554         * src/SDCCmain.c (main):
10555         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10556         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10557         The consequence was that some temporary files were not removed.
10558
10559         * src/SDCCglue.c:
10560         unification of code in functions tempfilename() and tempfile():
10561         function tempnam() is defined in Visual Studio 6.0 and .NET
10562
10563         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
10564
10565         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10566           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
10567         - removed compiler command line option /WX: Treats all warnings as errors
10568         - update a list of source files, included into the project
10569
10570         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10571           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10572         changed project type to Generic Project so that can be correcly converted to VS.NET project
10573
10574         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10575
10576         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10577
10578         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10579
10580         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10581         added return 0 statements after assert() to make compiler happy
10582
10583         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10584         added newline in the def file to keep MSC compiler satisfied
10585
10586         * sdcc/src/z80/gen.c:
10587         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10588           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10589         - solved MSC error in function aopDump()
10590
10591         * sdcc_vc.h: define PREFIX as "\\sdcc"
10592
10593 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10594         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10595
10596 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10597         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10598         - Rewrote the register banking algorithm.
10599         - Added pCode live-range analysis to registers (for now, only non-used and
10600         singly-used registers optimized away)
10601
10602         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10603
10604         * 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.
10605
10606 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10607         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10608
10609 2002-04-22  Michael Hope  <michaelh AT vroom>
10610
10611         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10612
10613         * configure.in (DD_COPT): Added include support required for gbdk.
10614
10615         * .version: Bumped version number just to increase it.
10616
10617         * src/SDCCmain.c: Added -nostdinc to the default options.
10618
10619 2002-04-15  Michael Hope  <michaelh AT vroom>
10620
10621         * device/lib/z80/printf.c (sprintf): Added.
10622
10623         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10624
10625         * src/z80/peeph.def: Added transpose redundent load rule.
10626
10627         * src/z80/main.c: Added force callee saves for jaune.
10628
10629         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10630
10631         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10632
10633 2002-03-28  Johan Knol  <johan AT balder>
10634
10635         * src/SDCCval.c: fixed bug #532436
10636
10637 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10638         * /src/port.h:
10639         Added "char *Processor" field to the port structure.
10640
10641         * /src/SDCCmain.c:
10642         Added -p option. Allows port dependent processor to be specified.
10643
10644         * all ports:
10645         Initialized the new field char *Processor field to NULL in all ports
10646
10647         * /src/pic/*:
10648         Compiler generated registers for interrupt context saving
10649         were not getting allocated.
10650
10651 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10652
10653         * /src/SDCCast.c:
10654         Fixed left shift. Will promote the left side of a left shift
10655         if a) left shifting more than size of operand or b) when assigned
10656         to something size > size of left side
10657
10658 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10659         * src/pic/*
10660         tons of changes. Register allocation has been
10661         rewritten. Added customization for the various PICs. Flow
10662         analysis is restructured. ...
10663
10664         * src/pic/device.h:
10665         Added
10666
10667         * src/pic/device.c:
10668         Added. device.c is a PIC port hack to accomodate variations
10669         in PIC devices.
10670
10671 2002-03-13  Michael Hope  <michaelh AT vroom>
10672
10673         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10674
10675 2002-03-04  johanknol  <johanknol AT manik>
10676
10677         * /src/SDCCval.c: fixed
10678
10679         const unsigned char arr[][2] = { { 0, 1 } };
10680         t18.c:1: error: Initializer element is not constant
10681
10682 2002-03-04  bela  <bela AT manik>
10683
10684         * /device/include/mcs51reg.h:
10685         ds89c420 register definition update
10686
10687 2002-03-03    <johan AT FRIJA>
10688
10689         * support/Util/SDCCerr.c: did something, but don't no why anymore
10690
10691         * support/regression/tests/bug-524691.c: made it a little less shy
10692
10693         * src/SDCCast.c (decorateType): fixed bug #524697
10694
10695         * src/SDCCast.c: made some lineno improvements
10696
10697         * src/SDCCval.c (getNelements): changed warning to error
10698
10699         * src/SDCCglue.c (printIvalArray): changed warning to error
10700
10701         * src/SDCCicode.c: fixed a warning for mingw
10702
10703         * src/SDCCast.c (decorateType): fixed the << promotion for ops
10704
10705         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
10706
10707 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
10708
10709         * src/ds390/peeph.def:
10710         Added some more peephole rules
10711
10712         * src/ds390/gen.c: Various fixes & enhancements
10713
10714         * src/SDCClrange.c, src/SDCClrange.h:
10715         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
10716
10717         * src/ds390/ralloc.c:
10718         various fixes & enhancements (ds390) specific
10719
10720         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
10721         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
10722         from rallocs.
10723
10724         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
10725
10726 2002-03-02    <johan AT FRIJA>
10727
10728         * src/SDCCast.c (decorateType): fixed bug #524708
10729
10730         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
10731
10732         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
10733
10734 2002-03-01  Michael Hope  <michaelh AT vroom>
10735
10736         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
10737
10738         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
10739
10740 2002-03-01    <johan AT FRIJA>
10741
10742         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
10743
10744         * src/SDCCast.c (decorateType): fixed bug #524209
10745
10746         * src/SDCCval.c (valNot): fixed bug #524195
10747
10748 2002-02-26    <johan AT balder>
10749
10750         * src/xa51/gen.c: fixed a warning
10751
10752         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
10753
10754         * src/SDCCast.c (decorateType): fixed bug #522534
10755
10756 2002-02-23    <johan AT balder>
10757
10758         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
10759
10760 2002-02-22    <johan AT balder>
10761
10762         * src/SDCCast.c: fixed bug #514865
10763
10764         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
10765
10766 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
10767
10768         * sdcc/src/SDCCloop.c:
10769         Previous fix was not good. basic blocks that have "break" or "return" are
10770         not really partof a loop , but live ranges used in these blocks should
10771         be live thru the entire loop, so set partOfLoop but don't add them to
10772         loop region
10773
10774 2002-02-21    <johan AT FRIJA>
10775
10776         * src/SDCCcse.c: fixed bug #514308
10777
10778 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
10779
10780         * src/SDCCloop.c:
10781         Fixed BUG #519583. If a conditional block ended in a return/break
10782         statement inside a loop, it was not being considered part of the loop.
10783
10784         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
10785
10786 2002-02-10  Karl Bongers <karl AT turbobit.com>
10787
10788         * debugger/*:
10789         Fixed up SDCDB debugger somewhat.  Updated debugger/README
10790         with lots of comments and notes.
10791
10792         * device/examples/test2.c:
10793         Fix bug, "red" variable not being initialized(compiler complained).
10794
10795         * device/examples/Makefile, examples/test3.c:
10796         Add Makefile in device/examples folder, compiles test3.c
10797         for use as a multiple module SDCDB test case.
10798
10799         * sim/ucsim/cmd.src/cmdset.cc:
10800         Took out debug printfs in ucsim "next" command.
10801
10802         * sim/ucsim/xa.src:
10803         Karl and Johan start ucsim XA support.  Most dissassembly working,
10804         about 75% emulation done(plenty of work remaining).
10805
10806         * sim/ucsim/z80.src:
10807         Add Z80 support to ucsim, add test-ucz80 regression test,
10808         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
10809         Notice z80 compiler fails on examples/test3.c/crc code.
10810
10811 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
10812
10813         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
10814         Added support for --parms-in-bank1
10815
10816         * src/ds390/peeph.def:
10817         added a few more peephole optimzations
10818
10819         * src/ds390/main.c:
10820         1) added __builtin_inp & __builtin_outp used to read in data of given length
10821            from a memory mapped port
10822         2) added __builtin_memcmp
10823         3) added __builtin_swapw swap bytes of a short
10824
10825         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
10826         1) handle multiple send & receives from register bank1
10827         2) ralloc can now allocate DPTR1 to some liveRanges
10828
10829         * src/SDCCsymt.c, src/SDCCsymt.h:
10830         changes to handle multiple sends & receives
10831
10832         * src/SDCCptropt.h:
10833         added some pointer arithmetic optimization
10834
10835         * src/SDCCptropt.c:
10836         added some pointer arithmetic optimizations but not stable yet so not
10837         called from anywhere (will get this working shortly)
10838
10839         * src/SDCCopt.c: fixed for multiple sends & receives
10840
10841         * src/SDCCmain.c:
10842         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
10843         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
10844            set preprocessor defines (depending on options)
10845
10846         * src/SDCCicode.c, src/SDCCicode.h:
10847         changes made to handle multiple sends & receives
10848
10849         * src/SDCCglobl.h:
10850         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
10851
10852         * src/SDCCcse.c, src/SDCCcse.h:
10853         added function findbackward def (to be used in upcoming optimization)
10854
10855         * src/SDCCcflow.c, src/SDCCcflow.h:
10856         added function returnAtEnd - to determine if a basic block terminates with
10857         a RETURN iCode
10858
10859         * src/SDCCast.c, src/SDCCast.h:
10860         added option parms-in-bank1
10861
10862         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
10863         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
10864         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
10865         adjusted for --parms-in-bank1 option
10866
10867         * device/include/string.h:
10868         donot redefine "reentrant" keyword
10869
10870         * device/include/ds80c390.h: Added some more SFRs
10871
10872 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
10873
10874         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
10875
10876 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
10877
10878         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
10879
10880 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
10881
10882         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
10883
10884 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
10885
10886         * Added --xram-movc option
10887
10888 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
10889
10890         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
10891
10892 2002-01-11  Johan Knol
10893
10894         * Added math lib of Jesus Calvino-Fraga
10895
10896 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
10897
10898         * src/SDCCmain.c (processFile): fix processing of ../../src.c
10899         * support/regression/Makefile: new target test-mcs51-stack-auto
10900         * support/regression/ports/mcs51-stack-auto/spec.mk: added
10901
10902 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
10903
10904         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
10905
10906 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
10907
10908         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
10909
10910 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
10911
10912         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
10913
10914         * src/SDCCglue.h: add definition for printIvalChar()
10915
10916 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
10917
10918         * src/SDCCast.c: fix #498138 by Johan
10919
10920         * src/SDCCglue.c: fix #498138 by Johan
10921
10922 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
10923
10924         * support/regression/Makefile: fix clean
10925
10926         * support/regression/ports/ds390/support.c: fix transmission of last character
10927
10928 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
10929
10930         * /sdcc/src/ds390/gen.c:
10931         a) improved computing address of stack variable
10932         b) took out some #if 0 code
10933         c) improved parmBytes adjustment
10934         d) improved genPlusIncr & genMinusIncr
10935         e) genCmp could generate bad code (when left assigned to DPTR)
10936         f) Fixed bug in hasInc
10937
10938         * /sdcc/src/ds390/ralloc.c:
10939         a) packRegsForSupport could mess up live information (Fixed)
10940         b) packRegsDPTRuse could be incorrect for left & right shift
10941
10942         * /sdcc/src/mcs51/ralloc.c:
10943         packRegsForSupport could mess up the live information (Fixed)
10944
10945         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
10946
10947         * /sdcc/src/SDCCast.c:
10948         can reverse a loop even if function call is present as long
10949         as the loop control variable is local & is not passed as parameter
10950
10951 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10952
10953         * /sdcc/ChangeLog: *** empty log message ***
10954
10955         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
10956         More builtin function additions for TININative
10957
10958         * /sdcc/src/ds390/ralloc.c:
10959         Had broken the regression testsuite
10960
10961         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
10962
10963         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
10964         Added funcattr hasStackParms will be set for reentrant functions when there
10965         are paramteres on the stack, this helps in minimizing frame pointer generation
10966         typeFromStr can handle function pointers now
10967
10968         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
10969         *** empty log message ***
10970
10971 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10972
10973         * /src/ds390/gen.c, /src/ds390/main.c:
10974         More builtin function additions for TININative
10975
10976         * /src/ds390/ralloc.c:
10977         Had broken the regression testsuite
10978
10979         * /src/SDCCast.c: Fixed a bug in dumptree
10980
10981         * /src/SDCCsymt.c, /src/SDCCsymt.h:
10982         Added funcattr hasStackParms will be set for reentrant functions when there
10983         are paramteres on the stack, this helps in minimizing frame pointer generation
10984         typeFromStr can handle function pointers now
10985
10986         * /doc/builtins.txt, /doc/TININative.txt:
10987         *** empty log message ***
10988
10989
10990 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
10991
10992         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
10993         ALPHA version for -mTININative
10994
10995         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
10996         updated to reflect changes in the port structure
10997
10998         * /src/port.h:
10999         added function do_assemble (similar to do_link) if non-null this function
11000         will be called to do assembly (-mTININative) requires a multi command
11001         assembly
11002         added function genAssemblerEnd will be called to generate assembler Epilogue
11003
11004         * /src/SDCCsymt.c:
11005         added _JavaNative to debug info printing
11006
11007         * /src/SDCCmain.c: added option --tini-libid
11008         added port->do_assemble function (-mTININative) has a multi command assemble
11009
11010         * /src/SDCCglue.c: Disabled "constExpr" check
11011         added port->genAssemblerEnd function
11012
11013         * /src/SDCCglobl.h: Added option --tini-libid value
11014
11015         * /src/SDCCast.h:
11016         tookout optimizeCompare from the header (has no external references)
11017
11018         * /src/SDCCast.c: made one more function "static"
11019
11020 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
11021
11022         * src/z80/mappings.i: Added z80asm support.
11023
11024         * src/z80/main.c: Added z80asm support on --asm=z80asm
11025
11026         * src/z80/gen.c: Fixed asm portability issues.
11027
11028         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
11029
11030         * src/SDCCglue.c (printExterns): Added global/extern split.
11031
11032 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
11033
11034         * support/regression/Makefile: added test for mcs51 model large
11035
11036         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
11037
11038         * support/regression/ports/gbz80/spec.mk: added -mgbz80
11039
11040 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
11041
11042         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
11043
11044 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
11045
11046         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
11047
11048         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
11049
11050 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
11051
11052         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
11053
11054         * support/regression/tests/simplefloat.c: Port to mcs51.
11055
11056 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
11057         * support/regression/tests/bug-485362.c: Added.
11058
11059         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
11060
11061         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
11062
11063         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
11064
11065         * src/z80/gen.c (aopDump): Added a dump function.
11066
11067 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
11068         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
11069
11070         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
11071
11072         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
11073
11074         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
11075
11076         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
11077
11078         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
11079
11080         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
11081
11082         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
11083
11084         * support/regression/ports/ds390/support.c: Use tinibios.
11085
11086         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
11087
11088 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
11089
11090         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
11091         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
11092
11093         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
11094
11095         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
11096
11097 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
11098
11099         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
11100
11101         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
11102         (packRegsForIYUse): Created and optimised.
11103
11104 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11105
11106         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
11107 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
11108
11109         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
11110
11111         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
11112
11113         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
11114
11115 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11116
11117         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
11118
11119         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
11120
11121 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11122
11123         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
11124
11125         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
11126
11127         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
11128
11129 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11130
11131         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
11132         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
11133         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
11134
11135         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
11136
11137         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
11138         (genNotFloat): Added.
11139         (genUminusFloat): Added.
11140
11141         * device/lib/z80/Makefile: Added floating pt stubs.
11142
11143         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11144
11145         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11146
11147         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11148
11149 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11150
11151         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11152
11153         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11154
11155         * sdcc/support/regression/Makefile: Add port ds390.
11156
11157         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11158
11159         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11160
11161         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11162
11163         * sdcc/support/regression/ports/ds390/support.c: Added.
11164
11165         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11166
11167         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11168
11169         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11170
11171 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11172
11173         * device/include/malloc.h: Added z80 and gbz80 support.
11174
11175         * device/lib/gbz80/heap.s: Added.
11176
11177         * device/lib/z80/heap.s: Added.
11178
11179         * device/lib/malloc.c: Added z80 and gbz80 support.
11180
11181         * support/regression/tests/malloc.c (testMalloc): Added.
11182
11183         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11184
11185         * support/regression/tests/bug-478094.c: Added.
11186
11187         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11188
11189 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11190
11191         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11192
11193         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11194
11195         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11196
11197         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11198
11199         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11200
11201 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11202
11203         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11204
11205 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11206
11207         * support/regression/tests/bug-477927.c: Added.
11208
11209         * src/z80/peeph.def: Added minor rules.
11210
11211         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11212
11213         * src/z80/peeph.def: Added jump optimisation modification.
11214
11215 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11216
11217         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11218
11219 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11220
11221         * support/regression/tests/funptrs.c: Added.
11222
11223 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11224
11225         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11226
11227 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11228
11229         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11230
11231         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11232
11233         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11234         (movLeft2ResultLong): Created.
11235
11236         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11237         (joinPushes): Added.  Joins two char pushes into a word push.
11238
11239 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11240
11241         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11242
11243         * support/makebin/Makefile (install): Added creation of dest dir.
11244
11245 2001-10-24 Karl Bongers <karl AT turbobit.com>
11246
11247         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11248
11249 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11250
11251         * src/z80/ralloc.c: Turned off faulty pack for one use.
11252
11253         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11254
11255         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11256
11257 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11258
11259         * support/regression/Makefile: Improved clean
11260
11261         * support/regression/ports/gbz80/spec.mk: Added clean
11262
11263         * support/regression/ports/host/spec.mk: Added clean
11264
11265         * support/regression/ports/z80/spec.mk: Added clean
11266
11267         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11268
11269         * support/regression/ports/mcs51/timeout.c: little improvements
11270
11271 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11272
11273         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11274
11275         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11276
11277         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11278
11279 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11280
11281         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11282
11283         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11284
11285 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11286         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11287
11288         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11289
11290         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11291
11292         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11293
11294         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11295
11296         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11297
11298         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11299
11300         * support/regression/tests/longor.c: Added.
11301
11302 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11303
11304         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11305
11306         * as/mcs51/aslink.h: define PATH_MAX
11307
11308         * as/mcs51/asm.h: define PATH_MAX
11309
11310         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11311
11312         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11313
11314         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11315
11316         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11317
11318         * src/SDCCglobl.h: define PATH_MAX
11319
11320         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11321
11322         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11323
11324 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11325
11326         * src/z80/gen.c (gencjneshort): Fixed
11327
11328         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11329
11330 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11331
11332         * support/regression/tests/bug-469671.c: Added.
11333
11334         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11335
11336 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11337
11338         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11339
11340         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11341
11342 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11343
11344         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11345
11346         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11347
11348         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11349
11350         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11351
11352         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11353
11354         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11355
11356         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11357
11358 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11359
11360         * 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.
11361
11362         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11363
11364         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11365
11366 2001-10-07    <johan AT FRIJA>
11367
11368         * device/lib/gets.c (gets): fixed the return value.
11369
11370 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11371         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11372
11373         * 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.
11374
11375         * 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.
11376
11377         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11378
11379         * src/pic/gen.c: Removed Safe_strdup.
11380
11381         * configure.in: Added option to enable libgc support.
11382
11383         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11384         (bitVectUnion): Optimised.
11385         (bitVectIntersect): Optimised.
11386         (bitVectBitsInCommon): Optimised.
11387         (bitVectCplAnd): Optimised.
11388
11389         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11390
11391 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11392
11393         * src/SDCCmain.c: distinguish between assembler debug and plain options
11394
11395         * src/avr/main.c:   remove standard assembler options
11396
11397         * src/ds390/main.c: remove standard assembler options
11398
11399         * src/mcs51/main.c: remove standard assembler options
11400
11401         * src/port.h: removed "PENDING" comment
11402
11403 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11404
11405         * src/device/lib/_mulint.c  : new, with assember functions
11406
11407         * src/device/lib/_mullong.c : new, with assember functions
11408
11409         * src/device/lib/_divuint.c : with assember functions
11410
11411         * src/device/lib/_divsint.c : with assember functions
11412
11413         * src/device/lib/_divulong.c: with assember functions
11414
11415         * src/device/lib/_divslong.c: with assember functions
11416
11417         * src/device/lib/_moduint.c : with assember functions
11418
11419         * src/device/lib/_modsint.c : with assember functions
11420
11421         * src/device/lib/_modulong.c: with assember functions
11422
11423         * src/device/lib/_modslong.c: with assember functions
11424
11425         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11426
11427         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11428
11429         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11430                                       replaced _mululong.c and _mulslong.c by _mullong.c
11431
11432 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11433
11434         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11435
11436 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11437
11438         * src/SDCCglue.c: test, if win32api is available for MINGW
11439
11440 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11441
11442         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11443         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11444         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11445         * support/regression/ports/host/spec.mk: removed GENERIC
11446         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11447         * support/regression/ports/z80/spec.mk: removed GENERIC
11448
11449 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11450
11451         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11452
11453         * support/regression/tests/bug-467035.c: Created.
11454
11455 2001-10-01    <johan AT FRIJA>
11456
11457         * src/SDCC.y: fixed bug #466586 part 1
11458
11459 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11460
11461         * SDCCicode.c: z80 has no generic pointers
11462         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11463
11464 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11465
11466         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11467
11468 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11469
11470         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11471
11472         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11473
11474 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11475
11476         * configure.in: Fixed up so that ucsim is only configured once.
11477
11478         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11479
11480         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11481         (getPathDifference): As above.
11482
11483         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11484
11485         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11486
11487 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11488         * .version: Updated to 2.3.1
11489
11490         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11491         Added copyright header.
11492
11493         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11494         (assemble): Added support for macro based assembler commands.
11495         (linkEdit): Added support for macro based linker commands.
11496         (preProcess): Changed the pre-processor to use macros.
11497         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11498         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11499
11500         * device/lib/z80/crt0.s: Added module name for debugging.
11501
11502 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11503
11504         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11505
11506         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11507
11508         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11509
11510         * src/Makefile.in: Added SDCCmacro and SDCCutil
11511
11512 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11513
11514         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11515
11516 2001-09-16    <johan AT FRIJA>
11517
11518         * 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.
11519
11520 2001-09-15    <johan AT FRIJA>
11521
11522         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11523         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11524
11525 2001-09-11    <johan AT FRIJA>
11526
11527         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11528
11529 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11530
11531         * support/regression/tests/bug-460444.c: Added test case.
11532
11533         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11534         (genCast): Added justification for all of the asserts.
11535
11536 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11537
11538         * support/regression/support.c: _xdata replaced by xdata
11539
11540         * support/regression/spec.mk: removed _generic
11541
11542 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11543
11544         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11545
11546         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11547         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11548
11549         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11550
11551         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11552
11553         * support/regression/tests/bug-460010.c: Added test case.
11554
11555         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11556
11557 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11558
11559         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11560
11561         * support/regression/testfwk.c: removed workaround for bug #436344
11562
11563         * support/regression/tests/bp.c: use less memory with mcs51
11564
11565         * support/regression/tests/bug-441448.c: use less memory
11566
11567         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11568
11569         * support/regression/collate-results.py: typo
11570
11571 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11572
11573         * support/regression/tests/fetchoverlap.c: Added new test case.
11574
11575         * support/regression/tests/bp.c: Added new test case.
11576
11577         * support/regression/tests/bug-448984.c: Added new test case.
11578
11579         * support/regression/tests/pow2shifts.c: Added new test case.
11580
11581         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11582         (genlshTwo): Fixed right shift for count > 8.
11583
11584         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11585
11586 2001-09-08    <johan AT FRIJA>
11587
11588         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11589
11590 2001-09-07    <johan AT FRIJA>
11591
11592         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11593
11594         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11595
11596 2001-09-06    <johan AT FRIJA>
11597
11598         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11599         * bernhard noted me at this: "() equals to (void)" (1.38)
11600
11601 2001-09-05    <johan AT FRIJA>
11602
11603         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11604
11605 2001-09-04    <johan AT FRIJA>
11606
11607         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11608
11609
11610 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11611
11612         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11613
11614 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11615
11616         * link/z80/aslink.h: Fixed path for PATH_MAX
11617
11618 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11619
11620         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11621
11622         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11623
11624         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11625
11626         * 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.
11627
11628 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11629
11630         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11631         (genCmp): Fixed up genCmp for the GB with longs.
11632
11633         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11634
11635         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11636
11637         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11638
11639         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11640
11641 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11642
11643         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11644
11645 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11646
11647         * 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.
11648
11649         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11650
11651 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11652
11653         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11654
11655         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11656
11657 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11658
11659   * sim/ucsim/configure:    little improvement of Cygwin-detection
11660   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11661   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11662   * support/regression/tests/bug-221100.c: small changes for mcs51
11663   * support/regression/tests/bug-221168.c: small changes for mcs51
11664   * support/regression/tests/bug-227710.c: small changes for mcs51
11665   * support/regression/tests/staticinit.c: small changes for mcs51
11666   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11667   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11668   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11669
11670 $Revision$