* doc/knownbugs.html: removed [ 1519095 ] from the list
[fw/sdcc] / ChangeLog
1 2006-07-25 Borut Razem <borut.razem AT siol.net>
2
3         * configure.in, configure, sdccconf_in.h: fixed bug
4           [ 1519095 ] regression test onebyte.c fails on ppc64 host
5         * doc/knownbugs.html: removed [ 1519095 ] from the list
6
7 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
8
9         * doc/knownbugs.html: added, contains list of known bugs at release
10         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
11
12 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
13
14         * device/include/mcs51/compiler.h: added SFRX for xdata based special
15           function registers and corrected defaults with additional warning
16         * device/lib/malloc.c: cosmetic changes
17         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
18         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
19           (fillGaps): and used it
20
21 2006-07-20 Raphael Neider <rneider AT web.de>
22
23         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
24           output unless SDCCPICDEBUG is set
25         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
26           output if SILENT is set
27
28 2006-07-11 Borut Razem <borut.razem AT siol.net>
29
30         * doc/README.txt: updated
31
32 2006-07-10 Borut Razem <borut.razem AT siol.net>
33
34         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
35           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
36           in WIN32 installation
37         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
38           release candidate 1
39
40 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
41
42         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
43         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
44
45 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
46
47         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
48
49 2006-07-06 Borut Razem <borut.razem AT siol.net>
50
51         * support/regression/tests/bitfields.c:
52           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
53         * support/regression/tests/constantRange.c:
54           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
55
56 2006-07-04 Borut Razem <borut.razem AT siol.net>
57
58         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
59           src/port.mk,
60           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
61           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
62           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
63           reverted changes from 2006-07-03
64         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
65         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
66           added CPPFLAGS, used by the host port
67
68 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
69
70         * support/regression/valdiag/tests/switch.c,
71         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
72         * support/regression/tests/libmullong.c: fixed for host
73         * support/regression/ports/host/spec.mk: disable all warnings for host,
74         SDCC runs with --less-pedantic too
75
76 2006-07-03 Borut Razem <borut.razem AT siol.net>
77
78         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
79           defined CPPFLAGS
80         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
81         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
82           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
83           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
84           include ../port.mk
85         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
86           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
87           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
88           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
89
90 2006-07-02 Raphael Neider <rneider AT web.de>
91
92         * src/pic16/devices.inc,
93         * device/include/pic16/pic18fregs.h,
94         * device/include/pic16/pic18f4550.h,
95         * device/lib/pic16/pics.all,
96         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
97
98 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
99
100         * as/hc08/lkaomf51.c (OutputName),
101         * as/mcs51/lkaomf51.c (OutputName),
102         * as/z80/asmain.c (asmbl),
103         * src/ds390/main.c (asmLineNodeFromLineNode),
104         * src/hc08/ralloc.c (hc08_assignRegisters),
105         * src/mcs51/main.c (asmLineNodeFromLineNode),
106         * src/xa51/ralloc.c (checkRegMask),
107         * src/xa51/gen.c (emitcode),
108         * src/z80/gen.c (_emit2),
109         * src/SDCCast.c (searchLitOp),
110         * src/SDCCglobl.h,
111         * support/packihx/packihx.c,
112         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
113         * src/ds390/gen.c (aopPutUsesAcc),
114         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
115         * support/regression/tests/libmullong.c (mullong_wrapper),
116         * src/SDCCsymt.c (powof2),
117         * src/SDCCast.c,
118         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
119         * src/SDCCsymt.h: added TYPE_TARGET_*
120         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
121         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
122         SDCCast because 1) header problems 2) this is the right place
123         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
124         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
125         prototype
126
127 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
128
129         * src/SDCCicode.h: removed buggy semicolon in unused macro
130         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
131         search for previous definiton of auto symbols too,
132         (findPrevUse): fixed logic of emitWarnings
133
134 2006-06-26 Raphael Neider <rneider AT web.de>
135
136         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
137           PCLATH and PCLATU on interrupts, potentially fixes #1505141
138
139 2006-06-25 Raphael Neider <rneider AT web.de>
140
141         * device/lib/pic/libm: NEW, added math library functions
142         * device/lib/pic/libsdcc: NEW; added float support functions
143         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
144         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
145           NEW, added math related headers
146         * device/include/asm/pic/features.h: NEW
147         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
148           (popGet): allow larger offsets for AOP_PCODE,
149           (genDataPointerSet): handle literals explicitly, more debug output,
150           (genAssign): fixed for float using aopLiteral ;-)
151         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
152           GOTO initialisation routine
153         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
154           flag on registers, fixes #1469043 (local variables do not work)
155         * src/pic/main.c (_pic14_do_link),
156         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
157           available
158
159 2006-06-25 Borut Razem <borut.razem AT siol.net>
160
161         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
162           characters printed (not including the trailing '\0' used to end
163           output to strings). Problem detected in regression test bug-927659.c.
164           NOTE: printf() family functions should return int instead
165           unsigned int!
166         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
167           specifier are printed as themselves
168         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
169           support flags, width and precision specifiers
170
171 2006-06-24 Borut Razem <borut.razem AT siol.net>
172
173         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
174           to the list of sdcc tagrets not supporting bit type
175         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
176           testfor pic16 due to bug:
177           [ 1511794 ] pic16: regression test bug-895992.c fails
178
179 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
180
181         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
182         * src/SDCCglue.c (initPointer), fixed bug 1496419
183         * support/regression/tests/bug1496419.c: new, added
184
185 2006-06-22 Borut Razem <borut.razem AT siol.net>
186
187         * support/regression/ports/pic16/support.c: use gpsim usart module from
188           libgpsim_modules library
189
190 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
191
192         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
193         IP0H to IPH0.
194
195 2006-06-19 Raphael Neider <rneider AT web.de>
196
197         * src/pic/glue.h,src/pic16/glue.h: added prototypes
198         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
199           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
200           (pic14printExterns,pic14printPublics,pic16printPublics,
201           pic16_printExterns): use new functions to emit symbols
202           (picglue,pic16glue): emit publics before emitting externs
203         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
204           locally defined functions to avoid bug #1443651
205         * support/regression/tests/bug-716242.c: removed pic16 workaround
206         * support/regression/ports/pic16/spec.mk: ignore errors during build
207
208 2006-06-19 Raphael Neider <rneider AT web.de>
209
210         * src/pic/glue.h: added pic14aopLiteral prototype
211         * src/pic/glue.c (pic14aopLiteral): return unsigned int
212         * src/pic/gen.c: removed stdint.h dependency
213           (aopGet): use Safe_strdup()
214           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
215           (genDataPointerSet): use pic14aopLiteral()
216         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
217           for pic16; thanks to Bernhard and Maarten
218
219 2006-06-18 Borut Razem <borut.razem AT siol.net>
220
221         * support/regression/tests/structflexarray.c: flexible array members
222           not supported by gcc < 3
223         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
224           GUI tool by default
225         * src/pic/gen.c: don't include [p]strdin.h on solaris
226         * support/Util/pstdint.h: addad svn attributes
227         * support/regression/tests/constantRange.c,
228           support/regression/tests/rotate.c: include inttypes.h instead
229           stdint.h on solaris, addad svn attributes
230
231 2006-06-18 Raphael Neider <rneider AT web.de>
232
233         * src/SDCCsymt.c (initCSupport): change return type of divschar to
234           int for PIC16
235         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
236           (pic16_genMinusBits): simplified sign-extension
237           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
238             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
239             adjusted to correctly handle mixed-signed operands, disabled
240             now unused multiplciation routines
241         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
242           (assignResultValue): added argument denoting the size of the result
243             as returned by the function (fixes upcasts in assigning from
244             function calls: char foo(); int i = foo();)
245           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
246             function result to assignResultValue
247           (genMult): disabled inlined multiplication code
248           (genDiv): augmented to also handle the modulus operator, fixed to
249             handle mixed-signed operands correctly
250           (genMod): simply call genDiv, disabled unused code
251           (genAssign): fixed missing (sign-)extension on result
252         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
253             valid char operands, allow signed operands for native code, added
254             division and modulo operator handling
255         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
256
257         As a consequence, onebyte.c (if split into two files) and muldiv.c
258         pass regression tests.
259
260 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
261
262         * doc/Makefile.in: two runs of makeindex seem needed to get
263         correct page references in the index of sdccman.pdf
264         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
265
266 2006-06-17 Borut Razem <borut.razem AT siol.net>
267
268         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
269
270 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
271
272         * doc/sdccman.lyx: updated, added (porting source code, debugging),
273         mentioned ec2drv and paulmon
274
275 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
276
277         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
278           consecutive abs areas
279           (find_empty_space, allocate_space): added map to handle codemap or
280            xdatamap,
281           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
282            absolute idata and xdata
283         * as/mcs51/lkmem.c (summary2): updated legend
284
285 2006-06-16 Raphael Neider <rneider AT web.de>
286
287         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
288
289 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
290
291         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
292           1208515
293         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
294
295 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
296
297         * src/port.h (struct PORT): added field gp_tags, to hold the tag
298         value of generic pointers,
299         * src/avr/main.c,
300           src/ds390/main.c,
301           src/hc08/main.c,
302           src/izt/i186.c,
303           src/izt/tlcs900h.c,
304           src/mcs51/main.c,
305           src/pic/main.c,
306           src/pic16/main.c,
307           src/xa51/main.c,
308           src/z80/main.c: PORT structure, added elements for gp_tags field,
309         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
310         fields in the PORT structure of each port,
311         * src/SDCCast.c (decorateType): allow processing of generic pointers
312         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
313         S_FIXED symbols
314
315 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
316
317         * link/z80/lkgb.c,
318         * link/z80/lkgg.c,
319         * src/pic16/gen.c,
320         * src/pic16/main.c,
321         * src/pic16/pcode.c,
322         * src/pic/main.c,
323         * src/pic/pcoderegs.c,
324         * src/SDCCicode.c,
325         * src/SDCCmain.c,
326         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
327           bug 1504689 on minGW
328
329 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
330
331         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
332
333 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
334
335         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
336
337 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
338
339         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
340           for optimization
341
342 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
343
344         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
345         to a char variable. Fixed bug #1504211
346         * device/include/pic16/adc.h,
347         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
348         and fixed bug #1364390
349
350 2006-06-10 Borut Razem <borut.razem AT siol.net>
351
352         * CVSROOT: removed the CVS left-over
353
354 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
355
356         * as/hc08/asmain.c (asexit),
357         * as/hc08/lkmain.c (lkexit),
358         * as/mcs51/asmain.c (asexit),
359         * as/mcs51/lkmain.c (lkexit),
360         * src/SDCCglue.c (DEFSETFUNC),
361         * src/SDCCmain.c (linkEdit, assemble),
362         * support/librarian/sdcclib.c (AddRel),
363           replaced unlink() by standard C remove()
364         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
365         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
366           gatherImplicitVariables): new, added to fix bug 608752,
367           (createFunction): added gatherImplicitVariables()
368         * src/SDCCast.h: added createRMW prototype
369         * src/SDCCsymt.h (struct symbol): added infertype
370         * support/regression/tests/bug608752.c: new, added
371
372 2006-06-10 Raphael Neider <rneider AT web.de>
373
374         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
375           multibyte dummy reads (fixes #1503234)
376
377 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
378
379         * device/include/mcs51/compiler.h: new, added header file to enable
380           creating common sfr definition header files for different compilers
381
382 2006-06-05 Raphael Neider <rneider AT web.de>
383
384         * src/pic16/{pcode.h,genarith.c}:
385           introduced pCodeOp combining any two pCodeOps (previously only
386           two register operands could be combined), removed pcop2 from
387           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
388         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
389         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
390           rewritten to use new PO_TWO_OPS
391         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
392         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
393           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
394           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
395           (pic16_get_op): embraced return arg to allow #define return(x),
396             added new case for combined opcodes
397           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
398           (pic16_pCode2str,pic16_getRegFrompCodeOp,
399            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
400
401 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
402
403         * src/SDCCval.c (checkConstantRange): added
404         * src/SDCCval.h: added checkConstantRange
405         * support/Util/SDCCerr.c,
406         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
407         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
408         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
409         * src/SDCCast.c (decorateType): added checkConstantRange,
410         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
411         can be emitted with the correct always true/false warning,
412         added optimization for double '!';
413         result of decorateType() must be assigned back to the tree, because
414         decorateType() can change the tree
415         * src/SDCCicode.c (geniCodeLogic),
416         (geniCodeAssign): replaced new checkConstantRange, added warnings,
417         (checkConstantRange): removed, it was only a fragment which never
418         emitted a warning
419         * src/SDCCsymt.c (computeType): fixed promotion for
420         "-1 < (unsigned bit) b"
421         * src/pic/ralloc.c (packRegsForAssign),
422         * src/pic16/ralloc.c (packRegsForAssign),
423         * src/hc08/ralloc.c (packRegsForAssign),
424         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
425         from mcs51
426         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
427         * support/regression/tests/constantRange.c: added
428         * support/valdiag/tests/constantRange.c: added
429         * support/valdiag/valdiag.py: added -DPORT_HOST=1
430
431 2006-06-02 Borut Razem <borut.razem AT siol.net>
432
433         * support/regression/ports/pic16/support.c: increase stack size
434           to 255 bytes
435         * support/regression/Makefile.in: sort tests by name so that the
436           resutlts can be compared on different machines / platforms
437
438 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
439
440         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
441         * src/ds390/gen.c (emitLabel): new, added,
442           (genDjnz): fixed stack overflow bug,
443           (throughout): cosmetic changes to sync with mcs51/gen.c,
444           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
445         * src/mcs51/gen.c (genEndFunction): small optimization,
446           (throughout): cosmetic changes to sync with ds390/gen.c
447
448 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
449
450         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
451           (_print_format): fixed printing pointers
452         * src/mcs51/gen.c (emitLabel, movb): new, added,
453           (genAssign): small optimization,
454           (genDjnz): fixed stack overflow bug,
455           (throughout): replaced sprintf with SNPRINTF,
456           replaced mcs51_regWithIdx with REG_WITH_INDEX,
457           replaced emitcode("mov", "b,...") with MOVB(...),
458           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
459           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
460         * src/mcs51/peeph.def: added rules 140 and 264
461         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
462           so they may get optimized into registers
463
464 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
465
466         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
467           immediately when encountered,
468           (printUsage): always use stderr even on windows
469
470 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
471
472         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
473         (processParms): fixed bug #1247551
474         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
475         parseCmdLine, main): print '--version' to stdout,
476         print 'help' to stdout if --help is given,
477         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
478         arguments are given; fixed --help
479
480 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
481
482         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
483         * support/regression/tests/bug-1493710.c: added
484
485 2006-05-27 Borut Razem <borut.razem AT siol.net>
486
487         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
488           static instead auto
489         * support/regression/ports/pic16/support.c: increase stack size
490           from default 64 bytes to 128 bytes
491         * support/regression/tests/staticinit.c,
492           support/regression/tests/float.c: regression tests fully enabled
493           for pic16 port by putting the initialized data arrays into the code
494           section
495         * support/regression/ports/pic16/spec.mk: don't link default libraries.
496           This was changed by mistake in the previous version.
497
498 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
499
500         * src/pic16/gen.c (genFunction, genEndFunction): some
501         beautifications, fixed bug with falsely restoring FSR2 in large
502         stack model, thanks to Beau E. Cox for reporting the bug
503
504 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
505
506         * debugger/mcs51/break.c,
507         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
508           use %p to print pointers, made address variables unsigned
509         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
510         * debugger/mcs51/symtab.c (parseSymbol): must return something
511         * src/mcs51/gen.c (aopForSym): small optimization,
512            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
513           (freeAsmop): added missing break,
514           (aopPut): removed parameter bvolatile, determine it inside the function,
515           (saveRegisters, unsaveRegisters): small optimization,
516           (genIpush): removed pointless check,
517           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
518           replaced sprintf with SNPRINTF,
519           replaced strcpy with strncpyz,
520           updated aopPut calls,
521           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
522         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
523
524 2006-05-24 Borut Razem <borut.razem AT siol.net>
525
526         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
527           modification of test for the pic16 port, put the array to the code
528           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
529
530 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
531
532         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
533         * support/Util/pstdint.h: added
534
535 2006-05-22 Borut Razem <borut.razem AT siol.net>
536
537         * src/regression/Makefile: removed bool2.c test, added -q linker option
538         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
539           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
540           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
541           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
542           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
543           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
544           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
545           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
546           define SUPPORT_BIT_TYPES 0, removed unused bit variables
547
548 2006-05-22 Raphael Neider <rneider AT web.de>
549
550         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
551           bug #1492360 (problematic due to generic pointers, see code)
552
553 2006-05-22 Borut Razem <borut.razem AT siol.net>
554
555         * support/regression/ports/pic16/specs.mk: removed stack size linker
556           directive
557         * support/regression/tests/array.c,
558           support/regression/tests/bitopcse.c,
559           support/regression/tests/bug-908454.c,
560           support/regression/tests/malloc.c: modified for pic16 regression test
561         * support/regression/tests/bitfields.c:
562           pic16 - excluded bitfileds of size > 8
563         * support/regression/tests/bp.c: pic16 - reduced data size
564         * support/regression/tests/bug-221100.c: pic16 - reduced data size
565         * support/regression/tests/bug-460010.c:
566           pic16 - used the absolute address the fits in memory
567         * support/regression/tests/bug-716242.c:
568           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
569         * support/regression/tests/float.c:
570           pic16 - excluded - data size too big
571         * support/regression/tests/onebyte.c:
572           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
573         * support/regression/tests/shifts.c:
574           pic16 - function names probably have to differ in first X characters
575           (gpasm limitation?)
576         * support/regression/tests/staticinit.c:
577           pic16 - excluded some tests due error: no target memory available for
578           section ".idata"
579
580 2006-05-22 Borut Razem <borut.razem AT siol.net>
581
582         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
583           second try. Thanks Stas Sergeev once more.
584
585 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
586
587         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
588           (genLeftShift, genRightShift): fixed bug 1491627
589         * src/hc08/peeph.def (rules 7, 8.x): added
590         * support/regression/tests/shifts.c (ShiftLeftByParam,
591           ShiftRightByParam, testShiftByParam): added to test variable shifting
592
593 2006-05-20 Raphael Neider <rneider AT web.de>
594
595         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
596         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
597           (allocReg): add only new registers to dynAllocRegs,
598           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
599             #1489055, #1445850, and probably #1483693
600
601 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
602
603         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
604         bug in for-loop that didn't emit the last of CONFIG and ID registers
605
606 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
607
608         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
609           with offset
610         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
611           1489016, 1434401 and 1490124
612         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
613           1489016, 1434401 and 1490124
614
615 2006-05-17 Borut Razem <borut.razem AT siol.net>
616
617         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
618           thanks Stas Sergeev
619
620 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
621
622         * device/include/mcs51/P89c51RD2.h,
623         * device/include/mcs51/P89LPC901.h,
624         * device/include/mcs51/P89LPC922.h,
625         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
626
627 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
628
629         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
630         to fix missing stack pragma in compiled binary object file,
631
632 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
633
634         * support/packihx/configure.in,
635         * support/packihx/configure: removed warning, autoconf >= 2.5x can
636         determine sizeof basic types even while cross compiling
637
638 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
639
640         * src/avr/gen.c (aopop),
641         * src/ds390/gen.c (aopOp),
642         * src/hc08/gen.c (aopOp),
643         * src/mcs51/gen.c (aopop),
644         * src/pic16/gen.c (pic16_aopOp),
645         * src/pic/gen.c (aopOp),
646         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
647         if size of operand is smaller than spill location
648
649 2006-05-12 Borut Razem <borut.razem AT siol.net>
650
651         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
652           have to have CR/LF line endings even if they are checked out on *nix
653           or on WIN32 in cygwin binmode
654
655 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
656
657         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
658         * device/include/ds80c390.h: added sfr16 definitions
659         * src/ds390/gen.c,
660         * src/ds390/gen.h,
661         * src/ds390/main.c,
662         * src/ds390/ralloc.c,
663         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
664           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
665           bit returning functions
666         * support/regression/tests/sfr16.c: enabled test on ds390
667
668 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
669
670         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
671         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
672
673 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
674
675         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
676         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
677           (cl_address_space constructor): removed expensive initialization,
678           (cl_address_space::get_cell): extended for late initialization,
679           (cl_address_space::*): use late initialization,
680           (cl_address_decoder::activate): removed expensive initialization,
681           This reduced regression test running time by 25%
682
683 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
684
685         * packihx/,
686         * configure.in,
687         * configure,
688         * sdcc.dsw,
689         * Makefile.bcc,
690         * Makefile.in,
691         * support/packihx/Makefile.in,
692         * support/packihx/clean.mk,
693         * support/packihx/Makefile.bcc,
694         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
695
696 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
697
698         * src/SDCCval.c (valNot): fix for regression test failure
699           of not.c on big endian hosts
700
701 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
702
703         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
704
705 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
706
707         * device/lib/mcs51/Makefile.in: changed string comparison operator
708           to = for POSIX compliance; == is bash extension
709
710 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
711
712         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
713           kosmonaut_pirx
714
715 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
716
717         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
718         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
719         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
720         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
721         bug report #1478657,
722
723 2006-05-05 Borut Razem <borut.razem AT siol.net>
724
725         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
726           making the html
727
728 2006-05-02 Borut Razem <borut.razem AT siol.net>
729
730         * doc/Makefile.in: removed *.ind dependency since there is no rule to
731           create *.ind, which made make to fail if invoked with -j 2
732
733 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
734
735         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
736           Hubert Sack for patch 1479782
737
738 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
739
740         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
741
742 2006-05-01 Raphael Neider <rneider AT web.de>
743
744         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
745           (create_pic): store only prefix-free device name,
746           (init_pic): check for device names with "16" prefix,
747           (list_valid_pics),
748         * src/pic/device.h (struct PIC_device),
749         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
750             stored device name,
751         * device/include/pic/pic12f{635,675,629,683}.h,
752         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
753         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
754         * device/include/pic/pic16f505.h,
755         * device/lib/pic/libdev/pic16f505.c: removed
756         * device/include/pic/pic14devices.txt: added support for pic12f
757             devices, removed unsupported non 16-bit devices
758             [above changes provided by patch from Zik Saleeba]
759         * src/pic/*, src/pic16/*, device/include/pic16/*,
760           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
761
762 2006-05-01 Borut Razem <borut.razem AT siol.net>
763
764         * configure.in, configure, doc/Makefile.in:
765           sync with nightly build makefile - latex, dvipdf and dvips
766           not needed any more
767
768 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
769
770         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
771         in the library source
772
773 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
774
775         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
776
777 2006-04-28 Raphael Neider <rneider AT web.de>
778
779         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
780         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
781           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
782         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
783
784 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
785
786         * device/lib/pic/libdev/Makefile.in,
787         * device/lib/hc08/Makefile.in,
788         * device/lib/gbz80/Makefile.in,
789         * device/lib/z80/Makefile.in,
790         * device/lib/ds390/Makefile.in,
791         * device/lib/ds400/Makefile.in: added srcdir to include search path,
792         thanks to Borut for the bug report
793         * configure.in,
794         * configure: always create doc/Makefile independent from --enable-doc
795         * Makefile.in: always install from directory doc independent from
796         --enable-doc
797         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
798         removed
799         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
800         * doc/Makefile.in: install *.txt if present
801         * device/include/Makefile.in (install): added installation of pic/*.inc
802         and pic/*.txt files again, they were erroneously removed
803
804 2006-04-28 Raphael Neider <rneider AT web.de>
805
806         * src/pic/{gen.c,main.h,pcode.c},
807         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
808             concerning signedness with casts
809
810 2006-04-28 Raphael Neider <rneider AT web.de>
811
812         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
813             definition of an interrupt handler,
814         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
815             interrupt handler stuff from picglue() to separate routine,
816           (picglue): enabled definition of intr handlers in files w/o main()
817
818 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
819
820         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
821           compilation with MSVC 2005 Express Edition (VC8)
822
823 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
824
825         * device/lib/Makefile: fixed build of gbz80 lib
826
827 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
828
829         * support/regression/tests/bug-460010.c,
830         * support/regression/tests/bug-524691.c,
831         * support/regression/tests/bug-716242.c: removed conditional defines
832           that are already in testfwk.h
833
834 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
835
836         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
837           (AccAXRsh1): added, shift right by 1,
838           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
839            AccAXLrl1
840         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
841
842 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
843
844         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
845         remove cast to same type
846         * src/SDCCast.c (decorateType): fix for RFE 1475742,
847         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
848         * as/z80/Makefile,
849         * link/z80/Makefile: removed, they have moved to
850         Makefile.in files
851         * configure,
852         * configure.in: replaced duplicate message about ucsim by missing sdcpp
853         * install-sh: fix bug #1204398 by setting umask 0022
854         * device/lib/Makefile: separate build of z80 and gbz80 lib
855
856 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
857
858         Enabled VPATH feature: changed nearly all Makefiles (149 files).
859         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
860
861         One basic decision: e.g. src/clean.mk includes further files. In order
862         to make this work there are two solutions:
863         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
864           run configure on them. This way they can use
865           'include $(srcdir)/port-clean.mk'
866         - always include clean.mk by the Makefile at the same level. To avoid
867           that `make clean` tries to include and build Makefile.dep the
868           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
869           implemented, because now even `make uninstall` doesn't create
870           Makefile.in. clean.mk could be eliminated by pasting it in
871           Makefile.in.
872
873         * debugger/mcs51/Makefile.in: build own objects from library sources
874         (SLIB, SDCC) in current directory
875
876         * configure, configure.in: renamed --disable-device-lib-build in
877         --disable-device-lib; added --enable-doc, the required tools are
878         searched by configure; added result message; the toolchain for the
879         belonging ports are now only built, if the port is enabled.
880
881         * support/regression/*: all output is written in directory gen, because
882         the fwk and ports directories don't livet in the build tree using vpath
883
884         * doc/sdccman.lyx: renamed --disable-device-lib-build to
885         --disable-device-lib, added --enable-doc, added section VPATH
886
887         * sim/ucsim/configure.in,
888         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
889         z80 are enabled by default
890
891 2006-04-24 Raphael Neider <rneider AT web.de>
892
893         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
894             to config word, "pic14_"-prefixed some extern functions
895           (pic14_emitConfigWord): emit __config directive(s) if assignment to
896             config word has been found
897         * src/pic/device.h: added prototypes
898         * src/pic/pcode.c: added "pic14_"-prefix where needed
899         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
900             fixup
901         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
902             words,
903           (pic14emitRegularMap): ignore config words,
904           (pic14createInterruptVect): moved generating __config directives away
905           (picglue): have __config directives emitted
906
907 2006-04-24 Borut Razem <borut.razem AT siol.net>
908
909         * doc/Makefile: sync with nightly build makefile
910
911 2006-04-24 Raphael Neider <rneider AT web.de>
912
913         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
914             registers that have not been assigned proper liveranges,
915             fixes #1469504 and #1474602,
916           (pCodeRegOptimizeRegUsage): fixed typo in comment
917
918 2006-04-24 Borut Razem <borut.razem AT siol.net>
919
920         * device/examples/main8051.c: deleted - it was removed from CVS
921           24.mar.2000 and after that modified 18.feb.2001, so it reappered
922           after the transition to Subversion
923         * src/SDCCalloc.h: deleted - it was removed  from CVS
924           3.feb.2001 and after that modified 18.feb.2001, so it reappered
925           after the transition to Subversion
926         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
927           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
928           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
929           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
930
931 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
932
933         * as/asx8051.dsp: added mcs51/strcmpi.h
934         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
935         * as/hc08/aslink.h: updated lnksect prototype
936         * as/hc08/asm.h,
937         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
938         * as/hc08/asmain.c,
939         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
940           (newdot): handle A_ABS
941         * as/hc08/asout.c,
942         * as/mcs51/asout.c (outarea): output address
943         * as/hc08/lkaomf51.c,
944         * as/mcs51/lkaomf51.c: disabled unused array UsageType
945         * as/hc08/m08pst.c,
946         * as/mcs51/i51pst.c,
947         * as/z80/z80pst.c: "ABS" is not A_OVR
948         * as/hc08/lkarea.c (newarea): read a_addr,
949           (lnkarea): added codemap array, sort absolute areas to the front,
950            combine all GSINITx/GSFINAL,
951           (find_empty_space, allocate_space): new functions,
952           (lnksect): return next address, handle absolute sections
953         * as/mcs51/lkarea.c (newarea): read a_addr,
954           lnksect2 prototype changed,
955           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
956           (find_empty_space, allocate_space): new, factored out of lnksect2,
957           (lnksect2): return next address, handle absolute sections
958         * as/hc08/lkhead.c,
959         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
960         * as/hc08/lklibr.c (addfile, fndsym),
961         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
962           index out of range and detect both '\' and '/'
963         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
964         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
965           regression tests (ds390 cannot return bool yet)
966         * doc/sdccman.lyx: changed version number, document changed --no-peep,
967           document critical interrupts on z80, document changed SDCC define
968         * src/asm.c (_asxxxx_mapping): fixed .org directive,
969           (_a390_mapping): added .org directive
970         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
971           (genMultOneByte): fixed warnings
972         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
973           ones
974         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
975         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
976           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
977         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
978         * src/pic16/main.c: removed newReg prototype
979         * src/pic16/pcode.c,
980         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
981           warnings
982         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
983           ones
984         * src/pic16/ralloc.c
985         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
986           to fix warnings
987         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
988           from short to PIC_OPTYPE
989         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
990         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
991           optype from short to PIC_OPTYPE
992         * src/port.h: made int_size unsigned to fix warnings
993         * src/SDCC.y: fixed warning on MSVC
994         * src/SDCCicode.c (getArraySizePtr): return unsigned int
995         * src/SDCCopt.c (convertToFcall): fixed warnings
996         * src/SDCCsymt.h: removed double prototype for genSymName
997         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
998           offset int to fix warnings
999
1000 2006-04-22 Borut Razem <borut.razem AT siol.net>
1001
1002         * doc/sdccman.lyx, */Makefile, */Makefile.in:
1003           references to CVS replaced with Subversion
1004
1005 2006-04-21 Borut Razem <borut.razem AT siol.net>
1006
1007         * doc/sdccman.lyx, */Makefile, */Makefile.in:
1008           references to CVS replaced with Subversion
1009
1010 2006-04-19 Borut Razem <borut.razem AT siol.net>
1011
1012         * src/version.awk: adapted for svn
1013         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
1014           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
1015           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
1016           /binutils-avr/etc/*.vi, *.jin: removed all properties
1017           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
1018
1019 2006-04-19 Borut Razem <borut.razem AT siol.net>
1020
1021         * CVS to Subversion migration completed
1022
1023 2006-04-18 Borut Razem <borut.razem AT siol.net>
1024
1025         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
1026           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
1027
1028 2006-04-17 Borut Razem <borut.razem AT siol.net>
1029
1030         * device/include/Makefile.in: added pic/*.inc to the installation
1031
1032 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
1033
1034         * support/regression/collate-results.py: fixed output in case of
1035         a valdiag error
1036         * support/regression/generate-cases.py: fixed splitting of pathnames
1037         with dots
1038         * as/hc08/lklibr.c (addfile),
1039         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
1040
1041 2006-04-11 Raphael Neider <rneider AT web.de>
1042
1043         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
1044         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
1045         * src/pic16/pcode.c (assignValnums): fixed #1460578
1046
1047 2006-04-11 Raphael Neider <rneider AT web.de>
1048
1049         * device/lib/pic/libdev/*.c,
1050         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
1051           fixes #1468739, enables compilation in --std-c99 mode
1052         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
1053
1054 2006-04-11 Raphael Neider <rneider AT web.de>
1055
1056         * src/pic/device.c (find_device): removed debug output
1057           (list_valid_pics): enabled verbose listing of supported devices
1058         * device/include/stdbool.h: define bool as char for pic14/16 as well
1059
1060 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1061
1062         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
1063
1064 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1065
1066         * .version: bumped version to 2.5.6
1067         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
1068
1069 2006-04-06 Raphael Neider <rneider AT web.de>
1070
1071         * .version: bumped version to 2.5.6 (pic14 ABI changed)
1072         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
1073         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
1074           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
1075             pic14_constructAbsMap
1076           (pic14printPublics): declare absolute global symbols as global
1077           (pic14createInterruptVect),
1078         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
1079           (newReg): assume new registers unused, use correct name in
1080             hashtable (reg->name instead of name), more debugLog output
1081         * src/pic/device.h (PIC_device): added fields for verbose output
1082         * src/pic/device.c: moved device definition to pic14devices.txt,
1083             added routines for runtime parsing of pic14devices.txt,
1084             added support for second config word
1085         * src/pic/main.c (_process_pragma): removed #pragma maxram,
1086           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
1087           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
1088           (_pic14_parseOptions): moved pCodeInitRegisters here
1089           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
1090         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
1091           (pCodeInitRegisters): rewrapped comments, perpared new approach to
1092             handling the pseudo stack
1093         * device/lib/Makefile.in: ignore failures in objects-pic16,
1094         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
1095         * device/lib/pic/NEWS: document new dependency on picXXX.lib
1096         * device/lib/pic/Makefile.subdir,
1097         * device/lib/pic16/Makefile.subdir: improved clean rules
1098         * device/lib/pic/libdev/: NEW, pic14 device libraries
1099         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
1100         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
1101         * device/include/Makefile.in: create subdir and install pic14 headers
1102         * device/include/pic/p16f_common.inc: removed unused declarations
1103         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
1104             PICs from inc2h.pl v1.6,
1105             replaced BIT_AT macros with struct declarations
1106         * device/include/pic/pic14devices.txt: definition of supported devices,
1107             all above improvements contributed by Zik Saleeba, thanks
1108         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
1109         * support/scripts/sdcc.nsi: also install pic14 device libraries and
1110             headers
1111
1112 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1113
1114         * device/include/mcs51/c8051f410.h: added interrupt numbers,
1115         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
1116           thanks to Charles Olds
1117
1118 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1119
1120         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
1121
1122 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1123
1124         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
1125         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
1126         * support/regression/bug1464657.c: added, new test
1127
1128 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1129
1130         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
1131           version number
1132
1133 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1134
1135         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
1136           --no-peep and --peep-file <file> are used don't use default rules but
1137           do use the <file>
1138
1139 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1140
1141         * src/mcs51/gen.c (genCall): fixed bug 1457608
1142
1143 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1144
1145         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
1146         changes seem to cause (trigger?) problems with the build system.
1147
1148 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
1149
1150         * src/SDCCpeeph.c (operandsLiteral): new, added,
1151           (callFuncByName): inserted operandsLiteral
1152         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
1153
1154 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1155
1156         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
1157         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
1158
1159 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1160
1161         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
1162           implemented patch 1120823 Thanks to Willy De la Court (normal
1163           interrupts need an interrupt number now if they are made critical),
1164           and enabled nesting of critical functions though not for gbz80
1165           (genCritical, genEndCritical): added functions
1166           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
1167         * src/z80/mappings.i: added "ei" to all mappings
1168
1169 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1170
1171         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
1172         submitted by the Debian SDCC maintainer Aurelien Jarno:
1173         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
1174         archive with gcc 4.1 on mips and wrote the patch"
1175
1176 2006-03-16 Raphael Neider <rneider AT web.de>
1177
1178         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
1179           the left operand is shorter than the result (c* = lit-c* + int),
1180           fixes bug #1450796
1181         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
1182           OP_SYMBOL
1183
1184 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
1185
1186         * src/.version: increased version number to 2.5.5
1187         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
1188         linking is done manually in pic16 port's _linkEdit,
1189         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
1190         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
1191         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
1192         allocate asmop as AOP_ACC,
1193         (aopForRemat): added parameter 'bool result' in function declaration,
1194         (pic16_aopGet): return AOP_ACC when accessing WREG,
1195         (pic16_popGetTempReg): minor modification,
1196         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
1197         'pic16_allocWithIdx',
1198         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
1199         calling function in absolute addresses,
1200         (genAssign): take into account AOP_ACC asmop,
1201         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
1202         * src/pic16/pcoderegs.c: some debug functions and lines added,
1203         * src/pic16/ralloc.c (decodeRegType): added but commented out,
1204         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
1205         register too,
1206         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
1207         call to allocReg, not by manually allocating a new one,
1208         (pic16_assignRegisters): now before going through the register
1209         allocating functions mark all registers as free. This eliminates some
1210         side effects resulting from peephole parser done earlier in the backbone
1211
1212 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
1213
1214         * src/SDCCicode.c (geniCodeLogic),
1215         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
1216
1217 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
1218
1219         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
1220           (genSend): bugfix, do not allocate and free twice,
1221           (shiftRLong): handle partially overlapping aops
1222         * support/regression/tests/bitopcse.c: fixed warning redefined idata
1223
1224 2006-03-08 Borut Razem <borut.razem AT siol.net>
1225
1226         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
1227           for pic16
1228
1229 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
1230
1231         * support/regression/tests/bug1409955.c: new, added
1232         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
1233         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
1234           (aopForSym, aopOp): increment asmop.allocated if reused,
1235           (freeAsmop): decrement asmop.allocated and check for zero instead of
1236           using asmop.freed,
1237           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
1238           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
1239            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
1240            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
1241            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
1242            genSignedRightShift, genRightShift, genDataPointerGet,
1243            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
1244            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
1245             in reverse order from allocation,
1246           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
1247             added swappedLR to keep track
1248         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
1249           pdata & code for GCC, z80, gbz80 & hc08
1250         * support/regression/tests/zeropad.c: moved defines to testfwk.h
1251
1252 2006-03-08 Raphael Neider <rneider AT web.de>
1253
1254         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
1255
1256 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
1257
1258         * device/include/mcs51/c8051f410.h: new SiLabs mcu
1259         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
1260         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
1261
1262 2006-03-06 Borut Razem <borut.razem AT siol.net>
1263
1264         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
1265           made the linker quiet
1266
1267 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
1268
1269         * src/pic16/gen.c (genPcall): fixed bug #1443644
1270         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
1271         which dumps before the function entry point a data byte which represents
1272         the number of the local variables used by the specified function, added
1273         'xinst' for initial support for Extended Instruction Support,
1274         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
1275         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
1276         port->fun_prefix anymore (may change later),
1277         (genFunction, genEndFunction): do not store/restore local registers for
1278         _main (this should take care the --main-return command line option in
1279         the future),
1280         (genOr): removed some legacy pic-port instructions,
1281         * src/pic16/genarith.c (genAddLit): re-enabled old code because
1282         performing operations with SFR's causes data to be written more than
1283         once to each SFR. Perhaps SFRs should be handled in special cases...
1284         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
1285         pcode.h
1286         * src/pic16/main.c (_process_pragma): stack bound checking did not take
1287         into account for stack starting position,
1288         (struct OPTIONS pic16_optionsTable): added command line argument
1289         --extended or -y for Extended Instruction Support,
1290         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
1291         (deassignLRs): *** perhaps the most important change, old 'for' code
1292         (commented out for reference), didn't account for some registers which
1293         were left marked 'not free' after a pointer operation. The change
1294         reduces register usage a lot in some cases
1295
1296 2006-03-04 Borut Razem <borut.razem AT siol.net>
1297
1298         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
1299           _clean
1300         * support/regression/tests/bug-524697.c: decreased array size for
1301           mcs51 to fit into the internal RAM
1302         * support/regression/Makefile.in: a little bit more verbose
1303
1304 2006-03-03 Borut Razem <borut.razem AT siol.net>
1305
1306         * support/regression/fwk/lib/testfwk.c,
1307           support/regression/fwk/include/testfwk.h: introduced function
1308           _prints(), nonrecursive _printn(), call _initEmu() from main()
1309         * support/regression/ports/gbz80/support.asm,
1310           support/regression/ports/ucz80/support.asm,
1311           support/regression/ports/z80/support.asm,
1312           support/regression/ports/ds390/support.c,
1313           support/regression/ports/hc08/support.c,
1314           support/regression/ports/host/support.c,
1315           support/regression/ports/mcs51/support.c,
1316           support/regression/ports/xa51/support.c: added empty _initEmu()
1317           function
1318         * support/regression/ports/pic16/gpsim.cmd,
1319           support/regression/ports/pic16/spec.mk,
1320           support/regression/ports/pic16/support.c,
1321           support/regression/Makefile.in: added pic16 regression test
1322
1323 2006-03-01 Raphael Neider <rneider AT web.de>
1324
1325         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
1326           genConstPointerGet): use safe way of generating MOVFF to cover
1327             literals as well as registers, fixes bug #1440527
1328         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
1329             dereference
1330           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
1331             more correctly, fixes bug #1232186
1332           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
1333         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
1334             gplink guess the correct processor in more cases, applied patch
1335             from Till Riedel attached to and fixing bug #1436552
1336
1337 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1338
1339         * support/regression/tests/array.c: added, contains check for #1434401
1340         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
1341
1342 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
1343
1344         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
1345         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
1346         * device/include/mcs51/c8051f326.h,
1347         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
1348         * device/include/mcs51/c8051f000.h,
1349         * device/include/mcs51/c8051f018.h,
1350         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
1351           PCON_IDLE,PCON_STOP and added sfr16 definitions
1352
1353 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1354
1355         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
1356           genGetWord): fixed bug 1409955
1357
1358 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1359
1360         * device/include/hc08/mc68hc908gp32.h,
1361         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
1362
1363 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
1364
1365         * src/SDCCast.c (constExprValue): return NULL if not a value
1366         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
1367         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
1368         * support/regression/tests/bitfields.c: enabled signed bitfield for all
1369
1370 2006-02-13 Borut Razem <borut.razem AT siol.net>
1371
1372         * src/regression/ptrarg.c: added, fails due to bug #1430967
1373         * src/regression/Makefile: ptrarg.c added, ...
1374
1375 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1376
1377         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
1378         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
1379
1380 2006-02-11 Borut Razem <borut.razem AT siol.net>
1381
1382         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
1383           print "Processor: xxx" message to stdout only if --verbose
1384
1385 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1386
1387         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
1388         * support/regression/tests/bug1426356.c: added
1389         * support/regression/tests/bitfields.c: removed 2 tests
1390
1391 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
1392
1393         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
1394         * device/include/mcs51/c8051f330.h,
1395         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
1396           PCON_IDLE,PCON_STOP and added sfr16 definitions
1397         * device/lib/_divsint.c,
1398         * device/lib/_divuint.c,
1399         * device/lib/_divulong.c,
1400         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
1401           register bank bug for small stackauto
1402
1403 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
1404
1405         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
1406
1407 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
1408
1409         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
1410         * all.dsp: corrected several bin paths
1411         * device/include/mcs51/c8051f120.h,
1412         * device/include/mcs51/c8051f300.h,
1413         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
1414           to PCON_IDLE,PCON_STOP
1415         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
1416         * device/lib/printf_large.c (output_float): fixed bug 1388703
1417         * support/regression/tests/bug1057979.c: added test for bug 1388703
1418
1419 2006-02-08 Raphael Neider <rneider AT web.de>
1420
1421         * src/pic/pcode.c (pciTRIS): fixed typo,
1422           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
1423           (LinkFlow): fixed handling of flows that end in a call,
1424           (ReuseReg): perform safety check earlier
1425         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
1426             to work with flows at the beginning of a pBlock,
1427             fixes #1426557 (Symbol not previously defined),
1428           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
1429             usage information
1430           (RemoveUnusedRegisters): update register usage info
1431         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
1432             created, reuse existing ones instead
1433         * src/pic/gen.c (genPcall): fixed #1424719
1434
1435 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
1436
1437         * link/z80/lkmain.c,
1438         * link/z80/lklex.c,
1439         * link/z80/lkdata.c,
1440         * link/z80/aslink.h: fixed build on current cygwin:
1441         replaced getline() by lk_getline()
1442
1443 2006-02-01 Borut Razem <borut.razem AT siol.net>
1444
1445         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
1446           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
1447           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
1448           src/regression/bool1.c, src/regression/bool2.c,
1449           src/regression/bool3.c, src/regression/call1.c,
1450           src/regression/compare.c, src/regression/compare10.c,
1451           src/regression/compare2.c, src/regression/compare3.c,
1452           src/regression/compare4.c, src/regression/compare5.c,
1453           src/regression/compare6.c, src/regression/compare7.c,
1454           src/regression/compare8.c, src/regression/compare9.c,
1455           src/regression/configword.c, src/regression/for.c,
1456           src/regression/inline.c, src/regression/mult1.c,
1457           src/regression/nestfor.c, src/regression/or1.c,
1458           src/regression/pointer1.c, src/regression/ptrfunc.c,
1459           src/regression/rotate1.c, src/regression/rotate2.c,
1460           src/regression/rotate3.c, src/regression/rotate4.c,
1461           src/regression/rotate5.c, src/regression/rotate6.c,
1462           src/regression/rotate7.c, src/regression/string1.c,
1463           src/regression/struct1.c, src/regression/sub.c,
1464           src/regression/sub2.c, src/regression/switch1.c,
1465           src/regression/while.c, src/regression/xor.c,
1466           src/regression/create_stc, src/regression/simulate,
1467           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1468           regression tests
1469         * src/regression/gpsim_assert.h: added
1470
1471 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1472
1473         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1474         ((void (code *) (void)) 0) ();
1475         * as/hc08/aslex.c,
1476         * as/hc08/aslink.h,
1477         * as/hc08/asm.h,
1478         * as/hc08/asmain.c,
1479         * as/hc08/lkdata.c,
1480         * as/hc08/lklex.c,
1481         * as/hc08/lkmain.c,
1482         * as/mcs51/aslex.c,
1483         * as/mcs51/aslink.h,
1484         * as/mcs51/asm.h,
1485         * as/mcs51/asmain.c,
1486         * as/mcs51/lkdata.c,
1487         * as/mcs51/lklex.c,
1488         * as/mcs51/lkmain.c,
1489         * as/z80/aslex.c,
1490         * as/z80/asm.h,
1491         * as/z80/asmain.c: fixed build on current cygwin:
1492         replaced getline() by as_getline()
1493
1494 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1495
1496         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1497         declarator in the symbol chain
1498         * src/SDCCsymt.h,
1499         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1500         parameter list for function pointers
1501         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1502         * support/regression/tests/bug-716242.c: added
1503
1504 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1505
1506         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1507         offset if possible
1508         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1509
1510 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1511
1512         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1513         inifinitely recurseable, added static
1514         * support/regression/tests/bug-1408066.c: added
1515
1516 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1517
1518         * src/SDCCicode.h,
1519         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1520         renamed, added possibility to create "postLoopLbl"-labels
1521         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1522         newiTempLoopHeaderLabel
1523         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1524         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1525         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1526         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1527         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1528         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1529         (basicInduction): fixed bug #136564, made static,
1530         (loopInduction): changed parameter of basicInduction, made static,
1531         (addPostLoopBlock): added
1532         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1533         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1534         findLoopEndSeq
1535         * support/regression/tests/bug-136564.c: added
1536         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1537         --std-sdcc99 to LIBSDCCFLAGS
1538
1539 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1540
1541         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1542         while loop
1543         * support/regression/tests/bug-1406131.c: added
1544
1545 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1546
1547         * src/SDCCast.c (decorateType): fix promotion of unary minus
1548         * src/SDCCsymt.c (computeType): beautified
1549         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1550         (valUnaryPM, valComplement): fix sign and promotion,
1551         (valNot): ANSI: result type is int (SDCC: unsigned char)
1552         * support/regression/tests/uminus.c: speedup by removing superflous
1553         test case 'int'
1554         * support/regression/tests/onebyte.c: added promotion and signedness
1555         tests for unary minus
1556         * support/regressions/tests/bug-477927.c: disable warning about
1557         uninitialized variables
1558         * support/regression/tests/not.c: added
1559
1560 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1561
1562         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1563         * src/mcs51/gen.c (gen51Code): show final register usage after
1564         fillGaps in asm with --i-code-in-asm
1565         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1566         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1567         incUsed, rliveClear, adjustIChain): made static,
1568         (setFromRange): excluded because it's unused,
1569         (findPrevUseSym, markWholeLoop): added,
1570         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1571         through all branches of predecessors enables sdcc to emit the warning
1572         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1573         (rlivePoint): made static, added parameter emitWarnings which is only
1574         true during the first run out of two,
1575         (findRecursiveSucc, findRecursivePred): removed,
1576         (computeLiveRanges): made static, added parameter emitWarnings,
1577         (dumpIcRlive): added for debugging only
1578         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1579         removed prototype of setFromRange()
1580         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1581         in call of computeLiveRanges()
1582         * support/regression/tests/bug-895992.c: added
1583         * support/regression/tests/bug-971834.c: added
1584         * support/valdiag/tests/bug-895992.c: added
1585         * support/valdiag/tests/bug-971834.c: added
1586
1587 2005-12-18 Raphael Neider <rneider AT web.de>
1588
1589         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1590           (genUnpackBits): improved code for direct operands,
1591           (genPackBits): improved code for literal assignment to bitfields
1592             and for direct destination operands (no FSR indirection),
1593             prevented redundant AND, fixes #1362800,
1594           (AccLsh): added parameter to disable masking of the result
1595         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1596           skip instructions with side-effects (like incfsz),
1597           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1598         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1599         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1600           fixes #1375263
1601
1602 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1603
1604         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1605         volatile variables as spill location
1606
1607 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1608
1609         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1610         replacing literals
1611         * support/regression/tests/bug-1376320.c: added
1612
1613 2005-12-08 Raphael Neider <rneider AT web.de>
1614
1615         * src/pic/device.c: renamed is_shared to pic14_is_shared
1616         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1617         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1618           (is_valid_identifier): added for above workaround
1619
1620 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1621
1622         * device/lib/Makefile.in: fixed to enable port-specific-objects
1623         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1624           char, thanks Hubert Sack
1625         * doc/sdccman.lyx: documented --xstack-loc,
1626           elaborated a bit more on interrupts and pitfalls,
1627           removed "setjmp/longjmp unsupported",
1628           documented some unsupported C99 features
1629         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1630         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1631           if, thanks Hubert Sack
1632         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1633         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1634           make make_library
1635         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1636           regression tests can report resource usage (rfe 700441)
1637         * support/regression/collate-results.py: report resource usage
1638         * support/regression/ports/ds390/spec.mk,
1639         * support/regression/ports/hc08/spec.mk,
1640         * support/regression/ports/mcs51/spec.mk,
1641         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1642         * support/regression/ports/ds390/uCsim.cmd,
1643         * support/regression/ports/hc08/uCsim.cmd,
1644         * support/regression/ports/mcs51/uCsim.cmd,
1645         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1646         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1647           library, use the default one
1648         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1649           building the library
1650
1651 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1652
1653         * config.dsp: added dependency on .version and configure_vc.awk
1654         * device/include/setjmp.h: updated for --stack-auto and --xstack
1655         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1656         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1657         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1658         * device/lib/libsdcc.lib: added _setjmp
1659         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1660           (decorateType): fixed bug 1372851,
1661           (optimizeGetHbit): fixed warning
1662         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1663           array initialisation
1664         * support/regression/tests/bug1057979.c: added test for bug 1358192
1665         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1666
1667 2005-12-03 Borut Razem <borut.razem AT siol.net>
1668
1669         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1670           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1671
1672 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1673
1674         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1675         createIval): implement symbol independant "flexible array member",
1676         (createIvalCharPtr): implemented flexible array initialisation with a
1677         string
1678         * src/SDCCsymt.c (copyStruct): removed,
1679         (getSize): fixed misleading comment,
1680         (getAllocSize): removed, the additional allocation size is now in
1681         sym->flexArrayLength,
1682         (checkStructFlexArray): new, syntax checks for flexible array members,
1683         (compStructSize): added syntax checks for "flexible array members"
1684         (copyStruct): removed,
1685         (copyLinkChain): removed inefficient fix for bug 770487
1686         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1687         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1688         symbol->flexArrayLength
1689         * src/SDCCerr.c,
1690         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1691         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1692         * support/regression/tests/structflexarray.c: added
1693         * support/valdiag/tests/structflexiblearray.c: added
1694
1695 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1696
1697         * src/SDCCast.c (decorateType): fixed bug 1368489
1698         * support/Util/SDCCerr.c,
1699         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1700
1701 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1702
1703         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1704           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1705
1706 2005-11-27 Borut Razem <borut.razem AT siol.net>
1707
1708         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1709           support/cpp2/mkdeps.h: added command line option
1710           -obj-ext=<extension> to SDCPP to define object file externion, used
1711           for generation of make dependencies (-M)
1712         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1713
1714 2005-11-26 Borut Razem <borut.razem AT siol.net>
1715
1716         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1717           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1718           added pic and pic16 libraries
1719
1720 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1721
1722         * device/include/float.h: Corrected typo in prototype of __fsgt
1723
1724 2005-11-25 Borut Razem <borut.razem AT siol.net>
1725
1726         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1727           added creation of model-mcs51-stack-auto libraries
1728
1729 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1730
1731         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1732         and fields-list too
1733         * src/SDCCast.c (createIvalArray): removed obsolete comment
1734
1735 2005-11-24 Borut Razem <borut.razem AT siol.net>
1736
1737         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1738           added missing device/lib/mcs51/crt*.asm sources
1739
1740 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1741
1742         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1743
1744 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1745
1746         * device/lib/_fs2schar.c,
1747         * device/lib/_fs2sint.c,
1748         * device/lib/_fs2slong.c: optimized inline asm
1749
1750 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1751
1752         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1753           Better handling of floats between -1.0 and 0.0.
1754
1755 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1756
1757         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1758           (the missing "if"s prohibited removal of redundant labels)
1759
1760 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1761
1762         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1763           Properly convert floats between -1.0 and 0.0 to long, int, and char
1764           types (max integer value of negative floats tends to zero).
1765         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1766           Removed changes made so to work properly with floats between
1767           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1768           and _fs2char.c
1769
1770 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1771
1772         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1773         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1774         (genCast) cosmetic change
1775         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1776         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1777         from mcs51
1778         * support/regression/tests/bitfields (testSignedBitfields): added
1779
1780 2005-11-18 Borut Razem <borut.razem AT siol.net>
1781
1782         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1783         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1784           introduced SILENT option to make building of pic16 libraries less
1785
1786 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1787
1788         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1789           Now they work properly with floats between -1.0 and 0.0
1790         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1791
1792 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1793
1794         * src/SDCCicode.c (printOperand): added missing else
1795
1796 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1797
1798         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1799         reformatted for better readability
1800         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1801         signed bitfields
1802
1803 2005-11-17 Borut Razem <borut.razem AT siol.net>
1804
1805         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1806           introduced SILENT option to make building of pic16 libraries less
1807           verbose - used for nightly snapshot build
1808         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1809           available on Win32 platforms.
1810         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1811           medium, large, pic and pic16
1812
1813 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1814
1815         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1816           printf("%f"...) sets fraction to zero.
1817
1818 2005-11-16 Raphael Neider <rneider AT web.de>
1819
1820         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1821           fixes #1357221
1822         * src/pic/gen.c (genIfx): implemented for CARRY bit
1823         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1824           to generic pointers, fixes #1357332,
1825           (pic16_movLit2f): NEW,
1826           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1827
1828 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1829
1830         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1831
1832 2005-11-11 Raphael Neider <rneider AT web.de>
1833
1834         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1835         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1836           compute pointer's type from operand,
1837           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1838           improved single bit reads, fixes bug #1353379
1839
1840 2005-11-09 Borut Razem <borut.razem AT siol.net>
1841
1842         * support/scripts/sdcc.nsi: added lib/pic to the package
1843
1844 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1845
1846         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1847
1848 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1849
1850         * support/regression/tests/bug1348008.c: added
1851         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1852         * support/regression/tests/bug1337835.c: updated comment
1853
1854 2005-11-06 Borut Razem <borut.razem AT siol.net>
1855
1856         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1857           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1858           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1859           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1860           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1861           dynamic construction of cl_error_class and derivates - 2.nd try
1862
1863 2005-11-05 Borut Razem <borut.razem AT siol.net>
1864
1865         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1866           bug, which caused Bus Errors on sparc solaris
1867
1868 2005-11-04 Borut Razem <borut.razem AT siol.net>
1869
1870         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1871           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1872           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1873           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1874           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1875           and derivates to resolve the initialization problem on OSX
1876
1877 2005-11-02 Borut Razem <borut.razem AT siol.net>
1878
1879         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1880           corrected typo - #include <winsock2.h>
1881
1882 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1883
1884         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1885           (_asxxxx_mapping): added org directive for future enhancements
1886
1887 2005-11-01 Borut Razem <borut.razem AT siol.net>
1888
1889         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1890           enabled sockets on WIN32
1891         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1892
1893 2005-10-31 Borut Razem <borut.razem AT siol.net>
1894
1895         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1896           WIN32 backslash path delimiters should be escaped when used in C strings
1897         * support/regression/tests/bitfields.c: exclude failing assertions for
1898           __CYGWIN32__ and __MINGW32__ hosts
1899
1900 2005-10-30 Borut Razem <borut.razem AT siol.net>
1901
1902         * src/SDCCutil.c: corrected double comparison typo
1903
1904 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1905
1906         * device/lib/medium/Makefile: added for new memory model medium
1907         * device/include/asm/mcs51/features.h: updated for medium/pdata
1908         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1909           added Multiply & Accumulate sbit's and MAC0_PAGE define
1910         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1911         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1912         * device/lib/_mullong.c: update for medium model
1913         * device/lib/incl.mk: added medium model
1914         * doc/sdccman.lyx: documented medium model
1915         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1916         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1917         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1918         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1919           (allocParms): set SCLS and OCLS to pdata for medium model
1920         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1921           for pdata,
1922           (powof2): return <0 if not power of 2
1923         * src/avr/gen.c (genBitWise): use updated powof2
1924         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1925           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1926           (shiftLLeftOrResult): use B if necessary
1927         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1928         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1929         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1930         * support/regression/Makefile.in: added test-mcs51-medium
1931         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1932
1933 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1934
1935         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1936         specifier unsigned
1937         * device/lib/time.c (mktime): fixed bug 1334315
1938
1939 2005-10-28 Raphael Neider <rneider AT web.de>
1940
1941         * device/include/pic/p16f_common.inc: added common declarations
1942         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1943
1944 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1945
1946         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1947           (aopPutUsesAcc): added to predict accumulator use,
1948           (assignResultValue): save acc if necessary,
1949           (genMinusDec): store result if indirectly addressed,
1950           (genDivOneByte):  save acc if necessary,
1951           (movLeft2Result): bugfix if left already in acc,
1952           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1953             attention to accumulator use (esp. pdata),
1954           (genReceive): receive pdata correctly
1955         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1956         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1957
1958 2005-10-27 Raphael Neider <rneider AT web.de>
1959
1960         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1961
1962 2005-10-27 Raphael Neider <rneider AT web.de>
1963
1964         * .version: changed version to 2.5.4
1965         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1966         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1967           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1968             arithmetics support routines
1969         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1970         * device/lib/Makefile.in: also create installdir for pic
1971
1972         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1973           pic14 port as well
1974         * src/pic/device.c (dump_sfr): rewritten to delegate register
1975           placement to the linker (use `extern sym' rather than sym EQU addr),
1976           (validAddress): fixed to check last specified address
1977         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1978           (popGetLit): truncate literal value to 8 bit,
1979           (popGet): moved assert to more appropriate place
1980           (popGetExternal): create pCode operand from and mark the according
1981             symbol as being `extern'
1982           (popGetAddr): added sanity check on immediate's offset, provide
1983             GPOINTER tag on demand
1984           (aopPut): fixed for immediates,
1985           (mov2w_op): move operand's address or contents to WREG (depending on
1986             operand type), safer variant of mov2w,
1987           (movwf,call_libraryfunc): NEW, handy abbreviations,
1988           (get_argument_pcop,get_return_val_pcop,pass_argument,
1989           get_returnvalue): interface for accessing function parameters and
1990             return values,
1991           (assignResultValuei,genRet): use new parameter/return value interface
1992           (pic14_getDataSize): back to old version handling generic pointers,
1993           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
1994             provided implementation and/or fixed old one,
1995           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
1996             calls, removed legacy 8051 reference code
1997           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
1998           (loadSignToC): NEW, move the operands sign bit to CARRY,
1999           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
2000             genRightShiftSigned, accepts negative shift counts,
2001           (setup_fsr): load FSR and adjust IRP (indirect memory access),
2002           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
2003             generic pointers, __data pointers and __code pointers,
2004           (genUnpackBits,genPackBits): rewritten to work with generic pointers
2005             and signed bitfields, limit bitfields to 8 bit,
2006           (genDataPointerGet): fixed number of bytes read,
2007           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
2008           (genPointerGet,genPointerSet): fixed handling of __code pointers,
2009             pointers to constant data are no longer assumed to point to __code
2010             space, removed invalid pointer types,
2011           (bitpatternFromVal): retrieve the PICs representation of an integer
2012             or float literal,
2013           (genDataPointerSet): fixed assigning to po_immediate operands,
2014           (genGenPointerSet): implemented as library call,
2015           (genIfx): fixed incorrect condition,
2016           (genAddrOf): limit generic pointers' addresses to 2 bytes,
2017             provide GPOINTER tag according to destination's storage class,
2018           (genCast): added code to handle casting to generic pointers, added
2019             sign-/zero extension of the result
2020           (aop_isLitLike,op_isLitLike): fixed handling of immediates
2021         * src/pic/gen.h: added macros to access IRP bit in STATUS register
2022         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
2023           extend the result
2024         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
2025           address/register resides in the shared banks
2026           (emitSymbolToFile): improved to handle global and `pinned' symbols,
2027             put all variables into separate sections (have the linker arrange
2028             them)
2029           (picglue): put init code and interrupt handlers in separate sections
2030         * src/pic/main.c: added port specific options table, modified to PORT
2031           structure to make GPOINTERs 3 byte, added pic14_options
2032           (_pic14_do_link): private linking routine (update paths to libraries,
2033             add libsdcc.lib by default)
2034         * src/pic/main.h: declare pic14_options
2035         * src/pic/pcode.c: fixed instructions i/o relations,
2036           (RegCond): reverted to correct version,
2037           (newpCodeOpLit): truncate literals to 8 bit,
2038           (genericPrint): added debug output,
2039           (getRegFromInstruction): fixed for various operand types, simplified
2040           (BuildFlow): fixed broken handling of isntructions with labels
2041           (LinkFlow): start at last instruction in flow (skip trailing comments),
2042             pass the flow on to the next instruction after CALL
2043           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
2044           (insertPCodeInstruction): fixed inserting after a skip instruction,
2045           (DoBankSelect): fixed for labeled instructions
2046           (OptimizepBlock): honor --nopeep switch
2047           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
2048         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
2049         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
2050           (pCodeOptime2pCodes): allow disabling this optimization via
2051             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
2052             but is still buggy), started implementation of a dataflow based
2053             pCode optimization (CSE + dead code elimination)
2054           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
2055         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
2056           names are independant of the stack location and therefore portable across
2057           devices
2058
2059 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
2060
2061         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
2062           (selectSpil): fixed bug 1337835 by not spilling bit variables
2063         * support/regression/tests/bug1337835.c: added test for this bug
2064         * src/mcs51/peeph.def: restart after rule 3.c,
2065           addded rules 263.x to optimize loading constants
2066
2067 2005-10-26 Raphael Neider <rneider AT web.de>
2068
2069         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
2070         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
2071           (genAssign): emit warning when casting literals to generic pointer
2072             type, also applies when taking the address of a fixed variable,
2073           (genCast): improved casting to generic pointers
2074         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
2075           extern variables, added verbose error message
2076         * device/include/pic16/{string.h,errno.h}: added #pragma library c
2077
2078 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
2079
2080         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
2081         carry must be complemented too
2082         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
2083         could be emitted by genMinus
2084         * src/SDCCval.c (constVal): fixed bug 1305065
2085
2086 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
2087
2088         * src/SDCCast.c (addCast): added promotion for bit variables
2089         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
2090         promotion casts + optimisation
2091         (optimizeGetWord): fix warning 'i' might be used uninitialized
2092         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
2093         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
2094
2095 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
2096
2097         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
2098         all chars are promoted to int; promotion should be handled in SDCCast.c
2099
2100 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2101
2102         * device/lib/_strcmp.c: Fixed bug 1326457
2103
2104 2005-10-11 Raphael Neider <rneider AT web.de>
2105
2106         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
2107         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
2108
2109 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
2110
2111         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
2112         * support/regression/tests/sfr16.c: added test for the sfr32 bug
2113
2114 2005-10-04 Raphael Neider <rneider AT web.de>
2115
2116         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
2117           device/lib/pic16/pics.all: added pic18f1320
2118         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
2119
2120 2005-09-30 Raphael Neider <rneider AT web.de>
2121
2122         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
2123         * src/pic16/devices.inc: NEW, provides device descriptions
2124         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
2125
2126 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
2127
2128         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
2129           GETHBIT
2130
2131 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
2132
2133         * doc/sdccman.lyx: updated Highest Order Bit documentation,
2134           documented Any Order Bit, Higher Order Byte and Higher Order Word
2135         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
2136         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
2137           (optimizeGetAbit): new, to get any bit, not only the high bit,
2138           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
2139           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
2140           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
2141           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
2142             RIGHT_OP: also try GETBYTE, GETWORD optimization,
2143             GETABIT, GETBYTE, GETWORD: decorate them,
2144           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
2145           (ast_print): added GETABIT, GETBYTE, GETWORD
2146         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
2147         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
2148           (geniCodeBinary): new generic binary icode,
2149           (ast2iCode): added GETABIT, GETBYTE, GETWORD
2150         * src/port.h: updated comment for PORT.hasExtBitOp
2151         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
2152           (genGetByte): new, to get a single byte,
2153           (genGetWord): new, to get a word from a long,
2154           (gen51Code): added GETABIT, GETBYTE, GETWORD
2155         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
2156
2157 2005-09-23 Raphael Neider <rneider AT web.de>
2158
2159         * configure.in, configure: have device/lib/pic configured
2160         * device/lib/Makefile.in: added model-pic14
2161         * device/lib/clean.mk: added pic/ to clean rule
2162         * device/lib/pic: added rudimentary pic14 library providing support
2163           functions for multiplication/division/generic pointer access
2164         * src/SDCCopt.c (convilong): mark support functions as extern
2165           for pic14 port as well
2166         * src/pic/gen.c (genMult): added assertions,
2167           (genpic14Code): emit warning on unhandled iCodes
2168         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
2169         * src/pic/pcode.c (pCodeOpCopy),
2170         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
2171           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
2172           SFR_REGISTER}), made safe for future extensions
2173         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
2174           instructions even if preceeded by SKIP instructions (also remove
2175           them); removed unused code
2176         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
2177           prevents leaving parts of the structure uninitialized after copying
2178
2179 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
2180
2181         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
2182           ago by me
2183         * support/regression/tests/addsub.c: added test for the bug
2184
2185 2005-09-21 Raphael Neider <rneider AT web.de>
2186
2187         * device/include/pic16/pic18f1220.h,
2188           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
2189         * device/lib/pic16/Makefile.rules: added missing opening paren
2190         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
2191           are provided in genutils.c,
2192           (genUminusFloat,genUminus,genCmpEq): added asserts on different
2193           operand/result sizes,
2194           (genCmp): assert on NULL pointers first, then check deref'ed values
2195         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
2196           result size
2197
2198 2005-09-18 Raphael Neider <rneider AT web.de>
2199
2200         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
2201           as these are now unused,
2202           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
2203         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
2204           local, avoids uninitialized pointer dereference on r->name
2205         * src/pic16/ralloc.c (newReg): fixed indentation
2206
2207 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
2208
2209         * src/SDCCval.c (constVal): fixed bug 730366
2210         * support/Util/SDCCerr.c,
2211         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
2212
2213 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
2214
2215         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
2216
2217 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
2218
2219         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
2220
2221 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
2222
2223         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
2224           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2225         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
2226           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2227         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
2228         * packihx/packihx.c (hexDigit): made c unsigned char
2229         * as/mcs51/lklibr.c (fndsym),
2230         * link/z80/lkgb.c (gb),
2231         * link/z80/lklibr.c (fndsym),
2232         * link/z80/lkrloc.c (relr),
2233         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
2234         * src/SDCC.lex (checkCurrFile, process_pragma),
2235         * src/SDCCglue.c (spacesToUnderscores),
2236         * src/SDCCmain.c (setParseWithComma, processFile),
2237         * src/asm.c (tvsprintf, printCLine),
2238         * src/avr/gen.c (emitcode, aopPut),
2239         * src/ds390/gen.c (emitcode),
2240         * src/hc08/gen.c (emitcode, emitinline),
2241         * src/mcs51/gen.c (emitcode, genInline),
2242         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2243           tokenizeLineNode),
2244         * src/pic/ralloc.c (debugLog),
2245         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2246           tokenizeLineNode),
2247         * src/pic16/ralloc.c (debugLog),
2248         * src/z80/main.c (_process_pragma):
2249            made all ctype.h function calls safe
2250         * src/SDCCopt.c: include math.h for fabs
2251         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
2252           and used them throughout the code to make ctype.h function calls safe
2253         * src/ds390/main.c (asmLineNodeFromLineNode),
2254         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
2255         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
2256            unsigned char*
2257         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
2258           (newpCodeAsmDir): made ctype.h function calls safe
2259         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
2260           pic16_emitcode):  made lbp unsigned char*
2261         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
2262           (pic16_newpCodeAsmDir): made ctype.h function calls safe
2263         * src/xa51/gen.c (emitcode),
2264         * src/z80/gen.c (_emit2): made lbp unsigned char*
2265         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
2266            char*
2267
2268 2005-09-05 Raphael Neider <rneider AT web.de>
2269
2270         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
2271           access bank splitpoint
2272
2273 2005-09-05 Raphael Neider <rneider AT web.de>
2274
2275         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
2276
2277 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
2278
2279         * .version: changed to version 2.5.3
2280         * doc/sdccman.lyx: changed version to 2.5.3,
2281           documented --codeseg and --constseg and pragma codeseg and constseg,
2282           documented bit parameters (reentrant) and bit returning
2283         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
2284            currFunc->recvSize, but is this ok for all ports?
2285           (ast2iCode): result of ~ on unsigned char must be cast to int for
2286            bool to work
2287         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
2288           function pointers in bit space
2289         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
2290           (processFuncArgs): call port.reg_parm() with reentrancy info
2291         * src/port.h,
2292         * src/avr/main.c,
2293         * src/ds390/main.c,
2294         * src/hc08/main.c,
2295         * src/pic/main.c,
2296         * src/pic16/main.c,
2297         * src/xa51/main.c,
2298         * src/z80/main.c: port.reg_parm prototype extended with
2299           "bool reentrant" parameter
2300         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
2301           options.stackAuto for allocating bit register parameters
2302         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
2303           (genSend): set BitBankUsed if it is,
2304           (selectRegBank): factored out of genCall for use in genPcall,
2305           (genCall): removed redundant dtype assignmen, use selectRegBank,
2306           (genPcall): handle returning in Carry properly, save in F0 if needed,
2307           (genReceive): handle bit register parameters
2308         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
2309           (mcs51_assignRegisters): enable bit registers for all reentrant
2310            functions and don't set BitBankUsed unconditionally
2311         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
2312         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
2313         * support/regression/tests/funptrs.c: added tests for BOOL and for return
2314
2315 2005-08-27 Borut Razem <borut.razem AT siol.net>
2316
2317         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
2318         ppc-osx (Darwin) does not support -u option. It seems that it is
2319         supported only on Linux - GNU cp
2320
2321 2005-08-25 Borut Razem <borut.razem AT siol.net>
2322
2323         * sim/ucsim/gui.src/serio.src/Makefile.in,
2324           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
2325           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2326           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
2327           install and strip, since the strip at /usr/ccs/bin should be used
2328           on solaris
2329
2330 2005-08-24 Borut Razem <borut.razem AT siol.net>
2331
2332         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
2333
2334 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
2335
2336         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
2337         ffffffffu
2338
2339 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
2340
2341         * as/mcs51/aslink.h: completed lkrloc.c prototypes
2342         * as/mcs51/lkmain.c (link_main): fixed warning
2343         * device/include/stdbool.h: ds390 has no advanced bit support yet
2344         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
2345         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
2346         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
2347           and updated their macros
2348         * src/SDCCval.c (constVal): updated comment for renamed b_long
2349
2350 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
2351
2352         * as/mcs51/asdata.c: changed ctype['['] to BINOP
2353         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
2354           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
2355           (oprio): set priority for '['
2356         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
2357            and adb_24_bit
2358         * as/mcs51/asm.h: added defines R_BIT and S_BIT
2359         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
2360         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
2361         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
2362           added overlayable BIT_BANK area
2363         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
2364           (summary2): explain 'T' in legenda
2365         * as/mcs51/lkrloc.c: replaced old K&R style,
2366           (relr): added R_BIT processing,
2367           (errmsg): added "Bit-addressable relocation error",
2368           (adb_bit): added for converting from byte- to bit-addressable space,
2369           (adb_24_bit): added for converting from byte- to bit-addressable space
2370         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
2371            used in reentrant functions now even as return value
2372         * device/lib/_gptrput.c (_gptrput): removed obsolete code
2373         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
2374           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
2375         * src/SDCCglobl.h: added indicator BitBankUsed
2376         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
2377            the bit registers b0-b7
2378         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
2379           (geniCodeCast): fixed bug 1263853,
2380           (geniCodeLogicAndOr): put result in bool or char,
2381           (geniCodeReceive): added parameter func for accessing the return type,
2382           (geniCodeFunctionBody): pass func to geniCodeReceive
2383         * src/SDCCmain.c: added indicator BitBankUsed
2384         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
2385         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
2386           (checkSClass): don't put automatic bool/bit on stack,
2387           (checkFunction): removed check on function cannot return bit
2388         * src/SDCCsymt.h: added newBoolLink prototype
2389         * src/mcs51/gen.c (rb1regs): added bit registers,
2390           (movc): created for assigning to carry,
2391           (pushReg, popReg): created for pushing registers,
2392           (sameRegs): check both AOP_REG and AOP_CRY types,
2393           (aopOp): handle bit registers,
2394           (aopPut): optimization no self-assign,
2395           (saveRegisters): push reg->base (bits) only once for bit registers,
2396            and use pushReg,
2397           (unsaveRegisters): pop reg->base only once and use popReg,
2398           (assignResultValue): added parameter func and return in carry for bits,
2399           (genIpush): optimization no reload in A if not changed,
2400           (genSend): bit parameters in reentrant functions are passed in bit
2401            registers by first assigning to bits in B, then save registers and
2402            copy B to bits,
2403           (genCall): handle returning in Carry properly, save it in F0 if needed,
2404           (genPcall): updated assignResultValue call, this is not safe yet for bit
2405            returning function !!!
2406           (genFunction): don't generate equ's for bit registers and use pushReg,
2407           (genEndFunction): take care of bit returning functions and use popReg,
2408           (genRet): return bit in Carry,
2409           (genIfx): optimize bit registers and other directly addressable bits,
2410           (genReceive): updated assignResultValue call
2411         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
2412           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
2413            registers when using stack-auto
2414         * src/mcs51/ralloc.c (_G): added allBitregs,
2415           (regs8051): added the bit registers,
2416           (createStackSpil): use macro IS_BIT,
2417           (getRegBit): added to allocate a bit register, else spill,
2418           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
2419           (updateRegUsage): factored out to ease stepping while debugging,
2420           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
2421            also allocate bit registers,
2422           (fillGaps): handle bit registers,
2423           (findAllBitregs): added to create bit vector with all bit registers,
2424           (mcs51_allBitregs): returns this bit vector,
2425           (mcs51_assignRegisters): when using stack-auto use bit registers for
2426            passing parameters and creating local variables
2427         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
2428
2429 2005-08-22 Borut Razem <borut.razem AT siol.net>
2430
2431         * device/lib/Makefile.in: replaced find option -or with -o
2432           to make it run on solaris
2433
2434 2005-08-22 Raphael Neider <rneider AT web.de>
2435
2436         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
2437           fixes #1265442 (crash on Solaris)
2438
2439 2005-08-20 Borut Razem <borut.razem AT siol.net>
2440
2441         * configure, configure.in: added tests for libsocket and libnsl libraries,
2442           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
2443           from support/regression/Makefile.in
2444         * support/regression/Makefile.in: added
2445         * device/lib/pic16/Makefile.common.in: force make to use bash shell
2446         * sim/ucsim/libtool: regenerated on sparc-solaris
2447         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2448           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
2449           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
2450           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
2451           sparc-solaris, which doesn't use GNU ld linker
2452         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
2453         * as/Makefile: find on sparc-solaris does not support -maxdepth option
2454
2455 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2456
2457         * src/mcs51/peeph.def: updated comments
2458
2459 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2460
2461         * device/lib/_gptrget.c,
2462         * device/lib/_gptrput.c: slightly shorter
2463         * doc/sdccman.lyx: incremented version
2464         * src/mcs51/peeph.def: moved peephole comments to the line of first
2465           change to better keep line correlation, reanimated 186.e
2466         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2467
2468 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2469
2470         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2471           David Saxton with quotes around file name.
2472
2473 2005-08-15 Borut Razem <borut.razem AT siol.net>
2474
2475         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2476           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2477           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2478           make tests run on x86_64 platform
2479
2480 2005-08-13 Raphael Neider <rneider AT web.de>
2481
2482         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2483           as it might be executed DURING a build (parallel make is wonderful)
2484
2485 2005-08-13 Raphael Neider <rneider AT web.de>
2486
2487         * device/lib/Makefile.in (port-specific-objects-pic16):
2488           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2489         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2490           dependency
2491         * device/lib/pic16/Makefile.rules: build subdirs before creating
2492           the library, removed builddir rule, create $(builddir) early in
2493           recurse rule, use empty recurse rule for leaf directories
2494         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2495           mkdir errors (race condition), removed duplicate suffix "hex"
2496           from clean rules
2497         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2498         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2499           prevents mkdir -p from aborting on Alpha
2500
2501 2005-08-12 Raphael Neider <rneider AT web.de>
2502
2503         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2504           db-statements in order to allow for arrays of pointers in code
2505           sections to be placed without interspersed 0-padding, fixes
2506           bug #1256215
2507         * (emitStatistics): fixed division by zero for pic18f1220
2508         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2509           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2510         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2511         * (pic16_pCodeConstString): keep track of already emitted string
2512           literals to prevent "duplicate definitions of symbol _str_NR"
2513         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2514           debug message
2515         * device/lib/Makefile.in: ignore failing PIC16 library builds
2516         * device/lib/pic16/Makefile: do not build if gputils are missing
2517         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2518
2519 2005-08-10 Raphael Neider <rneider AT web.de>
2520
2521         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2522           my last commit)
2523
2524 2005-08-10 Raphael Neider <rneider AT web.de>
2525
2526         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2527           Rokas' patch to add the new fixed point type "__fixed16x16"
2528         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2529           functions for __fixed16x16 arithmetics
2530         * device/lib/pic16: reimplemented the build system to support
2531           a separate build directory, better handling of libio (create
2532           the library in a separate subdir for each architecture) and
2533           easier configuration (centralized in Makefile.common)
2534
2535 2005-08-07 Raphael Neider <rneider AT web.de>
2536
2537         * src/pic16/gen.c (genrshTwo): fixed sign extension
2538         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2539         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2540           added T0CONbits
2541         * device/include/pic16/pic18f4220.h: NEW, header for
2542           pic18f4220 and pic18f4320
2543         * device/include/pic16/pic18fregs.h: added new devices,
2544           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2545         * device/include/pic16/signal.h: resolved name clashes
2546           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2547           to also allow testing for interrupt enable bits, added
2548           comments on how to use the macros
2549         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2550         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2551           register definitions for the devices
2552         * device/lib/pic16/pics.all: added new devices
2553         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2554           allocated memory
2555         * device/lib/pic16/libc/stdlib/memfree: do not count
2556           the block header as free memory
2557         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2558           simplified and added missing end-of-blocklist-marker
2559           (reported by Peter Onion, fixes #1252814)
2560         * (_mergeHeapBlock): fixed loop condition
2561         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2562           len==0, restructured code
2563         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2564           up a bit, reduced bitfield accesses, prevent endless loops
2565           in case of heap corruption
2566         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2567           "unreferenced arguments/must return a value" warnings
2568         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2569           replaced BAUDREG with SPBRG
2570         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2571           device/lib/pic16/debug/gstack/gstack.c: replaced
2572           _naked, _asm, _endasm with __naked, __asm, __endasm
2573
2574 2005-08-05 Raphael Neider <rneider AT web.de>
2575
2576         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2577           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2578
2579 2005-08-05 Borut Razem <borut.razem AT siol.net>
2580
2581         * device/lib/Makefile.in: added missing ';'
2582         * configure: removed ^M characters
2583
2584 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2585
2586         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2587           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2588           License
2589
2590 2005-08-04 Borut Razem <borut.razem AT siol.net>
2591
2592         * configure.in: pic16 libraries build 2nd try - enable running
2593           configure in device/lib/pic16
2594         * configure: regenerated from configure.in
2595         * device/lib/Makefile.in: create $(PORT)/bin directory
2596
2597 2005-08-03 Raphael Neider <rneider AT web.de>
2598
2599         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2600           to get/set values via pointers
2601         * (genUnpackBits,genPackBits): changed detection of
2602           ptr->bitfield vs. sym.bitfield, fixed access via generic
2603           pointers, removed dead (wrong) code for multibyte bitfields
2604         * (genNearPointerGet, genGenPointerGet): removed useless code,
2605           fixed bitfield detection, fixes #1250594
2606         * (genNearPointerSet): removed useless code
2607         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2608           and introduced macro pic16_emitpcode that conditionally emits
2609           the origin of the following pCode (useful for debugging SDCC)
2610         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2611         * (createDefmap): fixed handling of LFSR for --optimize-df
2612
2613 2005-08-02 Borut Razem <borut.razem AT siol.net>
2614
2615         * device/lib/Makefile.in: pic16 libraries build enabled since
2616           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2617
2618 2005-08-02 Raphael Neider <rneider AT web.de>
2619
2620         * src/pic16/gen.c (genPackBits): removed deprecated warning
2621         * (genGenPointerSet): fixed bitfield detection
2622
2623 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2624
2625         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2626
2627 2005-07-31 Raphael Neider <rneider AT web.de>
2628
2629         * device/lib/pic16/libdev/pic18f458.c,
2630           device/include/pic16/pic18f458.h: added missing T0CONbits
2631
2632 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2633
2634         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2635
2636 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2637
2638         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2639
2640 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2641
2642         * device/include/mcs51/at89c51ed2.h: added.
2643
2644 2005-07-23 Raphael Neider <rneider AT web.de>
2645
2646         * src/pic/gen.h: added emitpcode macro for debugging
2647         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2648           and replace by macro adding debug information on demand
2649         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2650         * (gencjne): tried to fix; replaced with correct (slower) code
2651         * (gen{Unp,P}ackBits): fixed single bit access
2652         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2653         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2654           previous instruction
2655         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2656           register has to be handled with care (forbidding movement
2657           of assignments/uses, removing assignments completely, ...)
2658         * (pCodeOptime2pCodes): make use of regIsSpecial
2659         * added lots of debugging output (commented out)
2660         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2661           from being reused as result UNLESS it is known to work
2662
2663 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2664
2665         * support/Util/dbuf.h: include <stddef.h> for size_t
2666         * .version: changed to version 2.5.2
2667
2668 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2669
2670         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2671
2672 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2673
2674         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2675           (genModOneByte): removed needless psha/pula
2676
2677 2005-07-22 Raphael Neider <rneider AT web.de>
2678
2679         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2680           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2681         * src/pic/gen.c (resolveIfx): do not "invent" labels
2682         * (genSkipc): changed to positive logic
2683         * (genSkipCond): removed as no longer needed
2684         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2685           backport from PIC16
2686         * (genLeftShift): check operands are in different registers
2687         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2688           INCF does not update CARRY...
2689         * src/pic/main.c: fixed _linkCmd
2690         * src/pic/pcode.c (unlinkpCode): added inactive code
2691         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2692           alive (do not assign result and operand overlapping registers)
2693
2694 2005-07-22 Raphael Neider <rneider AT web.de>
2695
2696         * src/pic/device.c (dump_sfr): replaced register declaration with
2697           call to emitSymbolToFile() to avoid duplicate symbols
2698         * (assignRelocatableRegisters): do not declare external symbols
2699         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2700           right (take size of type, not etype)
2701         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2702         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2703         * (packRegsForAccUse): disabled assignment of WREG as
2704           the result reg to prevent occurence of just fixed #1235003,
2705           fixes #1242954
2706         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2707           symbols (avoids duplicate symbols in .asm file)
2708         * (pic14emitRegularMap): use emitSymbolToFile()
2709         * src/pic/gen.c (aopOp): fixed spillLocation handling
2710         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2711         * (genDataPointerSet): removed unneccessary variables/output
2712
2713 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2714
2715         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2716         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2717
2718 2005-07-21 Raphael Neider <rneider AT web.de>
2719
2720         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2721           architecture cannot handle them efficiently, fixes bug #1235003
2722         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2723           check for empty sets before using them (fixes bug #1232190)
2724
2725 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2726
2727         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2728           (lnksect2): generate warnings for memory overlap
2729         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2730           constseg to set the name of these segments so you can instruct the linker
2731           to place them in banks
2732         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2733         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2734           added code_seg and const_seg to options
2735         * src/SDCCglue.c (emitMaps): use options.const_seg,
2736           (createInterruptVect): put interrupt vectors in segment HOME,
2737           (glue): put HOME before static segment and put the main glue in HOME,
2738           (glue): use options.code_seg
2739         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2740         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2741           these segments so you can instruct the linker to place them in banks
2742           (linkEdit): use code_loc for HOME segment which should be the first
2743           segment in code memory now
2744         * src/SDCCmem.c: fixed more stuff like bug 1238386
2745         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2746           (changePointer): don't change function pointers to code pointers for
2747           banked functions,
2748           (compareType): added exceptional check for banked function pointers
2749         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2750         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2751           after static in code memory
2752         * src/mcs51/gen.c: added aopLiteralLong prototype,
2753           (aopForSym): use getSize for functions,
2754           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2755           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2756           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2757           the segment,
2758           (genPcall): use call for literal function pointers and generate banked
2759           calls over the one trampoline so there's only one place for the user to
2760           modify according to his/hers hardware,
2761           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2762           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2763         * src/mcs51/main.c: added keyword banked,
2764           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2765         * support/Util/SDCCerr.c,
2766         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2767           needed for passing the bank and address to the trampoline
2768         * device/lib/mcs51/crtbank.asm: added for bankswitching
2769         * device/lib/mcs51/Makefile: added crtbank
2770
2771 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2772
2773         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2774           for fields at offset 0 of a struct or union as reported
2775           on 2005-07-07 in the developer mailing list.
2776
2777 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2778
2779         * src/SDCCmem.c: fixed bug 1238386
2780
2781 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2782
2783         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2784           (patch #1144962), added peephole 300, enabled 259.x
2785         * doc/sdccman.lyx: removed screenshot and provided link instead
2786
2787 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2788
2789         * doc/sdccman.lyx: added section about debugging with ddd
2790         * doc/figures/ddd_example.eps: screenshot of debugging session
2791
2792 2005-07-04 Raphael Neider <rneider AT web.de>
2793
2794         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2795           like CODE pointers, fixes #1115683
2796         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2797           call, fixes bugs #1232211, #1228110,
2798           fixed wrong casts to pCodeFlow from pCodeInstructions
2799
2800 2005-07-04 Raphael Neider <rneider AT web.de>
2801
2802         * src/pic/gen.c (popGet): changed assert to allow for
2803           bit operands
2804         * (popGetAddr): changed signature to provide
2805           an additional index, patched all call sites
2806         * (genCmpEq): handle literal-like operands correctly
2807         * (genAddrOf): added sanity checks on __code/__data pointers
2808         * (genAssign): added handling of symbols from __code section
2809         * (gencjne): do not generate code for comparisons whose result
2810           is neither stored nor used, fixes bug #1171114
2811         * (AccLsh, AccRsh): operate on operand instead of WREG
2812         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2813           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2814           by known count
2815         * rewrote complete shift-by-literal logic, commented unused
2816           functions out
2817         * (genConstPointerGet): get multiple bytes (if result size > 1),
2818           fixed handling of non-immediate addresses
2819         * (genPointerGet): handle CODE pointers like CONST pointers
2820         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2821         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2822           operand is to be treated as a literal or not
2823         * (mov2w,genPcall,genCmpEq),
2824           src/pic/genarith.c: use aop_isLitLike() to decide between
2825           literal/register contents
2826         * (addSign): added missing offset
2827         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2828           only emit comment in debug-mode,
2829           use {aop,op}_isLitLike throughout the file
2830         * src/pic/glue.c: fix initializers for pointers (work in progress)
2831         * src/pic/pcode.c (get_op): honor index on _const symbols
2832         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2833         * (dumppBlock): added pCode size estimation
2834         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2835           check for IS_SYMOP before OP_SYMBOL'ing
2836         * fixed indentation, compacted switch-statements
2837         * (allocReg): find free register and allocate it instead of
2838           allocating new registers all the time
2839         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2840           registers as its operands (necessary only for multibyte GETs)
2841
2842 2005-07-01 Raphael Neider <rneider AT web.de>
2843
2844         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2845           debugging .asm-output macros FENTRY + FEXIT
2846         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2847           way... I wonder...
2848         * (emitpComment): NEW, printf to pCode
2849         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2850           offset handling
2851         * (popGetAddr): NEW, variant of popGet to access an immediates
2852           high(er) bytes instead of the n'th byte of memory they reference,
2853           replaced popGet with popGetAddr where neccessary
2854         * (genDataPointerGet): reactivated and fixed implementation
2855         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2856           accesses
2857         * (genDataPointerSet): fixed multibyte assignments
2858         * (genpic14Code): fixed --i-code-in-asm handling
2859         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2860         * (genPlus): fixed index-out-of-bounds error
2861         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2862         * src/pic/ralloc.c: added debugging output macro FENTRY2
2863         * (spillThis): fixed indentation, enbraced for-body for clarity
2864         * (rematStr): commented out as now unused
2865         * (regTypeNum): commented out special spill case (overwrites
2866           arbitrary values)
2867         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2868
2869 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2870
2871         * doc/sdccman.lyx: documented sfr16/sfr32,
2872           added example for using storage class with function pointers
2873         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2874
2875 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2876
2877         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2878         * device/lib/_itoa.c,
2879         * device/lib/_ltoa.c: optimized codesize
2880         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2881           but don't know how to suppress the double warning.
2882         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2883         * support/Util/SDCCerr.c,
2884         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2885
2886 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2887
2888         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2889           fixed old K&R prototypes
2890         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2891         * device/lib/_gptrget.c,
2892         * device/lib/_gptrgetc.c,
2893         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2894           also new versions for small generic pointers and banked generic pointers
2895         * src/port.h: added const_name
2896         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2897         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2898         * src/SDCCcse.c (findPrevIc): check all associative operators
2899         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2900         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2901         * src/SDCCmem.c: updated comments,
2902           set far-space to 0 for pdata, results in optimized code
2903         * src/SDCCmem.h: added macro CONST_NAME
2904         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2905           moving the info into the highest bits, see also gptrget/gptrput
2906         * src/src.dsp: added sdcc.ico to project files
2907         * src/avr/gen.c (genCast): fixed bug 0x%d
2908         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2909         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2910           relation between ptr_type and DCL_TYPE,
2911           (genCast): fixed bug 0x%d
2912         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2913           (CODE)" for const_name
2914         * src/hc08/gen.c (genCast): fixed bug 0x%d
2915         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2916           (hc08_port): added "CONST (CODE)" for const_name
2917         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2918           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2919           between ptr_type and DCL_TYPE,
2920           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2921           operand* and took AOP() inside function so sfr-ness can be checked,
2922           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2923           new prototype,
2924           (genFunction, genEndFunction): optimized stack setup,
2925           (genMinus): optimized for literals with ending zeroes (in bytes),
2926           (genCast): fixed bug 0x%d
2927         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2928           (mcs51_port): added "CONST (CODE)" for const_name
2929         * src/mcs51/peeph.def: made rule 226 more generic
2930         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2931         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2932         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2933         * src/z80/main.c (z80_port): added NULL for const_name,
2934           (gbz80_port): added NULL for const_name
2935         * support/regression/tests/bug663539.c,
2936         * support/regression/tests/sfr16.c: new tests
2937
2938 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2939
2940         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2941
2942 2005-06-24 Raphael Neider <rneider AT web.de>
2943
2944         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2945           corrected typos...
2946         * device/include/pic16/signal.h: added USBIF
2947           and SIG_USB
2948
2949 2005-06-24 Raphael Neider <rneider AT web.de>
2950
2951         * device/lib/pic16/libdev/pic18f2455.c,
2952           device/include/pic16/pic18f2455.h: NEW
2953         * device/include/pic16/pic18fregs.h,
2954           device/lib/pic16/pics.all,
2955           src/pic16/device.c: added 18f2455
2956         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2957           device/include/pic16/{pic18f[68][567].h,usart.h}:
2958           replaced MULTIPLE_USARTS define with more relaible
2959           compatibility sfrs (for USART access)
2960
2961 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2962
2963         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2964           and the output asm file line is printed on two lines.
2965
2966 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2967
2968         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2969           BGT, BLE, BHI, and BLS instructions
2970         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2971           genCmpEq): removed
2972         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2973           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2974           fixes bug #1216342
2975         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2976
2977 2005-06-15 Raphael Neider <rneider AT web.de>
2978
2979         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2980         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2981         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2982           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2983           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2984
2985 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2986
2987         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2988           Marcel Telka in bug #1215704
2989
2990 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
2991
2992         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
2993           located in shared memory bank.
2994
2995 2005-05-31 Raphael Neider <rneider AT web.de>
2996
2997         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
2998           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
2999           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
3000
3001 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
3002
3003         * device/lib/_strncpy.c: fixed the fix
3004
3005 2005-05-26 Raphael Neider <rneider AT web.de>
3006
3007         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
3008           initializers with \0, bug #1208187
3009         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
3010           intializers with \0, bug #1208187
3011
3012 2005-05-26 Raphael Neider <rneider AT web.de>
3013
3014         * src/pic16/glue.c (pic16_printIvalChar): fixed string
3015           initializers with \0, bug #1208187
3016         * src/pic16/main.c (_process_pragma): added sanity checks
3017           for stack position and size, emit warnings when appropriate
3018
3019 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
3020
3021         * device/lib/_strncpy.c: fixed not filling with \0
3022
3023 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3024
3025         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
3026           createFunction),
3027         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
3028           compound_statement),
3029         * src/SDCCsymt.h,
3030         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
3031
3032 2005-05-24 Raphael Neider <rneider AT web.de>
3033
3034         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
3035
3036 2005-05-24 Raphael Neider <rneider AT web.de>
3037
3038         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
3039           TRISE definitions, closes bug #1162453
3040
3041 2005-05-22 Raphael Neider <rneider AT web.de>
3042
3043         * src/pic16/main.c (_process_pragma): check for missing
3044           arguments to pragmas code and udata
3045         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
3046           consistency fixes to match other headers (thanks to Jim Paris)
3047         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
3048
3049 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
3050
3051         * src/SDCCicode.c (isOperandEqual): fixed missing ;
3052
3053 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
3054
3055         * support/regression/tests/bug1198642.c: new test
3056         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
3057         * src/SDCCcse.c (findPrevIc): added comment, please have a look
3058         * support/scripts/resource.h,
3059         * support/scripts/resource.rc,
3060         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
3061         * support/scripts/sdcc.ico: added 32x32 icon
3062
3063 2005-05-18 Raphael Neider <rneider AT web.de>
3064
3065         * device/lib/pic16/libdev/pic18f*.c,
3066         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
3067           keywords to "__sfr" and "__at (X)"
3068         * device/include/pic16/pic18fregs.h: added pic18f4520
3069         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
3070           #1203088 (MPLAB compatibility)
3071
3072 2005-05-17 Raphael Neider <rneider AT web.de>
3073
3074         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
3075         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
3076         * device/lib/pic16/pics.all: added new devices
3077         * src/pic16/device.c: added support for pic18f4520
3078
3079 2005-05-16 Raphael Neider <rneider AT web.de>
3080         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
3081         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
3082         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
3083           convenience function for bit access
3084
3085 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
3086
3087         * device/lib/printf_large.c: fixed bug 1193299
3088         * support/regression/tests/bug1057979.c: added test %3.3s
3089
3090 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3091
3092         * device/include/mcs51/8051.h,
3093         * device/include/mcs51/8052.h: made parseable with lint
3094         * device/include/mcs51/lint.h: added include file for (sp)lint
3095         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
3096         * doc/cdbfileformat.lyx,
3097         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
3098
3099 2005-05-14 Raphael Neider <rneider AT web.de>
3100
3101         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
3102         * device/lib/pic16/libc/stdlib/itoa.c (new)
3103         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
3104         * device/lib/pic16/libio/Makefile: exclude subdir according to
3105           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
3106         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
3107         * src/pic16/gen.c (genFunction): prevent annoying warning
3108         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
3109           nameclashes on BeOS
3110         * support/cpp2/cppmain.c (cpp_output_string): new
3111         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
3112           fixes bug 1116802
3113
3114 2005-05-13 Borut Razem <borut.razem AT siol.net>
3115
3116         * src/SDCCmain.c (linkEdit): fixed bug 1195202
3117
3118 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3119
3120         * .version: changed to version 2.5.1; back to bleeding edge development
3121
3122 2005-05-11 Borut Razem <borut.razem AT siol.net>
3123
3124         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
3125           generate PDF version 1.3 documents
3126
3127 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3128
3129         * .version: changed to version 2.5.0
3130
3131 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3132
3133         * doc/sdccman.lyx: updated weblinks, index and smaller updates
3134
3135 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3136
3137         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
3138         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
3139         well as many smaller updates.
3140         * .version: changed to version 2.5.0-pre1
3141
3142 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3143
3144         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
3145
3146 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
3147
3148         * support/regression/tests/bug1185672.c: added
3149         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
3150           bug 1185672
3151         * src/mcs51/gen.c (genCall): added comments, made it look safer
3152         * src/mcs51/gen.c (genEndFunction): simplified
3153
3154 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
3155
3156         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
3157
3158 2005-04-14 Borut Razem <borut.razem AT siol.net>
3159
3160         * fixed bug 1045046 - SIGSEGV with really simple code?:
3161           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
3162           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
3163
3164 2005-04-14 Borut Razem <borut.razem AT siol.net>
3165
3166         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
3167           src/pic16/device.h: temporarily disabled experimental #inline pragma
3168           for 2.5.0 release
3169
3170 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
3171
3172         * device/include/z80/stdio.h,
3173         * device/include/z80/string.h: removed these highly incomplete files so
3174           SDCC can use the default ones in device/include/
3175
3176 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3177
3178         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
3179         gcc warning.
3180         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
3181         fix sdcpp warnings.
3182
3183 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3184
3185         * device/include/malloc.h: removed redundant __reentrant prototypes
3186         * device/lib/_mullong.c: added working xstack variant in asm (C version
3187           doesn't pass regression tests)
3188         * device/lib/bpx.c: used __data and made bpx char for mcs51
3189         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
3190           (createFunction): fixed bug with xstackPtr
3191         * src/SDCCcse.c: corrected comments
3192         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
3193           (killDeadCode, eBBlockFromiCode): removed unused code
3194         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
3195           corrected comments
3196         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
3197           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
3198           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
3199           (genModOneByte): fixed warning in MSVC
3200         * src/mcs51/main.c (): added comments
3201         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
3202
3203 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3204
3205         * src/SDCCmain.c (linkEdit): oops, changed one line too many
3206
3207 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
3208
3209         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
3210
3211 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
3212
3213         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
3214         characters arrays of larger size than the declared one.
3215
3216 2005-04-10 Borut Razem <borut.razem AT siol.net>
3217
3218         * src/pic/gen.c (genInline),
3219           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
3220           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
3221           (findNextInstruction), (findPrevInstruction),
3222           (findInstructionUsingLabel),
3223           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
3224         * src/pic/pcode.c (findLabel): added missing '\n'
3225         * src/src.dsp: added SDCCdwarf2.c to the project
3226
3227 2005-04-09 Borut Razem <borut.razem AT siol.net>
3228
3229         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
3230
3231 2005-04-08 Raphael Neider <rneider AT web.de>
3232
3233         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
3234           into the chain after a given one) and mergeDefmapSymbols (combine
3235           defmap entries for each symbol per pcode)
3236         * (createDefmap): have defmap entries merged in the end
3237         * (defmapReplaceSymRef): split defmap entries covering two accesses to
3238           a symbol before replacing one access type's symbol, merge symbols in
3239           the end (replacement symbol might already have an entry)
3240         * (assignValnums): keep reference to written WREG intact
3241
3242 2005-04-08 Raphael Neider <rneider AT web.de>
3243
3244         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
3245           Alpha)
3246
3247 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
3248
3249         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
3250         bytes
3251
3252 2005-04-07 Raphael Neider <rneider AT web.de>
3253
3254         * device/include/pic16/usart.h: added compatibility defines for
3255           devices with more than one USART
3256         * device/include/pic16/pic18f[68][567]20.h: activated above defines
3257
3258 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3259
3260         * device/lib/Makefile.in: updated for port specific include
3261
3262 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3263
3264         * support/regression/ports/mcs51/spec.mk: added mcs51 include
3265
3266 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3267
3268         * device/include/8051.h,
3269         * device/include/8052.h,
3270         * device/include/at89S8252.h,
3271         * device/include/at89c55.h,
3272         * device/include/at89x051.h,
3273         * device/include/at89x51.h,
3274         * device/include/at89x52.h,
3275         * device/include/mcs51reg.h,
3276         * device/include/reg51.h,
3277         * device/include/reg764.h,
3278         * device/include/regc515c.h,
3279         * device/include/sab80515.h: (re)moved these 12 files
3280         * device/include/mcs51/8051.h,
3281         * device/include/mcs51/8052.h,
3282         * device/include/mcs51/at89S8252.h,
3283         * device/include/mcs51/at89c55.h,
3284         * device/include/mcs51/at89x051.h,
3285         * device/include/mcs51/at89x51.h,
3286         * device/include/mcs51/at89x52.h,
3287         * device/include/mcs51/mcs51reg.h,
3288         * device/include/mcs51/reg51.h,
3289         * device/include/mcs51/reg764.h,
3290         * device/include/mcs51/regc515c.h,
3291         * device/include/mcs51/sab80515.h: and added them here
3292
3293 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3294
3295         * device/include/stdarg.h: changed SDCC specific keywords to double
3296           underlined form.
3297         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
3298           mcs51 and ds390.
3299         * device/include/hc08/mc68hc908gp32.h,
3300         * device/include/hc08/mc68hc908jb8.h,
3301         * device/include/hc08/mc68hc908jkjl.h,
3302         * device/include/hc08/mc68hc908qy.h: fixed comments
3303         * device/include/mcs51/README: updated
3304         * device/include/mcs51/c8051f120.h: added PINRSF
3305         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
3306         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
3307           amidst code. Also inline is not supported.
3308
3309 2005-04-06 Raphael Neider <rneider AT web.de>
3310
3311         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
3312         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
3313           callers stack/frame pointers
3314
3315 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3316
3317         * device/include/pic16/usart.h: added, missing in previous commit,
3318         * device/include/pic16/adc.h: fixed typo,
3319         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
3320         commit,
3321         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
3322         <p18fxxx.inc>
3323         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
3324         uninitialized because a bug appears with gplink
3325         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
3326         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
3327         complains for unrecognised option
3328
3329 2005-04-05 Raphael Neider <rneider AT web.de>
3330
3331         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
3332           structs as well (using memcpy)
3333         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
3334           on ISRs (GOTO has no label)
3335         * src/pic16/device.h: added OF_OPTIMIZE_DF
3336         * src/pic16/main.c: added compiler switch --optimize-df to enable the
3337           new data flow analysis/optimization
3338         * src/pic16/pcode.c: added (prototypes for and implementation of)
3339           dataflow analysis functions, fixed pCodeInstructions' inCond and
3340           outCond values, made RCALL a branch instruction
3341         * (pic16_unlinkpCode): keep C line if possible
3342         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
3343           C line moved if possible
3344         * (pic16_getRegFrompCodeOp): NEW, improved version of...
3345         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
3346           to use new pic16_getRegFrompCodeOp (works for more SFRs)
3347         * (pic16_BuildFlow): fixed skip instructions with label (did not start
3348           new flow)
3349         * (pic16_getJumptabpCode): NEW, needed in...
3350         * (LinkFlow): fixed handling of jumptables, calls and conditional
3351           branches
3352         * (pic16_InsertCommentAfter): NEW
3353         * (pic16_pCodeReplace): made verbose and flow preserving
3354         * (AnalyzeFlow): added call to data flow analysis
3355         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
3356         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
3357         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
3358
3359 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3360
3361         * src/SDCCast.c (decorateType): fixed bug #1105626
3362
3363 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
3364
3365         * device/include/asm/pic16/features.h,
3366         * pic18f*.h headers,
3367         * device/include/pic16/adc.h,
3368         * device/include/pic16/delay.h,
3369         * device/include/pic16/i2c.h,
3370         * device/include/pic16/malloc.h,
3371         * device/include/pic16/stdio.h,
3372         * device/include/pic16/stdlib.h,
3373         * device/include/pic16/string.h,
3374         * device/lib/pic16/libc/stdio/printf_tiny.c,
3375         * device/lib/pic16/libc/stdio/printf_small.c,
3376         * device/lib/pic16/libc/stdio/strmgpsim.c,
3377         * device/lib/pic16/libc/stdio/strmmssp.c,
3378         * device/lib/pic16/libc/stdio/strmusart.c,
3379         * device/lib/pic16/libc/stdio/vfprintf.c,
3380         * device/lib/pic16/libc/stdlib/ltoa.c,
3381         * device/lib/pic16/libc/stdlib/putchar.c,
3382         * device/lib/pic16/libc/stdlib/x_ftoa.c,
3383         * device/lib/pic16/libc/stdlib/memchrpgm.c,
3384         * device/lib/pic16/libc/stdlib/memchrram.c,
3385         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
3386         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
3387         * device/lib/pic16/libio/adc/adcbusy.c,
3388         * device/lib/pic16/libio/adc/adcread.c,
3389         * device/lib/pic16/libio/adc/adcsetch.c,
3390         * device/lib/pic16/libio/usart/ubaud.c,
3391         * device/lib/pic16/libio/usart/ubusy.c,
3392         * device/lib/pic16/libio/usart/udrdy.c,
3393         * device/lib/pic16/libio/usart/uopen.c,
3394         * device/lib/pic16/libio/usart/uputc.c,
3395         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
3396         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
3397         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
3398         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
3399         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
3400         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
3401         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
3402         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
3403         specific keywords to double underlined form,
3404         * device/lib/pic16/libc/Makefile.rules,
3405         * device/lib/pic16/libsdcc/Makefile.rules,
3406         * device/lib/pic16/libm/Makefile,
3407         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
3408         to compile with C standard set in Makefile.common
3409         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
3410         rand.c and crc.c in compilation process,
3411         * device/lib/pic16/libsdcc/int/divuint.c,
3412         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
3413         `c' from signed to unsigned,
3414         * device/lib/pic16/startup/crt0.c,
3415         * device/lib/pic16/startup/crt0i.c,
3416         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
3417         keywords to double underlined form, bug fixes in _do_cinit function
3418         which prevented the correct initialization of the .idata segment,
3419         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
3420         core to enter a infinite loop
3421         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
3422
3423 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3424
3425         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
3426
3427 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3428
3429         * device/include/Makefile.in: add support for hc08 subdirectory
3430         * device/include/hc08/: new subdirectory
3431         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
3432         Lucas Loizaga, thanks!
3433         * device/include/hc08/mc68hc908qy.h,
3434         * device/include/hc08/mc68hc908gp32.h,
3435         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
3436         their own directory. Changed internal macro names to use the compiler
3437         reserved namespace. Changed SDCC specific keywords to double
3438         underlined form.
3439         * device/include/math.h,
3440         * device/include/malloc.h,
3441         * device/include/stdarg.h,
3442         * device/include/stdbool.h
3443         * device/include/string.h,
3444         * device/include/tinibios.h,
3445         * device/include/ds400rom.h,
3446         * device/include/8051.h,
3447         * device/include/8052.h,
3448         * device/include/80c51xa.h,
3449         * device/include/at89c55.h,
3450         * device/include/at89S8252.h,
3451         * device/include/at89x51.h,
3452         * device/include/at89x52.h,
3453         * device/include/ds80c390.h,
3454         * device/include/reg764.h,
3455         * device/include/regc515c.h,
3456         * device/include/sab80515.h,
3457         * device/include/mcs51/c8051f000.h,
3458         * device/include/mcs51/c8051f018.h,
3459         * device/include/mcs51/c8051f020.h,
3460         * device/include/mcs51/c8051f040.h,
3461         * device/include/mcs51/c8051f060.h,
3462         * device/include/mcs51/c8051f120.h,
3463         * device/include/mcs51/c8051f300.h,
3464         * device/include/mcs51/c8051f310.h,
3465         * device/include/mcs51/c8051f320.h,
3466         * device/include/mcs51/c8051f330.h,
3467         * device/include/mcs51/c8051f350.h,
3468         * device/include/z180.h: Changed SDCC specific keywords to double
3469         underlined form.
3470
3471 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3472
3473         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3474         18F4455,
3475         * (pic16_assignConfigWordValue): disable testing of configuration
3476         register value with config mask,
3477         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3478         function with port->fun_prefix,
3479         * (genFunction): when generating a naked interrupt function never
3480         create an absolute segment placed in interrupt vector address, place
3481         the actual interrupt function at IVA instead, when an interrupt
3482         function is generated with unspecified interrupt then do not create
3483         the absolute section,
3484         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3485         code for generating a call to generic pointer get/put function with
3486         a call to function pic16_callGenericPointer(),
3487         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3488         the call to the generic pointer get/put functions with prefixing the
3489         function name with port->fun_prefix,
3490         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3491         * src/pic16/main.c (_process_pragma): prefix function with
3492         port->fun_prefix,
3493         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3494         calling assembler, old 18Fxxxx macro is deprecated,
3495         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3496         PC_ASMDIR in while condition,
3497         * (findInstruction): add PC_ASMDIR in while condition,
3498         * (buildCallTree): prefix main with port->fun_prefix,
3499         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3500         identifier for variable with banked access in instructions BTFSS,
3501         BTFSC, BCF, BSF, BTG
3502         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3503         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3504         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3505         perform optimization when enviroment variable NO_REG_OPT is set,
3506         * (insideLRBlock): NEW, return 1 if register is inside an
3507         INF_LOCALREGS block,
3508         * (RemoveRegFromLRBlock): remove a register that is completely
3509         eliminated by register optimization, but it is still left in local
3510         register store/restore in/from stack block,
3511         * (Remove2pcodes): after removing register, check to see if it
3512         should be removed from local register store/restore in/from stack
3513         block,
3514         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3515         DUMMY_READ_VOLATILE,
3516
3517         * device/include/pic16/adc.h: minor prototype modifications and
3518         update,
3519         * device/include/pic16/malloc.h: added GPL notice various
3520         modifications,
3521         * device/include/pic16/stdint.h: NEW, standard header for ints
3522         * device/include/pic16/delay.h: NEW, header for delay functions,
3523         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3524         delay1mtcy,
3525         * device/include/pic16/signal.h: NEW, header providing helper macros
3526         for implementing signal handlers,
3527         * device/include/pic16/stdio.h: added prototypes for functions,
3528         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3529         prototypes for stdin and stdout, added macro PUTCHAR to
3530         automatically implement putchar function prototype,
3531         * device/include/pic16/usart.h: modified and updated USART library,
3532         * device/lib/pic16/libio/adc/,
3533         * device/lib/pic16/libio/i2c: some modifications to improve library
3534         performance,
3535         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3536         family of functions,
3537         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3538         family of functions and other sources,
3539         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3540         of the PIC18Fxx[28] devices,
3541         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3542         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3543         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3544         _do_cinit function, because the previous failed when local variables
3545         where not placed in the same memory bank,
3546         * device/lib/pic16/libsdcc/char/: various modifications to improve
3547         library performance,
3548         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3549         information on the new functions of the c library and more...
3550
3551 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3552
3553         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3554
3555 2005-03-26 Raphael Neider <rneider AT web.de>
3556
3557         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3558           if condition == CARRY)
3559         * (genCmp): adapted to new genSkipc semantics
3560         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3561           on rIfx (genCmp was broken)
3562
3563 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3564
3565         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3566         * src/z80/main.c (_keywords[]),
3567         * src/SDCCglobal.h (struct options),
3568         * src/SDCC.y,
3569         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3570         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3571         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3572         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3573         always available in leading double underscore form. The C99 support is
3574         mostly missing, but it's a start.
3575         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3576         reserved identifier "__data".
3577
3578 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3579
3580         * src/mcs51/peeph.def: fixed bug 1170013
3581
3582 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3583
3584         * device/include/mcs51reg.h: fixed bug 842007
3585
3586 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3587
3588         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3589         last time.
3590
3591 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3592
3593         * src/port.h (struct PORT),
3594         * src/avr/ralloc.c (avr_assignRegisters),
3595         * src/avr/main.c,
3596         * src/ds390/ralloc.c (ds390_assignRegisters),
3597         * src/ds390/main.c,
3598         * src/hc08/ralloc.c (hc08_assignRegisters),
3599         * src/hc08/main.c,
3600         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3601         * src/mcs51/main.c,
3602         * src/pic/ralloc.c (pic14_assignRegisters),
3603         * src/pic/main.c,
3604         * src/pic16/ralloc.c (pic16_assignRegisters),
3605         * src/pic16/main.c,
3606         * src/xa51/ralloc.c (xa51_assignRegisters),
3607         * src/xa51/main.c,
3608         * src/z80/ralloc.c (z80_assignRegisters),
3609         * src/z80/ralloc.h,
3610         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3611         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3612         * src/SDCCcse.h,
3613         * src/SDCCdflow.c (computeDataFlow),
3614         * src/SDCCdflow.h,
3615         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3616         * src/SDCCloop.h,
3617         * src/SDCCcflow.c (*),
3618         * src/SDCCcflow.h,
3619         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3620         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3621         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3622         immedDom() returning wrong block; probably fixes bug #1160833)
3623
3624 2005-03-20 Borut Razem <borut.razem AT siol.net>
3625
3626         * support/scripts/inc2h.pl: WIN32 port
3627
3628 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3629
3630         * device/lib/makefile.in: added abs.c and labs.c
3631
3632 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3633
3634         * device/include/stdint.h: added
3635         * device/lib/abs.c: added
3636         * device/lib/labs.c: added
3637         * device/include/stdlib.h: added abs() and labs() prototypes
3638         * device/lib/libsdcc.lib: added abs and labs
3639         * device/include/float.h,
3640         * device/lib/_fsmul.c,
3641         * device/lib/printf_fast.c,
3642         * device/lib/printf_tiny.c: updated comments
3643
3644 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3645
3646         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3647         bug #1164313
3648
3649 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3650
3651         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3652         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3653
3654 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3655
3656         * device/lib/printf_large.c: removed inline assembly for portability and
3657           readability. Use printf_fast if speed or size are more important.
3658         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3659         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3660
3661 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3662
3663         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3664         prevent compiler warning
3665
3666 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3667
3668         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3669         moved to level 0 and declared as static. Also they are explicit
3670         placed in access bank. This was necessery because some times they
3671         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3672         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3673         optimizations. Currently only compare to unsigned char is implemented,
3674         * src/pic16/gen.c: added fReturnIdx array,
3675         * (struct resolvedIfx) is moved to gen.h and made public,
3676         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3677         * (aopForSym): added an optimization to directly store in stack of
3678         the operand of a SEND iCode,
3679         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3680         but as registers instead (AOP_REG) using the fReturnIdx array,
3681         * (pic16_freeAsmop): remove the freed register from the
3682         _G.sregsAlloc field,
3683         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3684         a compare of 'WREG',
3685         * (pic16_popGetTempRegCond): changed function prototype, now
3686         function takes also a bitVector argument v which holds the current
3687         set of registers that are allocated for stack access by aopForSym,
3688         registers allocated in aopForSym for accessing stack symbols are not
3689         any more part of the functions usedRegs field,
3690         * (genCall): some times aopOp is called for a stack variable to be
3691         send, aopForSym might perform the push, if this is true make sure
3692         that genCall doesn't push the variable twice by testing _G.resDirect,
3693         * (genFunction): changed testing for unspecified interrupt number
3694         from 256 to INTNO_UNSPEC,
3695         * modified selection scheme of frame pointer generation. Previously
3696         if function did use local registers a frame pointer was generated,
3697         now a frame pointer is generated only if function has arguments
3698         (that need PLUSW2 register access), or has stack arguments, or the
3699         compiler is not instructed to omit the frame pointer,
3700         * (genEndFunction): before restoring local registers that were saved
3701         in the function preamble, also restore the registers that *might*
3702         have been allocated for stack access,
3703         * (genRet): removed some old comments,
3704         * (genCmp, the active (RN's) version): added a call to the
3705         pic16_genCmp_special function to perform the compare with a more
3706         robust and optimized way,
3707         * (genInline): a feature has been added in inline code generation,
3708         which allows a wildcard variable substitution when writing inline
3709         assembly. Code is incomplete and experimental therefore undocumented,
3710         * (genCast): changed order of aopOp for result and right to allow
3711         aopForSym to directly load the result if possible,
3712         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3713         perform an optimized compare on some selected special occasions,
3714         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3715         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3716         generate an IVT any more,
3717         * src/pic16/main.c (pic16_optionsTable): added command line option
3718         --optimize-cmp,
3719         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3720         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3721         macros,
3722         * src/pic16/NOTES: Raphael Neider added in list of active developers
3723         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3724         jumptable_end to prevent bug #,
3725         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3726         inCond and outCond fields,
3727         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3728         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3729         turn off register spilling,
3730         * (packRegsForOneUse): synced with other ports' versions although it
3731         is not used currently,
3732         * (pic16_packRegisters): added an optimization while reading
3733         structure bitfields, some registers may be saved (malloc code is
3734         decreased by 80 bytes)
3735
3736 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3737
3738         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3739         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3740         this can be optimized more?
3741
3742 2005-03-10 Raphael Neider <rneider AT web.de>
3743
3744         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3745           genNearPointerGet): (hopefully) fixed access to bitfields via
3746           pointers (p->bitN = x; and x = p->bitN; failed)
3747
3748 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3749
3750         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3751
3752 2005-03-09 Raphael Neider <rneider AT web.de>
3753
3754         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3755
3756 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3757
3758         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3759         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3760           (regTypeNum): set REG_BIT type if necessary
3761         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3762         * support/regression/tests/critical.c: check bug 1144613
3763
3764 2005-03-02 Raphael Neider <rneider AT web.de>
3765
3766         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3767
3768 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3769
3770         * src/avr/ralloc.c (serialRegAssign),
3771         * src/ds390/ralloc.c (serialRegAssign),
3772         * src/hc08/ralloc.c (serialRegAssign),
3773         * src/mcs51/ralloc.c (serialRegAssign),
3774         * src/pic/ralloc.c (serialRegAssign),
3775         * src/pic16/ralloc.c (serialRegAssign),
3776         * src/xa51/ralloc.c (serialRegAssign),
3777         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3778
3779 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3780
3781         * src/SDCCast.c (decorateType): fixed bug 1124787
3782
3783 2005-02-20 Hubert Sack <sack AT digiplan.de>
3784         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3785
3786         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3787         patch #1121755
3788
3789 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3790
3791         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3792         to keep the correct label reference count when adding/removing references
3793         to labels. A peephole file using this is appended to patch #1144962.
3794
3795 2005-02-14 Raphael Neider <rneider AT web.de>
3796
3797         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3798         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3799         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3800           retrievals of result operand's value on assignment
3801
3802 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3803
3804         * device/include/pic16/string.h: modified prototype for memccpy()
3805         to memccpy(void *, void *, char, size_t)
3806         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3807         check whether to omit frame pointer or not,
3808         * (genInline): convert all occurences of "\n" to LF in inline
3809         assembler blocks, this helps formatting the inline text,
3810         * (pic16_loadFSR0): modified prototype,
3811         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3812         removed some 8051 legacy code,
3813         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3814         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3815         before allocating temporary registers in functions,
3816
3817 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3818
3819         * support/regression/tests/bitvars.c: corrected the "fix"
3820
3821 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3822
3823         * support/regression/tests/bitvars.c,
3824         * support/regression/tests/bitwise.c,
3825         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3826
3827 2005-02-10 Raphael Neider <rneider AT web.de>
3828
3829         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3830           different size for Alpha
3831         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3832
3833 2005-02-09 Raphael Neider <rneider AT web.de>
3834
3835         * src/SDCC.lex(doPragma) : save and restore warning options as well
3836           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3837         * have #pragma less_pedantic set the errorlevel to WARNING
3838           (fixes #1117001)
3839         * (cloneOptimize) : fixed wrong malloc's size
3840         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3841           facilitate correct handling of #pragma (save|restore)
3842
3843 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3844
3845         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3846
3847 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3848
3849         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3850
3851 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3852
3853         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3854
3855 2005-02-02 Raphael Neider <rneider AT web.de>
3856
3857         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3858         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3859         * (pic16_storeForReturn): fixed to allow returning function pointers
3860         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3861         * device/include/pic16/{stddef.h,stdbool.h}: added
3862
3863 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3864
3865         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3866
3867 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3868
3869         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3870         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3871          appeared to be required
3872
3873 2005-01-31 Borut Razem <borut.razem AT siol.net>
3874
3875         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3876           include/mcs51 and include/z80 directories to the package
3877
3878 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3879
3880         * src/hc08/gen.c (genFunction): fixed bug #1112752
3881
3882 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3883
3884         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3885
3886 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3887
3888         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3889
3890 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3891
3892         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3893
3894 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3895
3896         * device/include/c8051fxxx.h: removed these 6 files
3897         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3898
3899 2005-01-26 Raphael Neider <rneider AT web.de>
3900
3901         * src/pic16/gen.c (genAssign): fixed assignment from longs
3902           in codespace (were cut to three bytes)
3903         * (genDummyRead): implemented (except for CODESPACE...),
3904           fixed bug #1108575
3905         * src/pic16/glue.c (emitStatistics): beautified
3906         * device/lib/pic16/libm/Makefile: added include path
3907
3908 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3909
3910         * src/z80/gen.c (aopPut): fixed bug #1103902
3911
3912 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3913
3914         * device/lib/expf.c: fixed bug #1095792
3915
3916 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3917
3918         * device/lib/pic16/libm: added Math library sources
3919
3920 2005-01-24 Raphael Neider <rneider AT web.de>
3921
3922         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3923           to enable upcast to pCodeOpReg2 (there is no type tag to
3924           differenciate the two and pic16_popGet2p cast into PCOR2)
3925         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3926           (sizeof(sectNames) changed to sizeof(sectName))
3927           Both patches fix segfaults under MinGW.
3928
3929 2005-01-23 Raphael Neider <rneider AT web.de>
3930
3931         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3932           Safe_[mc]?alloc()'ed variables
3933         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3934           of (byte sized) temporaries (assign them to WREG for now)
3935         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3936           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3937           this might fix SIGSEGVs on MinGW...
3938         * src/SDCCopt.c (killDeadCode): restored original behaviour
3939           (volatile operands might get thrown away though)
3940
3941 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3942
3943         * src/pic16/gen.c: fixed bug #1106975,
3944         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3945         pointer update, INTCON is saved, global interrupts are disabled and
3946         restored after updateing TOS.
3947         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3948         * added function attribute 'shadowregs' to take advantage of shadow
3949         registers,
3950         * added function attribute 'wparam' as an alternative to the wparam
3951         pragma,
3952         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3953         user declares a non-ISR function as 'shadowregs',
3954         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3955
3956 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3957
3958         * .version: bumped version number to 2.4.8
3959         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3960         pic16 port,
3961         * device/lib/pic16/libio/i2c/: I2C module support library,
3962         * device/include/pic16/i2c.h: I2C support library header,
3963         * device/lib/pic16/libc/stdio/: standard IO support sources,
3964         * (printf_small.c): printf_small() source, supports float print,
3965         * (printf_tiny.c): printf_tiny() source, does not support floats,
3966         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3967         enable global optimizations for entire library source, other
3968         Makefiles in the source tree are also modified to reflect this,
3969         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3970         function,
3971         * doc/sdccman.lyx: updated to reflect new changes,
3972         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3973         sym->onStack if-case,
3974         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3975         sbit, idata, _idata, xdata, _xdata,
3976         * added pragma library, to link an external library, (see doc),
3977         * removed command line options, --pomit-config-words, --pomit-ivt,
3978         --pleave-reset-vector,
3979         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3980         when calling assembler to reflect memory model used, also define
3981         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3982         reflect stack model used,
3983         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3984         on stack return NULL,
3985
3986 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3987
3988         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
3989           of the operands is volatile. Fixes #1020220
3990
3991 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3992
3993         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
3994         * (OptimizeRegUsage): make sure that there is really no other flow where
3995           the first pCode is used
3996
3997 2005-01-22 Raphael Neider <rneider AT web.de>
3998
3999         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
4000           to fix #1106967 (pCode->seq are not set up correctly)
4001
4002 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4003
4004         * src/SDCCglue.c (glue): make sure code area is declared before the
4005         static initialization area.
4006
4007 2005-01-21 Raphael Neider <rneider AT web.de>
4008
4009         * device/lib/Makefile.in: fixed test for pic16 install dir
4010         * device/lib/pic16/*/Makefile*: modified compile flags to enable
4011           optimizations
4012         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
4013           added --optimize-goto compiler switch and pragma wparam documentation
4014         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
4015         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
4016           and PRODH closing bug #1071770 (peephole optimizer)
4017
4018 2005-01-19 Raphael Neider <rneider AT web.de>
4019
4020         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
4021           cmdLine buffers (used when calling sdcpp...) are large enough
4022           (MAX_PATH=256 truncates arguments leading to system halts when
4023           used in MinGW...)
4024         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
4025         * (genUminus): rewritten to for efficiency
4026         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
4027           used uninitialized in some cases)
4028         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
4029           copy the third byte from the int -- now assumes 0x80 (data memory)
4030         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
4031           operands (genAddLit expects the iCode's operands to swapped as
4032           well), fixed leftover bytes (crashed for short left operands)
4033         * (pic16_genMinusDec): performance improvements, removed false
4034           PIC14 emitSKPNCs
4035         * (pic16_genMinus): fixed to cope with differently sized operands
4036         * src/pic16/glue.c (pic16_glue): added new banksel optimization
4037           for --obanksel > 1
4038         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
4039         * src/pic16/graph.[ch]: implementation of directed graphs, used by
4040           new banksel optimization
4041         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
4042           analysis for temporary registers (segfaults...)
4043         * src/pic16/peeph.def: added rule
4044
4045 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
4046
4047         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
4048         which converts a float number to its ASCII representation
4049         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
4050         functions to convert the fractional and integer part of a float to ASCII,
4051         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
4052         realloc.c): added _MALLOC_SPEC to explicit place variables in data
4053         ram
4054         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
4055         _STATMEM macros,
4056         * device/include/pic16/adc.h: added GPL info,
4057         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
4058         a pCodeOp as tested operand,
4059         * (genNearPointerGet): optimized bit testing, does not use
4060         intermediate register for bit value, test directly instead with
4061         BTFSS, BTFSC, works only for single bits,
4062         * (genpic16Code): dump the name of the iCode in the asm,
4063         * src/pic16/ralloc.c (decodeOp): removed static declaration and
4064         renamed to pic16_decodeOp,
4065         * (serialRegAssign): do not allocate a temporary register for iCode
4066         sequences that test a single bit for 1/0
4067
4068 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
4069
4070         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
4071         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
4072         access stack and frame pointers. They are initially assigned to
4073         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
4074         accessing SFRs. Updated all occurences of modification of stack or
4075         frame pointer in gen.c and pcode.c,
4076         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
4077         assigning of a literal value to pointers,
4078         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
4079         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
4080         selected
4081
4082 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
4083
4084         * doc/sdccman.lyx: update documentation about stack pragma, added
4085         some info for stack memory models
4086
4087 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4088
4089         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
4090
4091 2005-01-08 Raphael Neider <rneider AT web.de>
4092
4093         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
4094           udata sections to fix bug #1097823
4095
4096 2005-01-05 Raphael Neider <rneider AT web.de>
4097
4098         * src/pic16/gen.c (genGenericShift): added handling of differently
4099           sized left operand and result
4100
4101 2005-01-04 Raphael Neider <rneider AT web.de>
4102
4103         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
4104         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
4105           to hold the condition bit)
4106         * added new version of genCmp (old code available via #define)
4107         * added new version of genShiftLeft/genShiftRight in a generic
4108           way, now supports shifting by negative values
4109         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
4110           shiftCount (expected by genGenericShift)
4111         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
4112         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
4113           dump
4114         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
4115           is an invalid literal too...)
4116
4117 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
4118
4119         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
4120         from Raphael Neider,
4121         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
4122         for 8-bit literals. This fixes some literal operands which are sign
4123         extended to 16-bits ints when instruction needs only 8-bits.
4124
4125 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
4126
4127         * device/lib/logf.c: added mcs51 assembly version
4128         * device/lib/expf.c: added mcs51 assembly version
4129         * device/lib/_logexpf.c: new shared asm code for expf and logf
4130         * device/include/math.h: add defines for assembly math library
4131         * device/lib/Makefile.in: build new _logexpf.c
4132         * device/lib/libfloat.lib: use new _logexpf.c
4133
4134 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4135
4136         * src/pic/device.c
4137         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
4138           device types which have less than 0x7f registers.
4139
4140 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4141
4142         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
4143
4144 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4145
4146         * device/lib/printf_fast.c: only build on supported arch.
4147         * device/lib/printf_tiny.c: only build on supported arch.
4148         * device/lib/printf_fast_f.c: only build if asm float lib
4149         * device/lib/_fsget1arg.c: only build if asm float lib
4150         * device/lib/_fsget2args.c: only build if asm float lib
4151         * device/lib/_fsnormalize.c: only build if asm float lib
4152         * device/lib/_fsreturnval.c: only build if asm float lib
4153         * device/lib/_fsrshift.c: only build if asm float lib
4154         * device/lib/_fsswapargs.c: only build if asm float lib
4155         * device/include/stdio.h: don't provide print_fast,
4156           print_fast_f, print_tiny prototypes if --xstack used
4157
4158 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
4159
4160         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
4161         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
4162           to the SOURCES
4163
4164 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4165
4166         * device/lib/printf_fast_f.c: same as printf_fast, but
4167           with floating point enabled
4168         * device/lib/printf_fast.c: minor tweaks
4169         * device/include/stdio.h: add printf_fast_f
4170
4171 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4172
4173         * src/SDCCmain.c: make --float-reent default for mcs51
4174         * device/lib/_fsadd.c: added mcs51 assembly version
4175         * device/lib/_fssub.c: added mcs51 assembly version
4176         * device/lib/_fsmul.c: added mcs51 assembly version
4177         * device/lib/_fsdiv.c: added mcs51 assembly version
4178         * device/lib/_fseq.c: added mcs51 assembly version
4179         * device/lib/_fsneq.c: added mcs51 assembly version
4180         * device/lib/_fsgt.c: added mcs51 assembly version
4181         * device/lib/_fslt.c: added mcs51 assembly version
4182         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
4183         * device/lib/Makefile.in: add _fscmp to build
4184         * device/lib/libfloat.lib: add _fscmp to build
4185
4186 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4187
4188         * device/lib/_fs2slong.c: added mcs51 assembly version
4189         * device/lib/_fs2sint.c: added mcs51 assembly version
4190         * device/lib/_fs2schar.c: added mcs51 assembly version
4191         * device/lib/_fs2ulong.c: added mcs51 assembly version
4192         * device/lib/_fs2uint.c: added mcs51 assembly version
4193         * device/lib/_fs2uchar.c: added mcs51 assembly version
4194         * device/lib/_slong2fs.c: added mcs51 assembly version
4195         * device/lib/_sint2fs.c: added mcs51 assembly version
4196         * device/lib/_schar2fs.c: added mcs51 assembly version
4197         * device/lib/_ulong2fs.c: added mcs51 assembly version
4198         * device/lib/_uint2fs.c: added mcs51 assembly version
4199         * device/lib/_uchar2fs.c: added mcs51 assembly version
4200         * device/include/float.h: added #define to select asm vs c
4201
4202 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
4203
4204         * device/lib/printf_fast.c: improvements to float output
4205         * device/include/float.h: add defines for assembly float library
4206         * device/lib/_fsget1arg.c: receive 1 float arg
4207         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
4208         * device/lib/_fsnormalize.c: normalize a float
4209         * device/lib/_fsreturnval.c: return float, various helper routines
4210         * device/lib/_fsrshift.c: right shift a float's mantissa
4211         * device/lib/_fsswapargs.c: swap 2 floats
4212         * device/lib/Makefile.in: build these 6 new files for mcs51
4213         * device/lib/libfloat.lib: add these 6 files to the library
4214
4215 2004-12-26 Borut Razem <borut.razem AT siol.net>
4216
4217         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
4218           built by gcc 3.4.2
4219
4220 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
4221
4222         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
4223           and fully reentrant and register bank neutral.
4224         * device/lib/printf_fast.c: added float (not enabled by default),
4225           added compact/slower integer (also not enabled by default),
4226           improved size/speed of fast integer code, other minor changes
4227         * device/include/stdio.h, device/lib/Makefile.in,
4228           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
4229
4230 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
4231
4232         * src/pic16/pcode.c: declaring variables other than at the start of a
4233           block is not supported in C by VC6.
4234
4235 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
4236
4237         * applied a previous patch from Raphael Neider that wasn't included
4238         in the previous commits, which fixes infinite loops within jumptable
4239         improvements,
4240         * made some fixes that previous patches introduced
4241
4242 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
4243
4244         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
4245         that fixes an issue with AOP_PCODE asmop's offset,
4246         * (pic16_popCopyReg): update instance field too,
4247         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
4248         function of pic port,
4249         * (genCmp, genAnd, genAssign),
4250         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
4251
4252 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
4253
4254         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
4255         variables initial values to idata section,
4256         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
4257         variables in some functions. This utilizes parmBytes field of iCode
4258         structure to hold the offset of the variable in stack. (might be
4259         able to use the stack field too?)
4260         * applied patch from Raphael Neider # ### , # ###
4261         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
4262         variable initial values in idata section,
4263         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
4264         for static variables with initial value
4265         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
4266         applied fix in while loop from Raphael Neider.
4267
4268 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
4269
4270         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
4271         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
4272         * src/ds390/ralloc.c (serialRegAssign): spill bits
4273         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
4274         * support/Util/SDCCerr.c,
4275         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
4276         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
4277         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
4278
4279 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
4280
4281         * device/include/sdcc-lib.h: inserted LGPL, added includes
4282           asm/ds390/features.h and asm/mcs51/features.h
4283         * device/include/asm/default/features.h,
4284         * device/include/asm/gbz80/features.h,
4285         * device/include/asm/z80/features.h: added empty _AUTOMEM
4286           and _STATMEM
4287         * device/include/asm/ds390/features.h,
4288         * device/include/asm/mcs51/features.h: added files with defines for
4289           _AUTOMEM and _STATMEM indicating automatic and static storage class
4290         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
4291         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
4292         * src/SDCCicode.c (geniCodeCast),
4293         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
4294         * src/SDCCloop.c (loopInduction): removed unused variable lr
4295         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
4296           to convertToFcall to include char modulo (RFE 1065037), added check
4297           if left operand is unsigned and use abs of literal value
4298         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
4299           as it doesn't work after conversion from peephole.def to peephole.rul
4300         * src/mcs51/gen.c (toBoolean): added check for size,
4301           (genModOneByte): optimized code for signed char modulo a literal
4302           power of 2 (thanks to Hubert Sack),
4303           (genRRC): removed unnecessary "clr c",
4304           (genRLC): replaced "add a,acc" with cheaper "rlc a"
4305         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
4306           jump optimization,
4307           swapped rules 256.c and 256.d,
4308           extended 256.d by using new multiple checks (thanks Erik),
4309           added rules 256.e and 256.f,
4310           updated rule 261.a and 261.b to new generated code
4311         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
4312
4313 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4314
4315         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
4316           induction related bugs, including first part of bug #1074377
4317
4318 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
4319
4320         * applied patch from bug-report #1076292,
4321         * applied patches for genAnd and Goto-optimizations for Raphael
4322         Neider,
4323         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
4324         dump a less iCode information,
4325         * src/pic16/device.h (pic16_options_t): added field debgen,
4326         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
4327         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
4328         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
4329         puclic,
4330         * (various functions): added macros FENTRY and FENTRY2 to functions,
4331         to emit function prologue,
4332         * (various functions): fixed indentation,
4333         * (genNearPointerGet): fixed loading of FSR0,
4334         * (genPackBits): applied patch from Raphael Neider to fix updating
4335         of FSR0 and touching only the modified bits,
4336         * src/pic16/genarith.c (various functions): added macros FENTRY to
4337         emit function prologue in comments,
4338         * src/pic16/pcode.h: added functions debugf2, debugf3,
4339         * src/pic16/ralloc.c: partial fix for packForPush caused
4340         segmentation fault,
4341
4342 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4343
4344         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
4345           <stsp AT users.sourceforge.net> with reversed byte order
4346         * support/regression/tests/rotate.c: added (ds390 skips some tests)
4347
4348 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4349
4350         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
4351           bug #1074377
4352         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
4353         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
4354
4355 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4356
4357         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
4358
4359 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4360
4361         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
4362           conditions,
4363           (setFromConditionArgs): friendly operand parser for peephole rules,
4364           (operandBaseName, operandsNotRelated): new peephole condition
4365           "operandsNotRelated" -- similar to "operandsNotSame", but takes
4366           architecture specific register naming into account, handles n-way
4367           comparisons, and supports quoted literals
4368         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
4369
4370 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4371
4372         * src/mcs51/peeph.def: fixed bug #1076940
4373
4374 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4375
4376         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
4377
4378 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4379
4380         Adding support for replacing ljmps with sjmps in jumptables
4381         generated for switch statements. For now you need to set the
4382         environment variable SDCC_SJMP_JUMPTABLE to enable this.
4383         Now 4 algorithms for mcs51 jumptable generation are used:
4384         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
4385         addresses loaded pc-relative for up to 112 cases and stack-pushing
4386         target addresses loaded with offset from dptr for up to 256 cases.
4387
4388         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
4389         * src/mcs51/main.c: adapted constants for switch table generation
4390         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
4391
4392 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
4393
4394         * device/lib/printf_large.c (_print_format): fixed bug 1073386
4395         * support/regression/tests/bug1057979.c: added test for bug 1073386
4396
4397 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4398
4399         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
4400         compilers
4401
4402 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4403
4404         * src/pic16/device.h,
4405         * src/pic16/genarith.c,
4406         * src/pic16/glue.c,
4407         * src/pic16/main.c,
4408         * src/pic16/pcode.c: applied patches #1068154 and #1070213
4409
4410 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
4411
4412         Large cummulative patch for pic16 port.
4413         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
4414         to call when a stack overflow occurs,
4415         * (malloc.h): added CVS Id tag,
4416         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
4417         variable,
4418         * added libc directory. The current version of LibC contains string
4419         functions, ctype functions and macros and some functions of the
4420         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
4421         be extensively tested in the future. Standard disclaimer here.
4422         Library is not automatically build yet. But one can build it by
4423         invoking 'make' inside the libc directory.
4424         * added ADC library under libio. Preliminary version yet.
4425
4426         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
4427         * src/pic16/gen.c (aopForRemat): asmop size is filled by
4428         aopForRemat() now and not by pic16_aopOp(),
4429         * (pic16_popGetTempReg): removed warning messgae when allocating
4430         temporary registers, its a buggy feature and will be removed,
4431         * (pic16_popGet): set register instance field in AOP_CRY,
4432         * (pic16_outBitC): fixed for results in size greater than 1,
4433         * (genUminusFloat): fixed for pic16, ported code from mcs51,
4434         * (pic16_storeForReturn): optimized return of 0,
4435         * (genCmp): experimental code for new genCmp which uses PIC18's
4436         special compare&skip instructions. Initial tests fail some times
4437         with variables grater than 1 byte in size, so new code is disabled,
4438         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
4439         a single bit,
4440         * (genCast): began a fix to optimize the casting of a bit to another
4441         bit, now assigning a bitfield to another bitfield will fail, sorry,
4442         * src/pic16/main.c: disabled the use of lr-support feature,
4443         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
4444         * added some function prototypes, added function _debugf prototype,
4445         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
4446         bits with offset (case PO_GPR_BIT),
4447         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
4448         command line,
4449         * (isBankInstruction): modified to return 0 for no banking instruction,
4450         and 1 for banking instruction,
4451         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
4452         caused stop processing pCodes after a inline assembly block,
4453         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
4454         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4455         registers when it shouldn't,
4456         * src/pic16/ralloc.c (allocReg): add preliminary support for
4457         supporting a limited set of temporary registers,
4458
4459 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4460
4461         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4462           genDataPointerSet): ensure assignments always copy in MSB to LSB
4463           order,
4464           (loadRegFromAop): recognize CLRH optimization,
4465           (genFunction): optimize RECEIVE iCodes in reentrant functions
4466
4467 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4468
4469         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4470           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4471           selected.
4472         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4473         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4474           contiguous with data
4475
4476 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4477
4478         * device/lib/_gptrget.c (_gptrget),
4479         * device/lib/_gptrgetc.c (_gptrgetc),
4480         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4481           instead of sjmp to ret
4482         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4483           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4484
4485 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4486
4487         * .version: bumped version to 2.4.7
4488         * device/lib/_gptrget.c (_gptrget): is now _naked
4489         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4490         * device/lib/_gptrput.c (_gptrput): is now _naked
4491         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4492           (createFunction): fixed xstack
4493         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4494         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4495           or bit either,
4496           (geniCodeCritical): store original interrupt state in an iTemp bit
4497           var unless stack-auto
4498         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4499         * src/SDCCmain.c (setIncludePath): added include/target to search path
4500         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4501         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4502           prototype,
4503           (processFuncArgs): put bit vars in bit area
4504         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4505           unsaveRBank): fixed xstack,
4506           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4507           (genFunction, genEndFunction): fixed xstack,
4508           (genAssign): optimization don't walk backwards through mem
4509         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4510         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4511         * support/regression/Makefile: also make library (for stack-auto) when
4512           making "all" and added "test-mcs51-xstack-auto"
4513         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4514         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4515         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4516         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4517         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4518           make-library by MAKE_LIBRARY
4519         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4520           regression tests for xstack
4521         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4522         * support/regression/tests/critical.c: test for critical on mcs51
4523
4524 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4525
4526         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4527           built version of sdcc instead of installed version
4528
4529 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4530
4531         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4532         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4533           vprintf.c now
4534         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4535         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4536           WARNING: remove device/lib/build/z80/printf.o by hand when
4537           updating from previous build!
4538         * device/lib/z80/printf.c: updated comment
4539         * support/regression/tests/bug1057979.c: test all ports now
4540         * support/regression/tests/bug1065458.c: file added
4541
4542 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4543
4544         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4545           *_start and *_end symbols for static functions
4546
4547 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4548
4549         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4550           and search crt0.o in all library paths,
4551           (setIncludePath): proper handling of --nostdinc,
4552           (setLibPath): proper handling of --nostdlib
4553         * support/regression/Makefile,
4554         * support/regression/ports/ds390/spec.mk,
4555         * support/regression/ports/gbz80/spec.mk,
4556         * support/regression/ports/hc08/spec.mk,
4557         * support/regression/ports/mcs51/spec.mk,
4558         * support/regression/ports/mcs51-large/spec.mk,
4559         * support/regression/ports/mcs51-stack-auto/spec.mk,
4560         * support/regression/ports/z80/spec.mk: use include and lib files from
4561           built version of sdcc instead of installed version
4562         * doc/sdccman.lyx: fixed typo in --nostdinc
4563
4564 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4565
4566         * src/pic/pcode.c,
4567         * src/pic/device.c,
4568         * src/pic/ralloc.c,
4569         * src/pic/gen.c : added support to generate code for struct bit fields.
4570
4571 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4572
4573         * as/xa51/xa_version.h,
4574         * device/include/errno.h,
4575         * device/include/regc515c.h,
4576         * device/lib/_itoa.c,
4577         * device/lib/_ltoa.c,
4578         * device/lib/ser_ir_cts_rts.c,
4579         * sim/ucsim/xa.src/glob.cc,
4580         * sim/ucsim/xa.src/inst_gen.cc,
4581         * sim/ucsim/xa.src/xa_bit.cc,
4582         * sim/ucsim/xa.src/xa_sfr.cc,
4583         * sim/ucsim/z80.src/inst_dd.cc,
4584         * sim/ucsim/z80.src/inst_fdcb.cc,
4585         * support/scripts/keil2sdcc.pl,
4586         * src/pic16/pic16.dsp,
4587         * src/pic16/pic16a.dsp: corrected cvs line endings
4588         * device/lib/printf_large.c: fixed bug 1057979
4589         * src/pic16/gen.c: fixed non-C standard code
4590         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4591         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4592         * support/regression/ports/mcs51/support.c: reload T1 asap
4593         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4594           pdata use and clear idata startup behaviour
4595         * support/regression/tests/bug1057979.c: added
4596
4597 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4598
4599         * device/examples/ds390/ow390/ad26.h,
4600         * device/examples/ds390/ow390/cnt1d.h,
4601         * device/examples/ds390/ow390/crcutil.c,
4602         * device/examples/ds390/ow390/ownet.h,
4603         * device/examples/ds390/ow390/owsesu.c,
4604         * device/examples/ds390/ow390/swt12.h,
4605         * device/examples/ds390/ow390/swtoper.c,
4606         * device/examples/ds390/ow390/temp10.h,
4607         * device/examples/ds390/ow390/thermodl.c,
4608         * device/examples/ds390/tinitalk/tinitalk.dsp,
4609         * device/examples/ds390/tinitalk/tinitalk.dsw,
4610         * device/examples/mcs51/clock/hw.h,
4611         * device/examples/mcs51/simple2/go.bat,
4612         * device/examples/serialcomm/windows/serial.h,
4613         * device/examples/xa51/dummy.c,
4614         * device/examples/xa51/hello.c,
4615         * device/include/80c51xa.h,
4616         * device/include/at89x051.h: corrected cvs line endings
4617
4618 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4619
4620         * src/pic16/main.c (options): added command line --gstack, to trace
4621         stack over/under flows,
4622         * added pragma 'wparam' to allow passing first byte of function
4623         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4624         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4625         call to __gstack_test function and sets up the symbol as extern,
4626         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4627         * popaop): added call to pic16_testStackOverflow,
4628         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4629         wparamList list,
4630         * (genCall, genPcall): now all parameters are passed via stack
4631         except in functions that are pass to wparam pragma in which WREG is
4632         used too,
4633         * (genPcall): REENTRANT flag is checked to see if variable prototype
4634         contains reentrant keyword, don't call a non-reentrant function, via
4635         a reentrant function pointer or vice versa, functions are never
4636         passed via WREG,
4637         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4638         D.Winkler,
4639         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4640         SIGSEGV when accessing a NULL register stucture,
4641         * (pic16_printGPointerType): modified to handle UPPER modifier for
4642         function initializers, changed prototype of function to simpler one,
4643         * (pic16_printIvalFuncPtr): check to see if function is already
4644         added in externs list,
4645         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4646         optimized a move from W to SFR with a move to the same register
4647         later after a CALL,
4648         * device/lib/pic16/debug: NEW directory, contains debug features
4649         which are enabled when linking with libdebug.lib, currently command
4650         line option --gstack enables stack pointer tracing for over/under
4651         flow, corresponding sources are in debug/gstack
4652
4653 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4654
4655         * doc/sdccman.lyx: updated SDCC version,
4656         * (PIC16 port): update list of command line options,
4657         * src/pic16/device.h (structure pic16_options_t): added field gstack
4658         to enable stack overflow tracing on push/pops,
4659         * src/pic16/device.c (statistics structure): added statistics
4660         structure,
4661         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4662         pic16_dump_int_registers): increase statistics counters for each
4663         * variable which is encountered
4664         * (pic16_dump_usection): emit each .udata variable to its own udata
4665         section,
4666         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4667         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4668         parameters via stack, otherwise use old scheme,
4669         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4670         assembler output file,
4671         * src/pic16/main.c: added command line options --gstack to enable
4672         push/pop tracing for stack overflow,
4673         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4674         instructions): added size of each instruction,
4675         * (pic16_countInstruction): estimate size of instructions in
4676         the_pFile list, inline assembly blocks are not counted,
4677         * (pic16_FixRegisterBanking): trace previous register usage, when
4678         banksel optimizations is greater than 0, don't emit a redudant
4679         banksel directive,
4680
4681 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4682
4683         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4684         * src/pic16/ralloc.c : applied same fix for pic16.
4685         * src/pic/gen.c : tidied it up a little.
4686
4687 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4688
4689         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4690         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4691
4692 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4693
4694         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4695
4696 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4697
4698         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4699         non-reentrant function __modsint in the interrupt function (thus
4700         corrupting math operations during serial I/O)
4701         * device/lib/ser_ir.c: as above, changed buffersize
4702         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4703         256.c,d for zeroing
4704         * doc/Makefile: added option -t for rsync
4705
4706 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4707
4708         * src/SDCCast.h (struct ast),
4709         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4710
4711 2004-10-20 Borut Razem <borut.razem AT siol.net>
4712
4713         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4714         package
4715
4716 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4717
4718         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4719         makefile targets,
4720         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4721         support functions to replace long sequences of MOVFF's from access
4722         bank registers to stack and vice versa,
4723         * src/pic16/device.h: added new field opt_flags, where optimization
4724         flags can be set to enable certain features,
4725         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4726         * pBlock, (genFunction, genEndFunction): surroung loop for
4727         saving/loading used registers in stack with PC_INFO pCodes,
4728         INF_LREGS. Code in between can then be optimized by pCode optimizer
4729         to support function calls,
4730         * (genDataPointerSet): fixed bug which loaded float fields in
4731         structures with corrupt data,
4732         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4733         in a standard way debug info on stderr. Feature used for developing
4734         and debugging only,
4735         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4736         obsolete chunks of code,
4737         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4738         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4739         * pic16/src/pcode.c (pic16_newpCodeInfo,
4740         * (pic16_newpCodeOpLocalRegs),
4741         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4742         feature,
4743         * (pic16_pCodeConstString): printing of the initial value of a
4744         symbol as a comment is inhibited since parsing was already done by
4745         copyStr and output is corrupt,
4746         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4747
4748 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4749
4750         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4751
4752 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4753
4754         * as/mcs51/lkarea.c: removed old K&R style,
4755           (lnksect): changed check on boundary error,
4756           (lnksect2): changed check on boundary error,
4757           (lnksect2): extend XSTK to end of page if size = 1
4758         * as/mcs51/lkmain.c: removed old K&R style,
4759           (Areas51): create l_IRAM symbol
4760         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4761         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4762           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4763         * device/lib/_mullong.c: added version to be compiled with xstack
4764         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4765         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4766         * device/lib/mcs51/crtxstack.asm: fixed comment
4767         * src/SDCCglue.c: maxInterrupts defaults to 0,
4768           (emitMaps): added pdata,
4769           (createInterruptVect): (re)moved default,
4770           (glue): added pdata,
4771           (glue): moved __start__xstack to XSTK with default size 1
4772         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4773           and options.float_rent when options.stackAuto is set,
4774           (linkEdit): only write XDATA_NAME if provided on command line
4775         * src/SDCCmem.h,
4776         * src/SDCCmem.c: added pdata
4777         * src/port.h: added pdata_name to PORT
4778         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4779           (saveRegisters, unsaveRegisters): removed usage of B,
4780           (genMinus): fixed accumulator clash,
4781           (genJumpTab): added comment, this needs another look
4782         * src/mcs51/gen.c: added check for "B in use" paranoia,
4783           added pushB() and popB()
4784         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4785           chance
4786         * src/avr/main.c,
4787         * src/ds390/main.c,
4788         * src/hc08/main.c,
4789         * src/mcs51/main.c,
4790         * src/pic/main.c,
4791         * src/pic16/main.c,
4792         * src/xa51/main.c,
4793         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4794           added PSEG (PAG,XDATA) or NULL to port specifier
4795         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4796         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4797           (_mcs51_genInitStartup): removed __start__xstack equ,
4798           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4799         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4800         * src/z80/gen.c (_rleAppend): fixed warnings
4801         * support/regression/tests/zeropad.c: added pdata test
4802         * .version: bumped to 2.4.6
4803
4804 2004-10-17 Borut Razem <borut.razem AT siol.net>
4805
4806         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4807         as a part of nightly build
4808
4809 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4810
4811         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4812         WREG holds the first byte function parameters,
4813         * (aopForSym): take special case for symbols which are in FARSPACE
4814         but in CODESPACE too,
4815         * (assignResultValue): modified to take into account _G.useWreg,
4816         * (genCall): don't use wreg for parameter passing when function is
4817         declared as reentrant, too, added optimization INCF to stack
4818         pointer when stack parameter count is 1,
4819         * (genFunction, genEndFunction): refurnished and fixed to not using
4820         wreg for passing parameters when function has varargs or is
4821         reentrant, fixed bug with symbol name compare for generating
4822         functions in absolute address,
4823         * (pic16_storeForReturn): refurnished,
4824         * (genCmp): began writing a new version of the function, not ready
4825         yet, therefore it is disabled,
4826         * (genAssign): do not read code memory when assigning a function to
4827         a pointer function,
4828         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4829         array of characters, not pointer,
4830         * (pic16initialComments): in debug mode emit an .ident directive for
4831         the assembler,
4832         * (_process_pragma): emit a new warning type (internal to pic16)
4833         when setting stack to default length, emit a similar warning when
4834         placing a function at absolute address and address is not word aligned
4835         * (_pic16_parseOptions): added 'return TRUE' statement,
4836         * (_pic16_linkEdit): if compiling a source, then add the source's
4837         file object, first in the list of objects to link,
4838
4839 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4840
4841         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4842         * src/pic/main.c : removed VC warning.
4843         * src/pic/gen.c : changed comment.
4844
4845 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4846
4847         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4848         reference to a deprecated symbol _GPTRREG was causing failure to
4849         link. Thanks G. M. Gallant for the info.
4850
4851 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4852
4853         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4854         comments for Bugs item #954788.
4855
4856 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4857
4858         * src/pic16/device.c (pic16_dump_gsection,
4859         * pic16_groupRegistersInSection): handle symbols declared to be in
4860         access bank differently,
4861         * src/pic16/gen.c (struct _G): added field resDirect,
4862         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4863         send values read from stack directly to result and don't allocate
4864         temporary values,
4865         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4866         same registers,
4867         * (pic16_sameRegsOfs): NEW,
4868         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4869         free because they were not allocated from temporary pool,
4870         * pic16_popRegFromString): workaround to fix a problem with
4871         allocating variables twice or never,
4872         * (genGenPointerGet): using PRODL instead of FSR0H,
4873         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4874         instead of FSR0H,
4875         * (genAssign): take advantage of the _G.resDirect flag,
4876         * (genCast): around line 11844, use mov2f instead of directly
4877         MOVFF'ing between operands to account for literal values,
4878         * src/pic16/genutils.c: some new debug functions for gpsim have been
4879         added,
4880         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4881         float with integer part only,
4882         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4883         place variables in access bank
4884         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4885         updated sources to reflect recent changes in gen.c
4886
4887 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4888
4889         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4890         sources that searched for headers in installation path, now the
4891         device/include/pic16 is used,
4892         * src/pic16/glue.c (pic16glue),
4893         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4894         .line directives if not in debug mode, this suppresses assembler's
4895         warnings for ignored directives
4896
4897 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4898
4899         * src/port.h: made reset_regparms prototype void parameter explicit.
4900         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4901         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4902         * doc/sdccman.lyx: documented warning disabling and how to use
4903           printf_large to make it print floats.
4904         * device/include/stdbool.h: NEW
4905         * device/lib/_atof.c,
4906         * device/lib/_divuint.c,
4907         * device/lib/_divulong.c,
4908         * device/lib/expf.c,
4909         * device/lib/printf_large.c,
4910         * device/lib/sincosf.c,
4911         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4912         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4913           a completely reentrant lib.
4914
4915 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4916
4917         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4918         * device/include/pic16/stdio.h: fixed bug with colon
4919
4920 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4921
4922         * device/include/pic16/stdio.h,
4923         * device/include/pic16/stdlib.h,
4924         * device/include/pic16/math.h: NEW
4925         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4926         declared as _naked to reduce overhead
4927         * device/lib/Makefile.in (target port-specific-objects-pic16):
4928         changed * to *.* so to ignore the CVS directory,
4929         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4930         stacked variables back in stack,
4931         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4932         corruption
4933
4934 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4935
4936         * .version: bumped version number to 2.4.5
4937         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4938         * support/Util/SDCCerr.c (messages structure): added entry for
4939         W_POSSBUG2
4940
4941         Large cumulative patch for pic16 port and libraries.
4942         * device/include/pic16/sdcc-lib.h,
4943         * device/include/pic16/stdarg.h,
4944         * device/include/asm/pic16/features.h,
4945         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4946         * device/include/pic16/float.h: changes reentrant keyword with
4947         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4948         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4949         updated target build-libraries to include objects from gptr,
4950         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4951         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4952         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4953         all function headings,
4954         * src/SDCCmain.c: added global parameter userIncDirsSet,
4955         * (parseCmdLine): when option -I is encountered add directory to
4956         userIncDirsSet too,
4957         * src/version.awk: added space between control and long,
4958         * src/pic16/NOTES: added some notes for the port,
4959         * src/pic16/gen.c: added prototype for mov2fp function,
4960         * (fReturnpic16[]): properly named return value registers,
4961         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4962         * (aopForSym): added code to handle symbols with onStack flag set,
4963         symbols onStack are allocated PTRSIZE bytes,
4964         * (aopFreeAsmop): handles special case where asmops are stack objects,
4965         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4966         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4967         added argument lock to trace flaws in allocating temporary registers
4968         when developing port,
4969         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4970         * (pic16_popRegFromString): reenabled allocating a direct register
4971         from string,
4972         * (assignResultValue): various beautifications,
4973         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4974         referenced function argument,
4975         * (genIpush): reenabled to allow stacked arguments, handles only
4976         ic->parmPush iCodes,
4977         * (genCall, genPcall): major changes to allow for variable argument
4978         functions, fixed a bug with falsely restoring stack pointer after
4979         returning from call,
4980         * (genFunction): pending code for critical function,
4981         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4982         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4983         * (genNearPointerGet): fixed bug with indirect reading, was always
4984         reading from INDF0
4985         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4986         pointers,
4987         * (genAddrOf): rewrote code to take address of a stacked function parameter
4988         * (genCast): fixed casting to generic pointer type,
4989         * src/pic16/gen.h: added AOP_STA,
4990         * (struct asmop): added field stk,
4991         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
4992         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
4993         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
4994         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
4995         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
4996         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
4997         generic pointers,
4998         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
4999         and library paths,
5000         * (pic16_port structure): generic pointer size is set to 3,
5001         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
5002         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
5003         compiler warning,
5004         * src/pic16/ralloc.c (allocReg): prevent allocating register when
5005         operand is an iTemp,
5006
5007 2004-09-24 Martin Helmling <mh AT octo-soft.de>
5008
5009         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
5010         * debugger/mcs51/simi.c: addapt new syntax of s51
5011
5012 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
5013
5014         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
5015         * src/pic16/pcode.c: commented out some calls to free() in order to
5016         fix bug #989576,
5017
5018 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5019
5020         * src/SDCCicode.h,
5021         * src/SDCCicode.c (isiCodeInFunctionCall),
5022         * src/avr/ralloc.c (selectSpil),
5023         * src/pic/ralloc.c (selectSpil),
5024         * src/pic16/ralloc.c (selectSpil),
5025         * src/ds390/ralloc.c (selectSpil),
5026         * src/hc08/ralloc.c (selectSpil),
5027         * src/xa51/ralloc.c (selectSpil),
5028         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
5029         stack in the middle of a function call sequence (fixes bug #1020268)
5030         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
5031         costs associated with the minimum switch case.
5032
5033 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5034
5035         * src/SDCC.lex: fixed bug #1030549
5036
5037 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5038
5039         * src/SDCCcse.h (struct cseDef),
5040         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
5041         over a function call if the CSE is derived from a symbol whose
5042         address has been taken (fixes bug #1029883)
5043         * support/regression/tests/bug-1029883: a new regression test for
5044         this bug
5045
5046 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5047
5048         * src/hc08/gen.c (emitinline): fixed bug #1029778
5049         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
5050         to a cast object is no longer a syntax error ("fixes" bug #1030006,
5051         and starts toward RFE #905167)
5052
5053 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
5054
5055         * src/pic16/gen.c (mov2f): New function to move an operand to
5056         another without considering if it is a literal or a register,
5057         * (pic16_sameRegs): don't check if they are both AOP_REG,
5058         * (AccRsh): removed andmask=0 lines,
5059         * (genLeftShift): duplicated to be improved in future versions,
5060         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
5061         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
5062         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
5063         * (pic16initMnemonics): added initialization for POC_INFSNZW,
5064         * (insertBankSwitch): fixed inserting banksel directives algorithm
5065         for instructions that follow a skip instruction, this fixes a report
5066         for broken subtraction code generation,
5067         * src/pic16/ralloc.c (deassignLRs): do not free register if current
5068         iCode is a left op, just in case result and right share the same
5069         registers
5070
5071 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5072
5073         * src/hc08/main.c,
5074         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
5075         preservation of HX
5076         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
5077         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
5078         on 2004-09-12; it was buggy
5079
5080 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
5081
5082         * src/SDCCsymt.h: removed RESULT_CHECK
5083         * src/SDCCast.c,
5084         * src/SDCCglue.c,
5085         * src/SDCCval.c,
5086         * src/pic/glue.c,
5087         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
5088
5089 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
5090
5091         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
5092         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
5093         configuration values no more rejected by compiler, they are assigned
5094         to configuration registers with a warning message instead,
5095         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
5096         the for-loop so last conf register is emitted too,
5097         * (_pic16_initPaths): link library libsdcc.lib by default,
5098         * (_hasNativeMulFor): modified test for multiplication according to
5099         Raphael Neider's remarks. Integer multiplication is also done with
5100         support functions,
5101         * device/include/pic16/pic18fregs.h: corrected type error in while
5102         testing and including 18f6720 header file
5103
5104 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
5105
5106         * src/pic16/device.h (pic16_options): removed field use_crt,
5107         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
5108         until an optimization to handle single bits is added,
5109         * (pic16_loadFSR0): moved before genUnpackBits,
5110         * (genAnd): some white lines removed,
5111         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
5112         leave_reset flags in pic16_options when using crt modules,
5113
5114 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
5115
5116         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
5117           for bugs 898889 & 979599. Also used some safer print instructions.
5118
5119 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
5120
5121         * src/pic16/device.h (pic16_options_t): added field use_crt,
5122         crt_name, no_crt,
5123         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
5124         catch a probable future bug,
5125         * src/pic16/gen.c: aopIdx function commented out,
5126         * (genAssign): commented out old code which used aopIdx,
5127         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
5128         code, added if conditionals to take into account the --use-crt
5129         command line options,
5130         * src/pic16/main.c (pic16_optionsTable): added new command line
5131         options, --use-crt= and --no-crt,
5132         * (_pic16_linkEdit): now the proper crt object is added in the
5133         linker command line except than when --no-crt is specified,
5134         * src/pic16/pcode.c,
5135         * src/pic16/pcode.h: added some structures and functions for a new
5136         optimization scheme to compansate for instruction overhead between
5137         same iCodes, this scheme is currently under development and is not
5138         working in any way,
5139         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
5140         to && operator,
5141         * device/lib/pic16/startup/crt0i.c,
5142         * device/lib/pic16/startup/crt0iz.c: added global char variable
5143         __uflags to force the generation of an idata section
5144
5145 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
5146
5147         * doc/Makefile,
5148         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
5149         * doc/sdccman.lyx: updated sdcc version to 2.4.4
5150
5151 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5152
5153         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
5154         Frieder) and clarified the default code optimization mode
5155
5156 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5157
5158         * src/SDCC.lex (doPragma, process_pragma),
5159         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
5160         "opt_code_size", and "opt_code_balanced"
5161         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
5162         regrouped options by category, added support for category headers
5163         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
5164         and "--opt-code-size"
5165         * doc/sdccman.lyx: documented these new options and pragmas
5166         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
5167         preference into account
5168
5169 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5170
5171         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
5172           geniCodePreDec): Fixed bug 904237 by generating a warning
5173         * src/SDCCerr.h,
5174         * src/SDCCerr.c: added warning W_SIZEOF_VOID
5175
5176 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
5177
5178         * src/pic/device.c : When no max ram set validate full memory range.
5179         * src/pic/pcode.c,
5180         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
5181
5182 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5183
5184         * device/lib/_gptrget.c,
5185         * device/lib/_gptrput.c: updated comment
5186         * device/lib/calloc.c,
5187         * device/lib/free.c,
5188         * device/lib/malloc.c,
5189         * device/lib/realloc.c: added LGPL, made them reentrant-safe
5190         * src/SDCCcse.c (cseBBlock),
5191         * src/SDCCicode.c (printOperand, geniCodeArray),
5192         * src/SDCCicode.h (struct operand): fixed bug 868103
5193         * support/regression/tests/bug-868103.c: added
5194         * src/SDCCast.c (searchLitOp),
5195         * src/SDCCcse.h (struct cseDef),
5196         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
5197         * src/SDCCicode.h (struct operand),
5198         * src/SDCCsymt.h (struct sym_link),
5199         * src/avr/gen.c (hasInc),
5200         * src/ds390/gen.c (hasInc),
5201         * src/hc08/gen.c (genPlusIncr, hasInc),
5202         * src/mcs51/gen.c (hasInc),
5203         * src/pic16/glue.c (pic16_printIvalChar),
5204         * src/pic16/ralloc.c (regWithIdx),
5205         * src/xa51/gen.c (hasInc) : removed warnings
5206         * src/SDCCast.c (createBlock): added comment ???
5207         * src/hc08/ralloc.c: updated comments
5208
5209 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5210
5211         * doc/sdccman.lyx: updated section on switch statements, added
5212         section about semaphore locking
5213         * doc/Makefile: added option -info for latex2html
5214         * device/lib/_gptrget.c,
5215         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
5216
5217 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5218
5219         * src/pic/device.h,
5220         * src/pic/device.c,
5221         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
5222          maxram is less than 0x100.
5223
5224 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5225
5226         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
5227
5228 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5229
5230         * src/port.h,
5231         * src/mcs51/main.c,
5232         * src/ds390/main.c,
5233         * src/z80/main.c,
5234         * src/hc08/main.c,
5235         * src/pic/main.c,
5236         * src/pic16/main.c,
5237         * src/avr/main.c,
5238         * src/xa51/main.c
5239         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
5240         a jump table is the best form for a switch statement, including
5241         automatic insertion of missing cases to make the case range
5242         continuous. Developed in collaboration with Frieder Ferlemann.
5243
5244 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5245
5246         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
5247         accumulator result if it needs sign extension
5248
5249 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5250
5251         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
5252
5253 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5254
5255         * device/lib/gbz80/printf.c,
5256         * device/lib/z80/printf.c: removed define for NULL
5257
5258 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5259
5260         * as/xa51/xa_link.c,
5261         * device/examples/ds390/ow390/ad26.c,
5262         * device/examples/ds390/ow390/cnt1d.c,
5263         * device/examples/ds390/ow390/counter.c,
5264         * device/examples/ds390/ow390/ds2480.h,
5265         * device/examples/ds390/ow390/ds2480ut.c,
5266         * device/examples/ds390/ow390/findtype.c,
5267         * device/examples/ds390/ow390/gethumd.c,
5268         * device/examples/ds390/ow390/owllu.c,
5269         * device/examples/ds390/ow390/ownetu.c,
5270         * device/examples/ds390/ow390/swt12.c,
5271         * device/examples/ds390/ow390/swtloop.c,
5272         * device/examples/ds390/ow390/temp.c,
5273         * device/examples/ds390/ow390/temp10.c,
5274         * device/examples/ds390/ow390/thermo21.c,
5275         * device/examples/ds390/ow390/tinilnk.c,
5276         * device/examples/ds390/ow390/tstfind.c,
5277         * device/examples/serialcomm/windows/serial.cpp,
5278         * device/examples/serialcomm/windows/test_serialcomm.cpp,
5279         * device/include/reg51.h: fixed line endings for cvs
5280
5281 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5282
5283         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
5284         packRegsForAccUse, packRegisters): new accumulator register
5285         packing algorithm
5286         * support/regression/ports/hc08/support.c (_putchar): suppress
5287         warning of unused variable
5288         * src/SDCCicode.c: added SWAP entry to codeTable
5289
5290 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
5291
5292         * device/lib/sprintf.c: forgot to add this file before previous commit
5293
5294 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
5295
5296         * src/pic16/gen.c (genPackBits): added operand right in function
5297         parameters, load result directly if p_type is POINTER (that is
5298         called by genNearPointerSet)
5299         * (genUnPackBits): added operand left in function parameters,
5300         * (genNearPointerGet, genNearPointerSet): prevent the loading of
5301         FSR0 if accessing bitfields,
5302
5303 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
5304
5305         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
5306           _print_format; updated printf, sprintf, vsprintf
5307         * device/include/asm/default/features.h: corrected comment/define
5308         * device/lib/Makefile.in: added sprintf.c
5309         * device/lib/libsdcc.lib: added sprintf module
5310         * device/lib/printf_large.c,
5311         * device/lib/vprintf.c,
5312         * device/lib/sprintf.c: totally refactored printf_large and vprintf
5313           into these 3 files
5314         * support/regression/Makefile: changed ALL_PORTS into a usefull default
5315         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
5316         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
5317           hc08 test
5318         * support/regression/tests/zeropad.c: define idata as data for hc08
5319
5320 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5321
5322         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
5323         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
5324         labels are referenced at least once (even if a reference is not found)
5325         * src/hc08/gen.c (emitcode): set isComment flag for comments
5326         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
5327         loads), rules 6a..6b (optimize jumps to return)
5328
5329 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5330
5331         * device/lib/acosf.c (acosf),
5332         * device/lib/asinf.c (asinf),
5333         * device/lib/atanf.c (atanf),
5334         * device/lib/ceilf.c (ceilf),
5335         * device/lib/cosf.c (cosf),
5336         * device/lib/coshf.c (coshf),
5337         * device/lib/cotf.c (cotf),
5338         * device/lib/fabsf.c (fabsf),
5339         * device/lib/floorf.c (floorf),
5340         * device/lib/log10f.c (log10f),
5341         * device/lib/logf.c (logf),
5342         * device/lib/sinf.c (sinf),
5343         * device/lib/sinhf.c (sinhf),
5344         * device/lib/sqrtf.c (sqrtf),
5345         * device/lib/tanf.c (tanf),
5346         * device/lib/tanhf.c (tanhf),
5347         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
5348         replaced all instances of "reentrant" in the library functions
5349         defined in math.h with this macro.
5350         * support/regression/tests/float_trans.c: reenabled test for hc08
5351
5352 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
5353
5354         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
5355         erroneously deleted
5356
5357 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5358
5359         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
5360         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
5361         multi-byte volatile operands are used
5362         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
5363         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
5364         initialization to area GSINIT0 so that it would always precede
5365         any static initializers in GSINIT
5366         * support/regression/tests/zeropad.c: fixed idata define for hc08
5367         * support/regression/tests/bug-927659.c,
5368         * support/regression/tests/float_trans.c: disabled tests for hc08
5369         pending missing library routines
5370         * .version: increased version number to 2.4.4 - hc08 port now passes
5371         regression tests
5372
5373
5374 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
5375
5376         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
5377         * Makefile.common.in,
5378         * as/Makefile,
5379         * as/hc08/Makefile.in,
5380         * as/mcs51/Makefile.in,
5381         * as/z80/Makefile.in,
5382         * debugger/mcs51/Makefile.in,
5383         * device/include/Makefile.in,
5384         * device/lib/Makefile.in,
5385         * doc/Makefile,
5386         * link/Makefile,
5387         * link/z80/Makefile.in,
5388         * packihx/Makefile.in,
5389         * sim/ucsim/main_in.mk,
5390         * sim/ucsim/avr.src/Makefile.in,
5391         * sim/ucsim/doc/Makefile.in,
5392         * sim/ucsim/gui.src/serio.src/Makefile.in,
5393         * sim/ucsim/hc08.src/Makefile.in,
5394         * sim/ucsim/s51.src/Makefile.in,
5395         * sim/ucsim/xa.src/Makefile.in,
5396         * sim/ucsim/z80.src/Makefile.in,
5397         * src/Makefile.in,
5398         * support/cpp2/Makefile.in,
5399         * support/librarian/Makefile,
5400         * support/makebin/Makefile: added DESTDIR to the install path proposed
5401         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
5402         * doc/sdccman.lyx: added DESTDIR documentation
5403
5404 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
5405
5406         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
5407         instruction for interrupt handlers, use fast returns when returning
5408         from high priority interrupts
5409
5410 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5411
5412         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
5413         code generation
5414         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
5415         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
5416         bugs, ported much of Bernhard's code from mcs51
5417         * src/mcs51/gen.c (genSend),
5418         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
5419         than one when calling a reentrant function
5420         * device/lib/_mullong.c: defined an alternate struct layout for big
5421         endian ports (hc08)
5422
5423 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5424
5425         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
5426         test
5427
5428 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5429
5430         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
5431         are sane and complete before asking the port its prefered parameter
5432         passing method (fixes bug #1017633)
5433         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
5434         and _ret3
5435
5436 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5437
5438         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
5439         problem in bitfields >= 8 bits.
5440
5441 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5442
5443         * src/SDCCsymt.c: undid changes that were not meant to be committed
5444
5445 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5446
5447         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
5448
5449 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5450
5451         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
5452           copied and wrong bit got inverted
5453
5454 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5455
5456         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5457         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5458         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5459         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5460         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5461         assignments to bitfields at known addresses
5462         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5463         reads from bitfields at known addresses
5464         * src/hc08/ralloc.c (packRegisters),
5465         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5466         genhc08Code): optimize pointer get values used as conditionals
5467         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5468         and branch
5469
5470 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5471
5472         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5473         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5474         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5475         as conditionals
5476
5477 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5478
5479         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5480
5481 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5482
5483         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5484         related problems
5485
5486 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5487
5488         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5489
5490 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5491
5492         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5493         mcs51 port
5494
5495 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5496
5497         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5498
5499 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5500
5501         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5502         cases use more compact code.
5503
5504 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5505
5506         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5507
5508 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5509
5510         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5511
5512 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5513
5514         * src/SDCCsymt.h,
5515         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5516         parameter of changePointer() from symbol* to sym_link*
5517         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5518         * src/SDCCsymt.c (compareType): void* type is castable to other
5519         pointers, but not necesarily an exact match.
5520         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5521         is no longer blindly treated as an exact match.
5522         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5523
5524 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5525
5526         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5527
5528 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5529
5530         * src/pic/gen.c,
5531         * src/pic/pcode.c,
5532         * src/pic/ralloc.h,
5533         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5534
5535 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5536
5537         * src/pic/device.c,
5538         * src/pic/device.h,
5539         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5540
5541 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5542
5543         * src/mcs51/gen.c (emitcode): fixed bug #992819
5544
5545 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5546
5547         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5548           there's no need to make it worse
5549
5550 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5551
5552         * src/mcs51/ralloc.c (deassignLR),
5553         * src/ds390/ralloc.c (deassignLR),
5554         * src/hc08/ralloc.c (deassignLR),
5555         * src/z80/ralloc.c (deassignLR),
5556         * src/pic/ralloc.c (deassignLR),
5557         * src/pic16/ralloc.c (deassignLR),
5558         * src/avr/ralloc.c (deassignLR),
5559         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5560         rlivePoint): fixed another part of bug #971834
5561
5562 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5563
5564         * src/z80/main.c: enabled "critical" keyword
5565         * src/z80/mappings.i,
5566         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5567         functions (fixes bug #979646)
5568         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5569
5570 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5571
5572         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5573           such as c:\mydir.
5574
5575 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5576
5577         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5578           doesn't disable too much optimizations
5579
5580 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5581
5582         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5583
5584 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5585
5586         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5587
5588 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5589
5590         * src/pic/gen.c tidied up tabs
5591         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5592         * src/pic/main.c tidied up tabs
5593         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5594         * src/pic/pcoderegs.c tidied up tabs
5595         * src/pic/ralloc.c tidied up tabs
5596
5597 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5598
5599         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5600         to S_FIXED for pic16 port and when symbol is not in level 0,
5601         allocate for S_REGISTER storage class and pic16 port, too,
5602         * src/pic16/device.h: prototype for checkSym,
5603         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5604         * (pic16_assignConfigWordValue): test the value and the mask to
5605         validate that the value is suitable for the configuration word,
5606         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5607         collect extern declared symbols, don't emit symbol twice, check
5608         first if symbol is in publics set first,
5609         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5610         * added command line '--fstack' which enables an experimental
5611         feature for stack access, too buggy to be used yet...
5612         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5613         * (pic16_allocDirReg): when register has storage class S_REGISTER
5614         allocate in pic16_dynAccessRegs,
5615         * device/include/pic16/pic18f????.h: modified configuration word
5616         naming convention, words started as CONFIG0H but should be CONFIG1H
5617
5618 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5619
5620         * device/include/mcs51reg.h: fixed bug 970993
5621
5622 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5623
5624         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5625         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5626         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5627         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5628         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5629         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5630           error/warning numbers,
5631           added function setWarningDisabled()
5632         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5633         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5634           _memcmp.c _memmove.c calloc.c realloc.c free.c
5635         * support/regression/tests/malloc.c: added tests for new functionality
5636         * support/regression/tests/zeropad.c: added tests for truncated initializers
5637           and initialized char arrays starting with '\x0'
5638         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5639
5640 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5641
5642         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5643
5644 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5645
5646         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5647         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5648         peephole 177.e. Thanks to anonymous
5649
5650 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5651
5652         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5653         function isn't used in the source but referenced as a
5654         variable initializer then declare it as extern in .asm file
5655
5656 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5657
5658         * .version: increased version number to 2.4.3
5659
5660         Adding version extension according to ChangeLog CVS revision
5661         * src/Makefile.in (target all): added dependency 'version.h'
5662         * (rule version.h): added rule to create version.h from ChangeLog,
5663         * (rule dep): added dependency version.h,
5664         * src/version.awk: AWK script to create version.h
5665         * src/SDCCdwarf2.c (dwWriteModule),
5666         * src/SDCCglue.c (initialComments),
5667         * src/SDCCmain.c (printVersionInfo): modified to write after
5668         version string the version extension number,
5669         * src/SDCCutil.c: included "version.h"
5670         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5671         number,
5672         * src/SDCCutil.h: added prototype for getBuildNumber
5673
5674         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5675         includeDirsSet, too,
5676         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5677         const char [] is found in function prototype...
5678
5679         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5680         moving to WREG with source is already in WREG,
5681         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5682         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5683         * (aopForSym): stack'ed symbols are partially supported, added
5684         if-clause to support symbols in FARSPACE,
5685         * (sameRegs): added test for AOP_ACC to see if registers are same,
5686         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5687         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5688         * (pic16_popRegFromString): will not allocate a new register if it
5689         doesn't find one by name, bug may have introduced...
5690         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5691         * (genIpush): revived to use pic16 port's stack,
5692         * (genAddrOf): added incomplete case for stack'ed operand,
5693         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5694         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5695         can handle multibyte operands,
5696         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5697         * (pic16initialComments): added message for MPLAB compatibility
5698         mode enabled,
5699         * src/pic16/main.h: prototype for pic16_mplab_comp,
5700         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5701         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5702         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5703         because of increased complexity of procedure,
5704         * (_process_pragma): stack pragma changed to format 'stack pos len',
5705         emit symbol '_stack_end' to conform with gplink,
5706         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5707         to search for register,
5708         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5709         PO_GPR_REGISTER,
5710         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5711         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5712         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5713         case for PO_GPR_REGISTER,
5714         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5715         dies, the new era is ahead !...
5716         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5717         pic16_dynInternalRegs,
5718         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5719         * (pic16_allocDirReg): minor optimizations and bug fixes,
5720         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5721
5722         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5723         load stack and frame pointer with address of 'stack_end' symbol
5724
5725 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5726
5727         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5728         without source code but only variable initializers
5729
5730 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5731
5732         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5733         external are not declared as extern to reduce overhead while linking
5734
5735 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5736
5737         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5738
5739 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5740
5741         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5742           Yee Keat for the patch
5743         * src/SDCCast.c (decorateType): fixed bug #979599
5744         * src/ds390/gen.h: removed local fReturnSizeDS390
5745         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5746         * src/ds390/gen.c (genAnd, genOr, genXor),
5747         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5748
5749 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5750
5751         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5752         add relFilesSet to $3, manipulate $2 to handle linking of object
5753         files without source files in command line,
5754         * device/include/pic16 (all headers): added ID location macros,
5755         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5756         entries for ID location bytes,
5757         * (pic16_assignIdByteValue): NEW,
5758         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5759         added field dumpcalltree to pic16_options_t,
5760         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5761         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5762         emitting rFalseIfx label after check_carry label,
5763         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5764         pic16_emitDIRegs), NEW
5765         * (pic16glue): dump .calltree file when option --calltree found,
5766         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5767         * (_pic16_genAssemblerPreamble): emit ID locations after
5768         configuration registers,
5769         * (pic16_linkCmd): modifications of the link command,
5770         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5771         * (pic16_pCodeInitRegisters): don't init stack registers,
5772         * (pic16_findPrevInstruction): fixed bug,
5773         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5774         bug with immediate registers,
5775         * (buildCallTree): traces stack push and pop,
5776         * (pct2): dump also stack usage for each function,
5777         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5778         * (pic16_allocDirReg): various modifications,
5779         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5780         fixed to 1,
5781
5782 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5783
5784         * src/pic16/pcode.c: removed buggy double colon
5785
5786 2004-07-01 Borut Razem <borut.razem AT siol.net>
5787
5788         * support/scripts/sdcc.nsi: added include/pic16 to setup
5789
5790 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5791
5792         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5793         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5794         target 'clean',
5795         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5796         specific command line arguments. Also added sample lkr script
5797         for placing a variable at a specific memory bank.
5798         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5799         at a specific memory bank,
5800         * (pic16_dump_isection): fixed bug which caused string literals to
5801         be omitted when dumping idata section,
5802         * (pic16_groupRegistersInSection): added code to handle registers
5803         in specific memory banks,
5804         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5805         public, all references are renamed too,
5806         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5807         AOP_DPTR2,
5808         * (pic16_storeForReturn): added case to handle when dest is WREG,
5809         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5810         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5811         pic16_rel_udata, check to see if that register is marked as being
5812         a member of a specific memory bank,
5813         * (pic16_printIvalCharPtr): added code to add string literals either
5814         to code or the idata sections,
5815         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5816         also accept the 'udata' pragma,
5817         * src/pic16/main.h: new structure types sectName and sectSym
5818         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5819         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5820         * (pic16_findPrevInstruction): fixed, it returned nothing,
5821         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5822         instruction combinations,
5823         * (pic16_FixRegisterBanking): heavily reorganised,
5824         * (pic16_AnalyzeBanking): if generating banksel directives is
5825         disabled, then don't call FixRegisterBanking at all,
5826         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5827         completely removed,
5828         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5829
5830 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5831
5832         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5833         Phuah Yee Keat <yk.phuah AT nestac.com>
5834
5835 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5836
5837         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5838         correctly the IVT even if it is relocated to some other location
5839
5840 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5841
5842         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5843         * device/include/pic16/pic18f2220.h: NEW,
5844         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5845         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5846         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5847         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5848         nodefaultlibs, ivt_loc is the location of the interrupt vector
5849         table, and nodefaultlibs signs that default libraries should not be
5850         linked in link stage,
5851         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5852         according to --ivt-loc argument,
5853         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5854         when pragma stack is found,
5855
5856 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5857
5858         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5859         256 (range check), 257 (do while), 258.a-f (bit banging
5860         f.e. on 3-wire SPI bus)
5861
5862 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5863
5864         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5865         variables used exclusively within a loop
5866
5867 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5868
5869         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5870
5871 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5872
5873         * src/SDCClrange.c (computeClash): fixed bug #971834
5874
5875 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5876
5877         * src/mcs51/gen.c (genCmp): fixed bug #975903
5878         * src/hc08/gen.c (operandsEqu),
5879         * src/ds390/gen.c (operandsEqu),
5880         * src/z80/gen.c (operandsEqu),
5881         * src/pic/gen.c (operandsEqu),
5882         * src/pic16/gen.c (operandsEqu),
5883         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5884         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5885
5886 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5887
5888         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5889
5890 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5891
5892         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5893         default case in switch statement,
5894         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5895         to eliminate problem with initialisation of pointers, but problem
5896         still exists,
5897         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5898         * (emitStaticSegment): removed various lines emitting debug info,
5899         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5900         added processor registers for utilizing EEPROM,
5901         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5902         configurable and set 8
5903
5904 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5905
5906         * .version: increased version number to 2.4.2,
5907
5908         Cumulative patch for pic16 port
5909         * src/pic16/device.c: changed scheme to dump initial values for
5910         variables in idata segment, all print_idata* functions were removed,
5911         now the pic16_printIval* will be called,
5912         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5913         * _pic16_printPointerType, pic16_printPointerType,
5914         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5915         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5916         NEW, similar to the respective functions in SDCCglue.c,
5917         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5918         way, emitting hex bytes,
5919         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5920
5921 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5922
5923         * src/avr/ralloc.c (serialRegAssign),
5924         * src/xa51/ralloc.c (serialRegAssign),
5925         * src/pic/ralloc.c (serialRegAssign),
5926         * src/pic16/ralloc.c (serialRegAssign),
5927         * src/hc08/ralloc.c (serialRegAssign),
5928         * src/z80/ralloc.c (serialRegAssign),
5929         * src/ds390/ralloc.c (serialRegAssign),
5930         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5931
5932 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5933
5934         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5935         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5936
5937 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5938
5939         Cumulative patch for pic16 port:
5940         * src/pic16/device.h (typedef PIC16_device) modified fields for
5941         defining microcontrollers,
5942         * src/pic16/device.c: added new info for all devices in Pics16 array,
5943         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5944         to be optimised out by the pCode optimiser,
5945         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5946         specially, bug reported by G.M. Gallant,
5947         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5948         as force'd so that cannot be optimised out by pCode optimiser,
5949         * src/pic16/pcode.c,
5950         * src/pic16/pcodepeeph.c,
5951         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5952         they are disabled by default, but can be enabled explicit with
5953         command argument --denable-peeps, for testing,
5954         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5955         --pomit-ivt in COMPILE_FLAGS
5956
5957 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5958
5959         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5960           compilation on MSVC
5961
5962 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5963
5964         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5965
5966 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5967
5968         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5969         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5970
5971 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5972
5973         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5974         would only assign 0x300001 register.
5975
5976 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5977
5978         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5979         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5980
5981 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5982
5983         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5984         for ds80c400
5985         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5986         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5987         added peephole 254 (left shift), 255 (jump table)
5988
5989 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
5990
5991         * device/lib/Makefile.in: removed comment line with model-pic16,
5992         * (target port-specific-objects-pic16): the libraries and objects
5993         are copied to the build directory form the device/lib/pic16/bin
5994         directory
5995
5996         Cumulative patch concerning pic16 port:
5997         * library directory has been re-organized,
5998         * added support for PIC18F1220,
5999         * added headers and library sources for chips 18f1220,18f6520,
6000         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
6001
6002         * configuration registers setting has changed, now each supported
6003         device has a complete description of the registers it uses,
6004         * all initialisations are moved to idata sections, these section
6005         can be absolute or relocatable,
6006         * fixed initialisation of codespace variables,
6007         * fixed warning about PCLATU and gpsim,
6008         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
6009         * (genAssign): use table reads when assigning from variables in codespace,
6010         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
6011         char/int variables placed in codespace,
6012         * (pic16_emitConfigRegs): NEW, emits a list with configuration
6013         registers set in .asm file, no need for --pomit-config-words anymore,
6014         * (pic16glue): some 8051 legacy segments are commented out
6015         (to be removed completely),
6016         * added support for alternative assembler and linker with --asm=
6017         and --link= command line arguments,
6018         * peepholes are disabled automatically in the port, no need to
6019         specify on command line,
6020         * port supports natively char/int/long multiplication, but converts
6021         all divisions to support functions,
6022         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
6023         to the file set in variable $2,
6024         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
6025         strings in ASCII format and not in hex,
6026         * ralloc.c (serialRegAssign): added a triplet of conditional calls
6027         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
6028         allocate proper register if iCodes aren't temporary,
6029
6030 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
6031
6032         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
6033
6034 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
6035
6036         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
6037         is commented out
6038
6039 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6040
6041         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
6042         computed address is reused
6043         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
6044         multi-byte bitfields
6045
6046 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6047
6048         * src/z80/gen.c: (genArrayInit): must check for pointers too
6049
6050 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6051
6052         * support/regression/tests/zeropad.c: never meant to commit the
6053           nestedstruct test: removed, added check for GCC version
6054
6055 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
6056
6057         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
6058         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
6059         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
6060           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
6061           bugs 928906 and 954082 half-empty initializers
6062         * src/SDCCsymt.h,
6063         * src/SDCCsymt.c (getAllocSize): added for above fix
6064         * src/z80/gen.c (genArrayInit): fixed bug 741044
6065         * support/regression/tests/zeropad.c: added tests
6066
6067 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
6068
6069         * src/pic16/device.c (pic16_dump_section): corrected bug which
6070         caused some symbols of the libraries to be misplaced
6071
6072 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6073
6074         * src/pic16/glue.c,
6075         * src/pic16/ralloc.h,
6076         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
6077         to fix conflict with pic port
6078
6079 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6080
6081         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
6082         externs configuration variables,
6083         * src/pic16/ralloc.h,
6084         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
6085         prototype in header, commented out some debug messages
6086
6087 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
6088
6089         * src/pic16/glue.c,
6090         * src/pic16/main.c,
6091         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
6092         for gpasm COFF object generation. Thanks to D. Hawkins for
6093         his patch info
6094
6095 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6096
6097         * src/ds390/main.c,
6098         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
6099         Brock for spotting this)
6100         * src/ds390/gen.c (genEndFunction),
6101         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
6102         interrupt handler and critical. Disable push/pop optimizations when
6103         peephole optimizations disabled.
6104
6105 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6106
6107         Updated pic16 library sources and headers.
6108         * device/lib/pic16/pic18f*/ ,
6109         * device/include/pic16/*.h: modified to handle structured SFR
6110         definitions
6111
6112 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6113
6114         * src/port.h (PORT structure): added hook initPaths, now each
6115         port can declare its own default search paths,
6116         which can been seen with the --print-search-dirs option,
6117         see pic16 port for example,
6118         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
6119         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
6120         * (doPrintSearchDirs): NEW, replaces in a central manner the
6121         printing of search dirs which was split in set*Paths functions,
6122         * (main): added call to port->initPaths and doPrintSearchDirs,
6123         * src/avr/main.c,
6124         * src/ds390/main.c,
6125         * src/hc08/main.c,
6126         * src/izt/i186.c,
6127         * src/izt/tlcs900h.c,
6128         * src/mcs51/main.c,
6129         * src/pic/main.c,
6130         * src/pic16/main.c: modified port structures to reflect addition of
6131         initPaths hook,
6132
6133         * src/pic16/device.c (regCompare): registers are finally sorted by name,
6134         * (pic16_dump_section): for registers in same address reserve memory once,
6135         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
6136         to no_banksel,
6137         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
6138         result is greater in size than right or left,
6139         * (pic16_genUMult8X8_8): there are some cases where the result can
6140         be 16 bits size, so handle these,
6141         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
6142         * (pic16_outBitC): modified to emit pcodes,
6143         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
6144         or not,
6145         * (genDivOneByte): implemented algorithm to divide 8-bits,
6146         * (genCmp): uncommented goto, but issues still exist,
6147         * (genAnd): fixed a bug with variables >8bits,
6148         * (genPackBits): optimization added that uses BCF/BSF to change a
6149         single bit,
6150         * (genAssign): fixed bug when assigning floating point literals,
6151         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
6152         __sdcc_gsinit_startup label,
6153         * src/pic16/main.c (_pic16_init): removed search directory
6154         initialisations,
6155         * (_pic16_initPaths): NEW, used to initialise search directories,
6156         * (_hasNativeMulFor): support functions for all except char/int
6157         multiplication, and char division,
6158         * (PIC16_port struct): modified entry for native mul support,
6159         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
6160         no_banksel option,
6161         * (buildCallTree): call to register_usage is ifdef'ed out,
6162
6163 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6164
6165         * device/include/string.h: applied Stas Sergeev's patch to make this
6166         header file compatible with the preprocessor -Wundef option
6167         * src/SDCCmain.c (main): abort compilation if preprocessor reports
6168         failure (fixes bug #941458)
6169
6170 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6171
6172         * src/SDCCopt.c (killDeadCode): fixed bug #907733
6173         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
6174         that the variable, not the function, should be static
6175         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
6176         to be consistent with non-literal case
6177
6178 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6179
6180         * src/SDCCast.c (isConformingBody): fixed bug #949967
6181         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
6182         convilong): fixed bug #952086
6183
6184 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6185
6186         * src/SDCCmem.c (allocVariables): fixed bug #955321
6187
6188 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6189
6190         * src/hc08/main.c (_hc08_genAssemblerEnd),
6191         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
6192         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
6193         completely eliminated the use of a temporary file
6194         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
6195         when more than one file linked
6196         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
6197
6198 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6199
6200         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
6201         which fixes bug #543481
6202         * support/regression/tests/bug-751703.c: fixed comments left from a
6203         cut and paste error
6204         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
6205         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
6206         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
6207         scopes
6208         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
6209         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
6210         are now changed to underscores in moduleName
6211
6212 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6213
6214         * as/mcs51/lkmem.c: better fix for bug #954173
6215
6216 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
6217         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6218
6219         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
6220         * device/include/c8051f000.h,
6221         * device/include/c8051f120.h,
6222         * device/include/c8051f300.h,
6223         * device/include/c8051f310.h,
6224         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
6225         PWM16) and detab'ed
6226
6227 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6228
6229         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
6230         and mailing lists, doc'ed --no-peep-comments, removed reference
6231         to knoppix (newest version has no LyX/LaTeX), other minor changes
6232         * src/SDCCglue.c (glue): save 2 bytes stack space with
6233         option --main-return. The ljmp could probably be avoided too
6234
6235 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6236
6237         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
6238
6239 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6240
6241         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
6242         * src/SDCCopt.c (isLocalWithoutDef),
6243         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
6244         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
6245         (credit to Maarten Brock for patch #949363, on which this is based)
6246         * support/regression/tests/bug-751703.c: some test cases of extern used
6247         within inner scopes.
6248
6249 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6250
6251         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
6252         SPEC_STRUCT
6253         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
6254         struct definitions
6255         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
6256         dwWriteLabel): fix to create valid debugger symbols even when
6257         the module name has non-alphanumeric symbols in it
6258         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
6259         when a variable's allocation has been optimized away
6260
6261
6262 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6263
6264         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
6265         * src/hc08/main.c,
6266         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
6267         * src/mcs51/main.c,
6268         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
6269         * src/ds390/main.c,
6270         * src/z80/gen.c (z80_emitDebuggerSymbol),
6271         * src/z80/main.c,
6272         * src/pic/gen.c (pic14_emitDebuggerSymbol),
6273         * src/pic/main.c,
6274         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
6275         * src/pic16/main.c,
6276         * src/avr/gen.c (avr_emitDebuggerSymbol),
6277         * src/avr/main.c,
6278         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
6279         * src/xa51/main.c,
6280         * src/SDCCdebug.c (emitDebuggerSymbol),
6281         * src/SDCCdebug.h,
6282         * src/port.h: added a debugger struct to the port struct. Added a
6283         callback for defining debugger symbols
6284
6285         * src/SDCCast.c (createLabel),
6286         * src/SDCC.y (labeled_statement): mark all compiler generated labels
6287         with isitmp = 1
6288         * src/SDCCicode.h,
6289         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
6290         iCode back to the ast for the function
6291
6292         * src/hc08/ralloc.c (hc08_assignRegisters),
6293         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
6294         unneeded fields from the regs struct.
6295         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
6296         pushReg() & pullReg() functions instead of emitcode()
6297
6298         * src/hc08/gen.c (genLabel, genhc08Code),
6299         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
6300
6301         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
6302         debugger hooks
6303
6304         * src/hc08/gen.c (genEndFunction, genhc08Code),
6305         * src/hc08/gen.h,
6306         * src/mcs51/gen.c (genEndFunction, gen51Code),
6307         * src/mcs51/gen.h,
6308         * src/ds390/gen.c (genEndFunction, gen390Code),
6309         * src/ds390/gen.h,
6310         * src/z80/gen.c (genEndFunction, genZ80Code),
6311         * src/z80/gen.h,
6312         * src/z80/z80.h,
6313         * src/pic/gen.c (genEndFunction, genpic14Code),
6314         * src/pic/gen.h,
6315         * src/pic16/gen.c (genEndFunction, genpic16Code),
6316         * src/pic16/gen.h,
6317         * src/avr/gen.c (genEndFunction, genAVRCode),
6318         * src/avr/gen.h,
6319         * src/xa51/gen.c (genEndFunction, genXA51Code),
6320         * src/xa51/gen.h,
6321         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
6322         specific code to cdbFile.c and out of the backend code generators
6323
6324         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
6325         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
6326         starting address is now 0
6327
6328         * as/hc08/asm.h,
6329         * as/hc08/m08pst.c,
6330         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
6331         assembler directive for DWARF support
6332         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
6333
6334         * src/src.dsp,
6335         * src/Makefile.in,
6336         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
6337
6338 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6339
6340         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
6341         and inappropriate peephole optimization in jump tables
6342
6343 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6344
6345         * as/hc08/m08pst.c,
6346         * src/SDCCglue.c: sdccopt works for the hc08 port now
6347
6348 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
6349
6350         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
6351
6352 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6353
6354         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
6355
6356 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6357
6358         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
6359         rules
6360         * src/SDCCmain.c,
6361         * src/SDCCglobl.h,
6362         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
6363         comments from the peephole optimizer replacement rules
6364         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
6365         symbols
6366         * src/SDCCcse.c (updateSpillLocation),
6367         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
6368         equivalents
6369         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
6370         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
6371         objects far pointers
6372
6373 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6374
6375         * src/SDCCsymt.h: a missing part of my last change
6376         * src/pic/ralloc.c (regTypeNum),
6377         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
6378
6379 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6380
6381         * src/SDCCicode.h,
6382         * src/SDCCicode.c (aggrToPtrDclType),
6383         * src/SDCCptropt.h,
6384         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
6385         ptrPseudoSymConvert),
6386         * src/pic/ralloc.c (regTypeNum),
6387         * src/pic16/ralloc.c (regTypeNum),
6388         * src/hc08/ralloc.c (regTypeNum),
6389         * src/ds390/ralloc.c (regTypeNum),
6390         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
6391         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
6392
6393 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6394
6395         * link/z80/lkmain.c (afile),
6396         * as/hc08/lkmain.c (afile),
6397         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
6398         prevent a pointer problem when a filename has no directory and
6399         no extension specified.
6400
6401 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6402
6403         * link/z80/lkmain.c (afile): allow periods in directory names
6404         * link/z80/lkmain.c (afile),
6405         * as/mcs51/lkmain.c (afile),
6406         * as/hc08/lkmain.c (afile): allow linker script file to have an
6407         extension other than ".lnk"
6408         * link/z80/lklex.c (getfid),
6409         * link/z80/lkmain.c (parse),
6410         * as/mcs51/lklex.c (getfid),
6411         * as/mcs51/lkmain.c (parse),
6412         * as/hc08/lklex.c (getfid),
6413         * as/hc08/lkmain.c (parse): Support comments in the linker script
6414         file on lines by themselves and after filenames
6415
6416 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6417
6418         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
6419
6420 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6421
6422         * src/z80/peeph-z80.def: removed some peephole rules that don't
6423         work with multibyte arithmetic (fixed bug #937126)
6424         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
6425         to registers and not global variables
6426         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
6427         geniCodePreInc, geniCodePostDec, geniCodePreDec,
6428         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
6429         checking for assignments not internally generated (fixed bug #931895)
6430         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
6431         structure member (fixed bug #930072)
6432
6433 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6434
6435         * src/SDCCmain.c (linkEdit),
6436         * src/hc08/main.c (_hc08_parseOptions),
6437         * as/hc08/Makefile.in,
6438         * as/hc08/aslink.h,
6439         * as/hc08/asm.h,
6440         * as/hc08/m08pst.c,
6441         * as/hc08/lkrloc.c (relr, rele),
6442         * as/hc08/lkarea.c (lnkarea)
6443         * as/hc08/lkmain.c (afile, parse),
6444         * as/hc08/lkelf.c: support for ELF output
6445         * as/hc08/lks19.c (s19),
6446         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
6447
6448 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6449
6450         * as/mcs51/lkihx.c: Fixed bug #899105.
6451
6452 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6453
6454         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6455         .dsp files from Unix to DOS.
6456
6457 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6458
6459         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6460         function pointers; we have been compliant for several months now.
6461         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6462         change that was accidently commented out
6463         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6464         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6465         bug #922319
6466
6467 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6468
6469         * src/hc08/gen.c: output of all of the internal debugging information
6470         is now controlled by the D() macro; it is disabled by default
6471
6472 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6473
6474         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6475         harder to keep the same registers during a CAST iCode
6476         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6477         long via int can be done in a single cast, if the signedness is
6478         correct.
6479         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6480         putchar() in tinibios.c in ds390's library
6481
6482 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6483
6484         * src/SDCCast.c (decorateType): fixed bug #898889,
6485         cast result of a literal complement too
6486         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6487         fixed check for bitfields
6488
6489 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6490
6491         * src/SDCCicode.c (geniCodeLogic): made it static,
6492         (geniCodeLogicAndOr): added in order to fix bug #905492,
6493         (ast2iCode): fixed bug #905492
6494         * support/regression/tests/bug-905492.c: added
6495         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6496         (processParms): fixed bug #927659: don't copy parms, this will clear
6497         decorated flag
6498         * support/regression/tests/bug-927659.c: added
6499
6500 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6501
6502         * src/SDCCast.c (addCast): don't cast float to char
6503         * device/lib/libsdcc.lib: added _memmove
6504
6505 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6506
6507         * device/lib/large/Makefile: fixed parallel execution by
6508         replacing `make` by `$(MAKE)`
6509
6510 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6511
6512         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6513         offsets (fixes bug #923936)
6514
6515 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6516
6517         * device/lib/small/Makefile: fixed parallel execution by
6518         replacing `make` by `$(MAKE)`
6519
6520 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6521
6522         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6523
6524 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6525
6526         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6527         * src/regression/Makefile: Regression test was not running.
6528
6529 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6530
6531         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6532         complement if possible
6533         * src/SDCCval.c (valComplement),
6534         * src/SDCCicode.c (operandOperation): fixed complement of literal
6535         * support/regression/tests/onebyte.c (testComplement): added
6536
6537 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6538
6539         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6540         return an optimized tree; actually replace actParm with the new tree
6541         * src/SDCCast.h: added some parantheses to remove side effects
6542         * support/regression/tests/bug-920866.c
6543
6544 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6545         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6546         Bit operands were not being handled properly in the pic14 port.
6547         (now src/regression/add.c passes again).
6548
6549 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6550
6551         * src/SDCC.y (labeled_statement): case and default no longer require
6552         a following statement (RFE #893037)
6553
6554 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6555
6556         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6557         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6558         disabled (fixes bug #916294)
6559         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6560         "mov a,acc"; patch provided by Lenny Story
6561         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6562
6563 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6564
6565         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6566         functions
6567         * src/ds390/gen.c (genFunction, genEndFunction),
6568         * src/ds390/ralloc.c (ds390_assignRegisters),
6569         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6570         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6571         pushed if there are parameters passed on the stack. Also, a cleaner
6572         way to decide if r0/r1 should be pushed/popped. (Together they fix
6573         bug #918693)
6574
6575 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6576
6577         * doc/sdccman.lyx,
6578         * device/lib/mcs51/crtpagesfr.asm,
6579         * device/lib/mcs51/crtxinit.asm,
6580         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6581         to avoid confusion with Si Lab's SFRPAGE register.
6582
6583 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6584
6585         * src/SDCCglue.c (emitMaps): allow public sfr variables
6586         * src/SDCCglue.c (initialComments): include compiler build date
6587         with compiler version and put the timestamp of the generated
6588         assembly file on a serperate line to be less confusing.
6589         * src/port.h: added genInitStartup hook
6590         * src/avr/main.c,
6591         * src/ds390/main.c,
6592         * src/hc08/main.c,
6593         * src/pic/main.c,
6594         * src/pic16/main.c,
6595         * src/xa51/main.c,
6596         * src/z80/main.c: genInitStartup initialize as NULL (default to
6597         historical behaviour)
6598         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6599         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6600         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6601         library instead of hard coding it into the compiler.
6602         * support/regression/ports/mcs51-stack-auto/spec.mk,
6603         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6604         * device/lib/mcs51/Makefile,
6605         * device/lib/small/Makefile,
6606         * device/lib/large/Makefile,
6607         * device/lib/mcs51/crtpagesfr.asm,
6608         * device/lib/mcs51/crtstart.asm,
6609         * device/lib/mcs51/crtxclear.asm,
6610         * device/lib/mcs51/crtxinit.asm,
6611         * device/lib/mcs51/crtclear.asm,
6612         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6613         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6614         and into user configurable files.
6615         * device/lib/clean.mk: clean mcs51 directory too
6616         * support/regression/tests/longlit.c: added static to T1 declaration
6617         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6618         accesses in the initialization code
6619
6620 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6621
6622         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6623         OSCTRIMVAL as noted in bug #916008
6624
6625 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6626
6627         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6628         in loops with multiple exits (reported as incorrect registers
6629         used by Martin Helmling in Sdcc-user list)
6630
6631 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6632
6633         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6634         made ds390 register extensions look less like error messages
6635
6636 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6637
6638         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6639         reported by Adam Wozniak in Sdcc-user list
6640
6641 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6642
6643         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6644         arithmetic optimizations, added debug output
6645
6646 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6647
6648         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6649         * sdcc.spec: updated and split sdcc into 3 rpms
6650         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6651         needed for literals of LEFT_OP and '+'
6652         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6653         introduced RESULT_TYPE_NOPROM
6654         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6655         left shift
6656         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6657         limited promotion to int only for '*'
6658         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6659
6660 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6661
6662         * src/pic16/gen.c (genSkip),
6663         (genc16bit2lit), (gencjneshort): commented out
6664         (is_LitOp): new helper function, checks operand type
6665         (genCmpEq): rewritten
6666
6667 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6668
6669         * support/regression/tests/bug-908454.c: added
6670
6671 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6672
6673         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6674         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6675         (geniCodeCast): cosmetic, don't preserve bit storage class
6676         (geniCodeLeftShift): added promotion
6677         (geniCodeLogic): fixed regression
6678         * src/SDCCsymt.c (computeTypeOr): accept bits too
6679         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6680
6681 2004-03-07  Borut Razem <borut.razem AT siol.net>
6682
6683         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6684
6685 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6686
6687         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6688         version of pic16_genPackRegisters which does not check if ic is a
6689         CAST operator,
6690         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6691         function cause string1.c regression test fails
6692
6693 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6694
6695         * sim/ucsim/configure.in,
6696         * sim/ucsim/configure,
6697         * sim/ucsim/doc/Makefile.in: use docdir
6698         * src/SDCC.y: fixed sbit atrributes
6699         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6700         * src/SDCCast.c (decorateType): |^& need special promotion handling
6701         * src/SDCCast.h,
6702         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6703         * src/SDCCsymt.h (computeType),
6704         * src/SDCCicode.c: computeType() needs op
6705         * src/SDCCsymt.c (checkTypeSanity),
6706         * doc/sddman.lyx: "plain" bitfields are unsigned
6707         * src/SDCCsymt.c (computeTypeOr): added
6708         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6709         |^& ops
6710         * src/SDCCval.c (val*): computeType() needs op
6711         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6712         * support/regression/tests/onebyte.c: added tests for |^&
6713
6714 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6715
6716         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6717         for writing icode into asm output.
6718
6719 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6720
6721         * src/pic16/device.c: added some debug lines enabled
6722         with macro DEBUG_CHECK,
6723         * src/pic16/genarith.c: more debug in genPlus,
6724         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6725         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6726         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6727         * (aopForSym): onStack symbols are re-placed in data memspace,
6728         and onStack flag is cleared,
6729         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6730         copy temporary pcodeop,
6731         * (genPcall): added warning for not updating PCLATU,
6732         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6733         always true for pic16 port,
6734         * (genMultOneWord): NEW, supports integer multiplication,
6735         * (genMult): modified to call genMultOneWord,
6736         * (ifxForOp): added warning when return NULL,
6737         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6738         flag is set before call to operandFromSymbol for implicit
6739         added structures,
6740         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6741         options.intlong_rent are set by default,
6742         * (_hasNativeMulFor): modified to allow port generation of integer
6743         multiplication,
6744         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6745         set regtype to REG_SFR for all registers, restricting seting the
6746         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6747
6748 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6749
6750         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6751         more than 500 times in the regression tests
6752
6753 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6754
6755         * support/Util/SDCCerr.h,
6756         * support/Util/SDCCerr.c,
6757         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6758         enumerator_list),
6759         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6760         for symbol conflicts.
6761         * support/valdiags/tests/enum.c,
6762         * support/valdiags/tests/tentdecl.c,
6763         * support/valdiags/tests/struct.c: expect possible error messages
6764         referring to original symbol definitions.
6765         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6766         * src/SDCCsymt.h,
6767         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6768
6769 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6770
6771         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6772
6773 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6774
6775         * src/pic16/ralloc.c (newReg): fixed bug #908929
6776
6777 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6778
6779         * src/ds390/gen.c: added missing #include "main.h"
6780
6781 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6782
6783         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6784         checking if symbol is already in set,
6785         * src/pic16/device.h: prototype for checkAddSym,
6786         * src/pic16/gen.c: (_G): added entry interruptvector,
6787         * (assignResultValue): removed some commented out lines,
6788         * (genFunction): check for ISR via sym->type, absolute section for
6789         interrupt code is created via a new pBlock, the goto instruction is
6790         placed now correctly at the interrupt vector position, changed all
6791         references from ivec to _G.interruptvector,
6792         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6793         is the interrupt is a high priority one, same for return from ISR,
6794         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6795         externs to calls of checkAddSym,
6796         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6797         pic16_pcode_verbose flag is set,
6798         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6799         * src/pic16/pcoderegs.c: message about how many registers are saved
6800         will only be emitted if pic16_pcode_verbose flag is set,
6801
6802 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6803
6804         * src/ds390/ralloc.h,
6805         * src/ds390/ralloc.c (ds390_regWithIdx),
6806         * src/ds390/gen.c (emitcode),
6807         * src/ds390/main.h,
6808         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6809         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6810         ds390operandCompare, getRegsRead, getRegsWritten,
6811         initializeAsmLineNode): customized instruction size calculation for
6812         ds390, started basis for some register optimizations
6813         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6814         corresponding assembly output
6815         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6816         missing push/pop of r0/r1. Optimized push/pops
6817
6818 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6819
6820         * src/mcs51/main.c (instructionSize): fixed ACALL size
6821         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6822
6823 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6824
6825         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6826         the sorting of rlist with NULL elements
6827         * (print_idataType, print_idata): NEW to create idata sections
6828         * src/pic16/device.h: idataSymSet new variable
6829         * src/pic16/gen.c (genFunction): fixed some bugs in string
6830         comparing, improved the absolute section creation for ISRs,
6831         added FSR0L/FSR0H in registers that are saved in an ISR,
6832         * (genInline): fixed the processing of inline snippets,
6833         now they undergo no process by the peephole optimizer
6834         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6835         are placed in idataSymSet,
6836         * (pic16emitStaticSeg): extern symbols are added in externs,
6837         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6838         switching when aboslute variables are placed in access bank memory
6839         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6840         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6841         commented out with #if,
6842         * (pic16_packRegisters): reintroduce the check for CAST because some
6843         symbols are not correctly handled,
6844         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6845         pCodeInstruction instead of pCode,
6846         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6847         pCodeAsmDir definition,
6848         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6849         directive, then the argument directive is emitted without the leading
6850         tab, hack for inline labels which must be in the first column,
6851         * (compareLabel,pic16_findNextInstruction),
6852         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6853         * (insertBankSwitch): modified for the new pCodeAsmDir,
6854
6855 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6856         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6857
6858         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6859         instance,
6860         * (pushSide): commented out with #if,
6861         * (assignResultValue): fixed some typos in saving
6862         registers,
6863         * (genPcall): FIXED and sync'ed with genCall,
6864         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6865         * (genNearPointerGet): fixed to handle some more cases,
6866         implementation scheme via table reads,
6867         * (genConstPointerGet): modified to access code memory correct,
6868         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6869         and improved to handle some cases
6870         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6871         instead of "RETLW" for init data
6872         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6873         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6874         variables are placed in access bank memory (<0x80 and >=0xf80),
6875         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6876         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6877         TBLWT_POSTDEC,TBLWT_PREINC
6878         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6879         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6880         directives
6881         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6882         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6883         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6884         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6885
6886 2004-02-29  Borut Razem <borut.razem AT siol.net>
6887
6888         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6889         support/Util/findme.h, support/Util/system.h: enhance binary relative
6890         search for lib and include by using findProgramPath()
6891
6892 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6893
6894         * src/SDCCpeeph.h,
6895         * src/SDCCpeeph.c (pcDistance),
6896         * src/port.h,
6897         * src/mcs51/ralloc.h,
6898         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6899         * src/mcs51/main.h,
6900         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6901         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6902         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6903         size calculation port specific, started basis for some register
6904         optimizations
6905         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6906         missing push/pop of r0/r1. Optimized push/pops
6907         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6908         * device/lib/_modsint.c (_modsint),
6909         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6910         and stack version so regression tests pass
6911
6912 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6913
6914         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6915         * src/SDCCast.c (decorateType): catch another small optimization
6916         with '?' operator
6917         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6918         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6919         modified to finally use computeType() all over SDCC,
6920         see Feature Request #877103
6921         * src/SDCCval.h: cosmetic
6922         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6923         valCompare(); regression tested in muldiv.c
6924         * support/regression/tests/muldiv.c (testMod): mod sign follows
6925         dividend only
6926
6927 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6928
6929         * src/SDCCast.c (decorateType): fixed bug #902362
6930         * doc/INSTALL.txt: fixed install instructions for win32
6931
6932 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6933
6934         * device/include/Makefile.in (install): fixed by replacing spaces
6935         by tabs
6936         * doc/README.txt,
6937         * doc/INSTALL.txt: updated for release
6938         * doc/sdccman.lyx: added warning for --xstack being buggy
6939
6940 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6941
6942         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6943         to eliminate build warnings.
6944         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6945
6946 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6947            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6948
6949         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6950         removed -penable-stack, added comment for stack pragma, added
6951         warning for not initializing the stack/frame registers, removed
6952         comment at interrupts section
6953
6954         Stack is made permanent, there is no ability to disable stack usage.
6955         * src/pic16/device.h,
6956         * src/pic16/device.c: removed all references to USE_STACK macro,
6957         * src/pic16/device.c (pic16_dump_section): when no elements in
6958         rlist, free rlist before return,
6959         * (pic16_dump_int_registers): NEW, internal registers are a new set
6960         of general purpose registers reused by each function,
6961         * (checkAddReg): returns 1 if registers is added to set,
6962         * (pic16_groupRegistersInSection): when a registers is of type
6963         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6964         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6965         SRCASECMP macro is moved here from device.c
6966         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6967         PO_PCLATU, PO_PRODL, PO_PRODH,
6968         * (pic16_pCodeOpType, genMinus,
6969         changed compares to "a" register, with AOP_ACC,
6970         * (pic16_genPlus): fixed some bugs and indented properly,
6971         * (pic16_addSign): changed size to size+offset in the MOVWF
6972         instruction,
6973         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6974         multiply 8-bit operand by literal, result is 8-bit,
6975         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6976         multiply 2 8-bit operand, result is 8-bit,
6977         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6978         genUMult8X*_16,
6979         * src/pic16/gen.c: changed accUse to contain WREG only,
6980         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6981         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6982         true, do not use immediate addressing any more unless sym is a
6983         pointer in codespace,
6984         * (aopForRemat): do not use immediate addressing when symbol not in
6985         codespace and when symbol's address is requested,
6986         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6987         accUse size (= 1),
6988         * (aopGet): added case for AOP_ACC and don't return "accumulator
6989         bug" but WREG instead,
6990         * (popGetTempReg): pushes contents of temporary register in stack,
6991         * (popReleaseTempReg): pops contents of temporary register from
6992         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
6993         * (pic16_popGet): separated case AOP_ACC to return register WREG
6994         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
6995         or PO_IMMEDIATE and initializes their instance/offset appropriately,
6996         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
6997         the use of immediate pointers to certain cases only.
6998
6999         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
7000         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
7001         * (assignResultValue, genCall, genRet): modified to use the new
7002         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
7003         genPcall is still broken,
7004         * (genFunction): added code to create 'A' type pBlocks when
7005         interrupt functions are generated, code not extensively tested yet,
7006         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
7007         * (genEndFunction): modified so ISRs pop stored registers from stack,
7008         * (genMultOneByte): cleanup,
7009         * (AccRsh): added flag andmask, to and result with appropriate mask,
7010         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
7011         * (genDataPointerGet): fixed and reenabled its use,
7012         * (genNearDataPointerGet): bugs fixed,
7013         * (genDataPointerSet): bugs fixed,
7014         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
7015         pic16_DumpSymbol, pic16_DumpOp,
7016         * src/pic16/genutils.h: function prototypes for the above functions,
7017         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
7018         pointers,
7019         * (pic16emitRegularMap): many many many improvements, but needs a
7020         major cleanup,
7021         * src/pic16/main.c: enable_stack in pic16_options is removed,
7022         * (_pic16_parseOptions): removed command line options -penable-stack,
7023         * (_process_pragma): emit stack symbol only when stack pragma is
7024         processed,
7025         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
7026         redirected to FSR0L/FSR0H pair,
7027         * (pic16_get_op, pic16_get_op2): modifications and improvements,
7028         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
7029         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
7030         for immediates,
7031         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
7032         * (dumpPicOptype): NEW,
7033         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
7034         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
7035         with movff instruction,
7036         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
7037         added pic16_int_regs, some packRegsFor* functions are commented out,
7038         because produce errors,
7039         * src/pic16/NOTES: minor modifications
7040
7041 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7042
7043         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
7044         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
7045         --pack-iram.
7046         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
7047         * as/mcs51/lkaomf51.c: fixed bug #895763
7048
7049 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
7050
7051         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
7052
7053 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7054
7055         * doc/sdccman.lyx: added details about the HC08 storage classes and
7056         interrupts, fixed the register usage info for z80 & gbz80
7057
7058 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
7059
7060         * doc/sdccman.lyx: added more pic16 port documentation
7061         * device/include/pic16/: added header pic18fregs.h
7062
7063 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
7064
7065         * doc/sdccman.lyx: added Vangelis' contribution
7066
7067 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7068
7069         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
7070         extend to the next CALL or PCALL, not just to the next CALL.
7071
7072 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
7073
7074         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
7075
7076 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7077
7078         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
7079         bug #895752 and a better fix for bug #716790
7080
7081 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7082
7083         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
7084
7085 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7086
7087         * doc/sdccman.lyx: minor changes, minor changed
7088
7089 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
7090
7091         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
7092         which can't handle SDCC_NEWONEBYTEOPS,
7093         (geniCodeMultiply): removed conversion from mult to shift for pic14
7094         and pic16
7095
7096 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7097
7098         * src/hc08/gen.h,
7099         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
7100         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
7101         thus fixing bug #895406
7102
7103 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
7104
7105         * device/lib/_modsint.c,
7106         * device/lib/_modslong.c: sign follows divisor only
7107         * src/hc08/gen.c (genMultOneByte): if result size is 1,
7108         signs or signedness can be ignored
7109         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
7110         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
7111         added optimization for IFX,
7112         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
7113         arguments;
7114         reenabled optimization for IFX, which was removed on 2004-01-11
7115         * src/SDCCast.h: added return type IFX
7116         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
7117         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
7118         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
7119         SDCC_OLDONEBYTEOPS selects the old behaviour
7120         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
7121         changed again and commented promotion rule
7122         * src/SDCCval.c (valDiv): promotion no longer necessary
7123         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
7124         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
7125         rewritten
7126         * support/regression/tests/onebyte.c: added
7127
7128 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
7129
7130         * gen.c (genInline): reverted to old code for assemnling inline
7131         code because of bug reported James Chadd
7132
7133 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
7134
7135         * ralloc.h: missing declarations from previous patch,
7136         seems that patch for ralloc.h was never applied, fixed
7137
7138 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7139            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7140
7141         * pcode.c,
7142         * pcode.h,
7143         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
7144         indirect addressing. Marked FSR0 as deprecated
7145         * gen.c (pointerCode): commented out, not needed now
7146         (pic16_popGet2p): new MOVFF helper function
7147         (genGenPointerGet),
7148         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
7149         (shiftRLong): removed duplicate debugging info
7150
7151 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7152
7153         * src/ds390/gen.c (genNearPointerGet),
7154         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
7155         optimization with bits, but not bitfields.
7156         * src/ds390/ralloc.c (packRegisters),
7157         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
7158
7159 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
7160
7161         * src/SDCCcse.c (algebraicOpts): copy operands before modification
7162
7163 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7164
7165         * src/SDCCsymt.h,
7166         * src/SDCCicode.c (operandFromSymbol),
7167         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
7168         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
7169         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
7170         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
7171         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
7172         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
7173         bug #892038
7174         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
7175         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
7176         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
7177         * src/SDCCsymt.c (newSymbol),
7178         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
7179         enumerator_list),
7180         * src/SDCCval.h,
7181         * src/SDCCval.c (newiList): fixed bug #885705
7182
7183 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7184
7185         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
7186         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
7187
7188 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7189
7190         * device/include/c8051f120.h,
7191         * device/include/c8051f300.h,
7192         * device/include/c8051f310.h: added/updated header files for Silicon
7193         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7194         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
7195         in new section Submitting patches
7196
7197 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7198
7199         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
7200         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7201         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7202         genGenPointerSet),
7203         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
7204         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7205         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7206         genGenPointerSet),
7207         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
7208         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7209         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7210         genGenPointerSet),
7211         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
7212         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7213         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7214         genGenPointerSet): fixed bug #892400
7215         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
7216         to eliminate build warnings.
7217         * src/SDCCast.c (processParms),
7218         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
7219         fixed bug 751859
7220         * support/valdiag/valdiag.py: added GCC to the list of defines active
7221         when compiling with gcc
7222
7223 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7224
7225         * support/Util/SDCCerr.h,
7226         * support/Util/SDCCerr.c,
7227         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
7228         with an incomplete type (fixed bug #883734)
7229         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
7230
7231 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7232
7233         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
7234
7235 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7236
7237         * src/SDCCast.c (decorateType),
7238         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
7239         function pointer implementation
7240         * support/regression/tests/funptrs.c: added tests to verify both forms
7241         of function pointers work correctly. Added tests to verify parameters
7242         are passed in the correct order.
7243
7244 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
7245
7246         * device.c (regCompare): registers are sorted by ascending
7247         address and increasing size,
7248         * main.c (_pic16_finaliseOptions): removed the declaration
7249         of compiler macro MCU. Now a macro of the format pic18fxxxx
7250         will be defined from the command line
7251
7252 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7253             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7254
7255         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
7256         PCOP_RLCF was overwritten!
7257         * gen.c (genSkip): commented out calls to pic16_emitcode,
7258         * (genCmpEQ): fixed "long" compares, only high word did get compared,
7259         * (genlshTwo),
7260         * (genRRC): added debugging info,
7261         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
7262         overwritten while shifting,
7263         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
7264         overwritten while shifting,
7265         * (AccLsh),
7266         * (AccRsh),
7267         * (shiftLLeftOrResult),
7268         * (shiftRLeftOrResult),
7269         * (shiftRLong),
7270         * (shiftLLong): Implemented with pic16_emitpcode
7271         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
7272         * (genLeftShift): Fixed bug, operand for shift by variable always
7273         was "and"ed with 0x0f,
7274         * (genLeftShiftLiteral),
7275         * (genrshTwo),
7276         * (genRightShiftLiteral): added debugging info,
7277         * (genrshFour): added comment,
7278         * (genRightShift): determined signedness from operand "left"
7279         instead of "result"
7280
7281 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7282
7283         * src/SDCCicode.c (geniCodeParms),
7284         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
7285         function pointers, fixed function pointer bugs #861242 and #861896
7286
7287 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7288
7289         * device/include/c8051f000.h,
7290         * device/include/c8051f120.h,
7291         * device/include/c8051f300.h: added header files for Silicon
7292         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7293
7294 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
7295
7296         * src/SDCCast.c (processParams): added new type flow and restructured
7297         (gatherAutoInit): added new type flow
7298         (addCast): cosmetic changes
7299         (getLeftResultType): added new type flow for array indices, patch
7300         provided by Stas, see FR #877103
7301         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
7302         array index patch by Stas
7303         * src/SDCCast.h: added prototype getResultTypeFromType()
7304         * src/SDCCval.h,
7305         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
7306         * src/pic/glue.c (pic14emitStaticSeg),
7307         * src/pic16/glue.c (pic16emitStaticSeg),
7308         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
7309         for initialization of symbols
7310         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
7311         * support/Util/SDCCerr.h:
7312         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
7313         * .version: bumped version number to 2.3.8
7314         * device/include/Makefile.in (install),
7315         * doc/Makefile (install): changed to 'rm `find ...`' construct to
7316         avoid warnings
7317
7318 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
7319
7320         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
7321         Slade Rich fixed an optimization bug
7322         * src/pic/pcodepeep.c,
7323         * src/pic/pcoderegs.c
7324         * doc/Makefile (install): added test for directory
7325
7326 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7327
7328         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
7329         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
7330         * src/pic/ralloc.c (getRegPtr, getRegGpr),
7331         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
7332         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
7333         * as/mcs51/asexpr.c (term),
7334         * as/hc08/asexpr.c (term): fixed bug #887146
7335
7336 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7337
7338         * src/z80/gen.c (genMult): handle single byte result product
7339         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
7340         DUMMY_READ_VOLATILE (fixed bug #886367)
7341
7342 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7343
7344         * support/regression/tests/libmullong.c: fixed logic, on little endian
7345         hosts we ended without a mullong_wrapper()
7346
7347 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7348
7349         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
7350         virus/worm forged address usage.
7351
7352 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7353
7354         Fixed promotion, it should be done on AST level:
7355         * src/SDCCast.c (addCast): added promotion to int
7356         (decorateType): updated call to upCast()
7357         * src/SDCCicode.c (geniCodeLeftShift): removed call to
7358         usualUnaryConversions()
7359
7360 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
7361
7362         * support/regression/tests/literalop.c (mulWrapper): Added a
7363         wrapper to remove integer overflow warnings.
7364
7365         * support/regression/tests/float_trans.c: Made work on host.
7366
7367         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
7368         location of sz80.
7369
7370         * support/regression/generate-cases.py (main): Changed from inline
7371         to a main method.
7372
7373         * doc/Makefile (install): Changed to depth first to get rid of
7374         missing directory install warning.
7375
7376         * as/Makefile (install-doc): Made work on Mac.
7377
7378 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
7379
7380         * src/SDCCast.c: added an additional type flow in decorateType() of
7381         opposite direction, see feature request #860006; it's enabled at runtime
7382         by setting the environment variable SDCC_NEWTYPEFLOW
7383         * src/SDCCast.h: changed prototype of decorateType()
7384         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
7385         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
7386         'char' to 'int' can be omitted, if both operands are 'unsigned char';
7387         see feature request #877103
7388         * src/SDCCval.c: updated call of decorateType()
7389         (valBitwise): fixed bug #882876
7390         (valMinus): added promotion
7391         (valLogicAndOr): result is unsigned
7392         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
7393         * src/SDCCsymt.c (computeType),
7394         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
7395         must not cause an unsigned operation
7396         * src/pic/glue (pic14emitRegularMap),
7397         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
7398
7399 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
7400
7401         * src/pic/pcode.c (PCodeID): commented out left over debug code
7402
7403 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
7404
7405         * support/valdiag/tests/overflow.c: added shift tests
7406         * src/pic/device.c,
7407         * src/pic/gen.c,
7408         * src/pic/gen.h,
7409         * src/pic/glue.c,
7410         * src/pic/main.c,
7411         * src/pic/pcode.c,
7412         * src/pic/pcode.h,
7413         * src/pic/pcodepeep.c,
7414         * src/pic/pcoderegs.c,
7415         * src/pic/ralloc.c,
7416         * src/pic/ralloc.h: applied patch from Slade Rich;
7417         added support for multiple code pages and multiple RAM banks on the
7418         PIC 14 port. The ASM files now no longer simply assume all the
7419         code / RAM are in the same page / bank. This means the linker can
7420         safely allocate code/RAM of separate ASM files to different pages/banks.
7421         * doc/sdccman.lyx: added Slade's tips
7422         * src/mcs51/peeph.def: fixed bug #880768
7423
7424 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7425
7426         * src/hc08/ralloc.c (rematStr): fixed bug #879282
7427         * src/SDCCast.c (decorateType): fixed bug #880197
7428
7429 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
7430
7431         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
7432         getopt.h.
7433
7434         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
7435         strtof is not part of C89 and isn't included with Mac OS X.
7436
7437 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7438
7439         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
7440         shiftL2Left2Result): fixed bug #879326
7441         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
7442         (genMultOneByte): fixed bug in signed vs unsigned multiplication
7443         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
7444         address fetch for clr instruction
7445         * device/lib/hc08/_mulint.c: created optimized assembly version
7446         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
7447
7448 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
7449
7450         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
7451         proposed in FR #877103
7452
7453 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
7454
7455         * src/SDCCval.c (cheapestVal): added missing checks
7456         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7457         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7458
7459 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7460
7461         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7462         equal operands
7463
7464 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7465
7466         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7467         loaded with the linker search paths (-L arguments) and the libraries
7468         to be linked with the current source (-l arguments). Changes
7469         currently will affect only the pic16 port.
7470         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7471         include path the port specific paths and port specific libraries,
7472         * gplink command now contains the $3 argument,
7473         * src/pic16/device.h,
7474         * src/pic16/device.c,: structure PIC_device is made public and
7475         renamed to PIC16_device, the same for variable Pics which is renamed
7476         to Pics16. Updated all references to them.
7477         * src/pic16/glue.c (pic16glue): corrected bug with code
7478         initialization which bypassed the variable initializations block.
7479
7480         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7481         COMPILE_FLAGS and added the --nostdinc option
7482
7483 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7484
7485         * device/include/mc68hc908jb8.h: Register defs for another member
7486         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7487
7488 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7489
7490         Documenting changes from previous commits.
7491         * configure.in (version 1.56),
7492         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7493         when generating output files to configure the pic16 library,
7494         but now I've commented it out, since gputils aren't installed in the
7495         SF compile farm, so library won't compile
7496
7497         * device/lib/Makefile.in (version 1.56): initially I've added in
7498         target 'all' the prerequestive 'model-pic16' so it compiled the
7499         pic16 library, but now I've commented it out for the same reasons
7500         above,
7501         * added targets 'model-pic16' and 'objects-pic16' to compile the
7502         library
7503         * added target 'port-specific-objects-pic16' to handle the
7504         generated libraries and copy them into the build/ directory
7505         * added target 'clean-intermediate-pic16' to clean intermediate
7506         files into pic16 directory
7507         * in target 'installdirs' added line to create directory pic16 in
7508         the installation path
7509
7510         * device/include/Makefile.in (version 1.11): in target 'install'
7511         added lines to copy all header files to installation path,
7512         * in target 'installdirs' added line create directory for pic16
7513         headers in the installation path
7514
7515 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7516
7517         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7518          a function call
7519
7520 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7521
7522         * configure,
7523         * device/lib/configure.in,
7524         * device/lib/configure: fixed for autoconf 2.57
7525
7526 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7527
7528         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7529         option so that it actually works. Made it specific to the z80, since
7530         the gbz80 doesn't have these kinds of I/O ports.
7531
7532 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7533
7534         * device/include/z180.h,
7535         * device/lib/_memcpy.c,
7536         * device/lib/_memmove.c,
7537         * device/lib/_mulint.c,
7538         * device/lib/ser_ir.c,
7539         * device/lib/ser_ir_cts_rts.c,
7540         * device/lib/_strcmp.c,
7541         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7542         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7543         portmode; added deprecation warning for bank= and protmode= forms.
7544         Also, guard against buffer overflow.
7545         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7546
7547 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7548
7549         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7550         changed interrupt vector table generation to only emit declared vectors.
7551         * device/include/Makefile.in: added missing backslash
7552         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7553
7554 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7555
7556         Mainly changes to support compilation of the device libraries
7557         * src/pic16/device.c: stack is allocated via symbol and not
7558         via literal number. The symbol is placed in the corresponding
7559         position of the data ram
7560         * (pic16_dump_section): relocatable and absolute uninitialized
7561         data are now emitted in sorted order to reduce section naming,
7562         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7563         weren't marked as being in the access bank,
7564
7565 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7566
7567         Added portion of GNU PIC Library under the directory
7568         device/include/pic16 and device/lib/pic16. These files
7569         contain the declarations of SFRs for the PIC18Fxx2 devices.
7570         The directory is initialized via configure from toplevel.
7571
7572 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7573
7574         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7575         the spilllocations to be compared correctly
7576
7577 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7578
7579         * src/SDCCast.c (decorateType): fixed bug introduced today
7580
7581 2004-01-12  Borut Razem <borut.razem AT siol.net>
7582
7583         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7584         doc/sdccman.lyx: upper case pragmas are deprecated
7585
7586 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7587
7588         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7589         in simpler and even better code
7590
7591 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7592
7593         * src/SDCCicode.c (operandOperation): fixed bug #874819
7594         * src/SDCCast.c (decorateType): fixed
7595         char foo (unsigned long ul) { return ul > 0; }
7596
7597 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7598
7599         * doc/sdccman.lyx: Moved and added some sections, small changes
7600         all over. Telling LaTeX to be less strict with word spacing
7601         to better keep the right margin. Changed some notes about
7602         maintainance of the ports in section 3.2.1 - is it OK like this?
7603
7604 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7605
7606         SDCC source changes:
7607         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7608         convilong): modified to inform the pic16 port that builtin functions
7609         are external
7610
7611         PIC16 PORT specific changes:
7612         * src/pic16/device.c pic16_dump_equates() added,
7613         processor registers declared internally by the port are emitted in
7614         the translation as equates,
7615         * src/pic16/gen.c: inline code is passed unprocessed to the
7616         translation,
7617         * (pic16_popGetLit2): fnuction modified to take second operand as
7618         pCodeOp pointer and not as literal,
7619         * (popRegFromIdx): prefixed with pic16_,
7620         * (pic16_popCombine2): modified to receive already allocated pCode
7621         operands,
7622         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7623         * (genFunction): initializes local stack frame and pushes on stack
7624         all the registers used by this function,
7625         * (genEndFunction): restores all registers from stack and restores
7626         stack frame,
7627         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7628         improvements,
7629         * (pic16glue): changed the program startup sequence,
7630         * added new dbName code 'A' for functions placed in absolute section
7631         * src/pic16/main.c: added function attribute _naked,
7632         * added pragma 'code' to place a fnuction at an absolute address,
7633         * added command line arguments --debug-ralloc and --pcode-verbose,
7634         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7635         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7636         * (pic16_newpCodeOpLit2): modified to take the second operand as
7637         pCodeOp pointer,
7638         * (pic16_printpBlock): modified to emit each function in a separate
7639         section,
7640         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7641         UPPER for immediate operands,
7642         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7643         instruction,
7644         * src/pic16/peeph.def: all peepholes with movff are commented out,
7645         because there is a problem in the pcode peep optimizer,
7646         * src/pic16/ralloc.c: the register allocator can now reuse local
7647         function symbols for another function. This saves register usage.
7648         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7649
7650         Added file src/pic16/NOTES with information about program writing on
7651         the current port version.
7652
7653 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7654
7655         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7656         and peephole 252 (array access)
7657
7658 2004-01-09  Borut Razem <borut.razem AT siol.net>
7659
7660         * src/SDCCmain.c : fixed #872250: -l command line defined library
7661           files are scanned before standard library files
7662
7663 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7664
7665         * src/SDCCast.c (decorateType): fixed bug #874046
7666
7667 2004-01-09  Borut Razem <borut.razem AT siol.net>
7668
7669         * support/scripts/sdcc.nsi: remove previous installation
7670
7671 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7672
7673         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7674         bytes for last interrupt vector (mcs51)
7675         * sdcc.spec: fixed typo
7676
7677 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7678
7679         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7680         gen51Code): more efficient parameter receive for --model-large
7681         ("bug" #845294)
7682
7683 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7684
7685         * src/ds390/main.c,
7686         * src/z80/main.c: added missed needLinkerScript flags (more than
7687         one port structure defined in these file)
7688         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7689         bug #795325
7690
7691 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7692
7693         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7694         * src/port.h: added flag needLinkerScript in port->linker
7695         structure to inform whether to create a .lnk file or not,
7696         * src/avr/main.c,
7697         * src/ds390/main.c,
7698         * src/hc08/main.c,
7699         * src/mcs51/main.c,
7700         * src/pic/main.c,
7701         * src/pic16/main.c,
7702         * src/xa51/main.c,
7703         * src/z80/main.c: changed appropriately to configure
7704         needLinkerScript flag
7705         * src/pic/gen.c,
7706         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7707         * src/pic/glue.c: added variable udata_section_name to
7708         override default uninitialized data segment definition for
7709         devices only with SHAREBANK memory (reported from Erik Epetrich)
7710         * (pic14emitOverlay): modified to emit a commented overlay segment
7711         directive when no overlay data exist
7712         * (picglue): modified to emit uninitialized data segment
7713         according to udata_section_name
7714         * src/pic/main.c (_pic14_parseOptions): added command line
7715         options --udata-section-name=[name] to override default
7716         udata definition name
7717         * modified _linkCmd and _asmCmd to include compiler passed
7718         arguments via -W option
7719         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7720         object file from '.rel' to '.o' in port->linker structure,
7721         changed size of fptr from 2 to 3 in port structure
7722
7723 2004-01-07  Borut Razem <borut.razem AT siol.net>
7724
7725         * support/scripts/sdcc.nsi: update PATH
7726         * support/scripts/sdcc.ico: craeted
7727
7728 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7729
7730         * device/include/Makefile.in: fix install
7731         * doc/Makefile: fix install
7732
7733 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7734
7735         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7736         in bug #860505
7737         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7738         how the function variable allocation summary is displayed; also
7739         include information about variables allocated to the overlay
7740         segment
7741
7742 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7743
7744         * as/mcs51/lkmain.c: Help about -Y option
7745         * as/mcs51/lkarea.c: Fixed gcc warnings
7746
7747 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7748
7749         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7750         fixed warning
7751         * support/valdiag/tests/overflow.c: added
7752         * src/SDCCast.c (decorateType),
7753         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7754         LEFT_OP (left shift)
7755
7756 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7757
7758         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7759         (default behaviour).
7760
7761 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7762
7763         A python script to validate compiler diagnostic messages. It can be
7764         used to verify that sdcc complains about bad c source code and
7765         gives a good location of the error.
7766         * support/valdiag/Makefile,
7767         * support/valdiag/valdiag.py,
7768         * support/valdiag/tests/*
7769
7770 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7771
7772         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7773         * src/SDCCsymt.c (newEnumType),
7774         * src/SDCCsymt.h
7775         * support/Util/SDCCerr.c,
7776         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7777         enum related bugs.
7778         * support/regression/tests/enum.c: added test for enum values that
7779         require at least 2 bytes of storage.
7780
7781 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7782
7783         * src/common.h: added ifndef/define/endif macros
7784         around the header file.
7785         Bug reported from Jesus Calvino-Fraga
7786
7787 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7788
7789         * sdcc.spec: updated
7790         * device/include/Makefile.in: don't install CVS directories
7791         * device/lib/Makefile.in: added removal of CVS directories after install
7792         * doc/Makefile: fixed install, added local_icons
7793         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7794         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7795         * src/ds390/gen.c (genRightShift): fixed bug #870788
7796         * src/SDCCast.c (decorateType): fixed bug #870781
7797
7798 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7799
7800         PIC16 port related changes:
7801         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7802         added variable stackPos,
7803
7804         * gen.c: genCall, assignResultValue: added support for
7805         pushing/retrieving function parameters to/from stack,
7806         genFunction,genEndFunction: setup stack frame for the
7807         generated function,
7808         genAddrOf: will be changed according to bug 863624
7809
7810         * added files genutils.c and genutils.h which contain gen*
7811         debugged and optimised functions extracted from gen.c
7812
7813         * glue.c: added variable 'externs' which holds extern symbols,
7814         pic16emitRegularMap: is modified to properly handle relocatable
7815          symbols under the new scheme,
7816         pic16createInterruptVect: is modified
7817         pic16printPublics: is modified to emit 'global' assembler directives,
7818         added pic16_printExterns to print extern symbols,
7819         pic16glue: initializes stack/frame pointer in the beginning of
7820         the assembly output. Temporary hack, will be corrected later,
7821         because gplink yet does not support stack and SDCC does not
7822         yet support a type of crt0.o object to create the final binary.
7823
7824         * Removed many lines that contain 8051 legacy code.
7825         * The code is finally placed under a 'code' directive.
7826         * Added port specific options.
7827
7828         * _process_pragma: simplified since now we do not need *special*
7829         include file to define SFR registers. But a separate header
7830         will be needed. This will be developed later.
7831         * _pic16_parseOptions: added, parses port specific options:
7832         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7833         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7834         --preplace-udata-with=
7835
7836         * _pic16_setDefaultOptions: modified to initialize section names,
7837         but hack is temporarly out of order since it needs improvement.
7838         * _pic16_genAssemblerPreamble: configuration words are emitted by
7839         their address instead of their name. This part is incomplete and
7840         supports only the 18Fxx2 devices. Other devices will emit an error
7841         during assembly since they do not contain the same set of config
7842         registers
7843         * _pic16_genIVT: is modified,
7844
7845         * pcode.c: added definitions for some hardware registers that are needed
7846         for stack support
7847         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7848         All PCI entries are updated. Now LFSR is supported.
7849         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7850         * added pic16_newpCodeOpLit2 to support instructions with
7851         two literal arguments
7852         * pic16_pCode2str: corrected code that emits assembler instructions
7853         with two literal operands and those that have an access bit modifier
7854         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7855         this fixes a bug which caused some labels to be lost, when an
7856         assembler directive was added, i.e. banksel,
7857         * pic16_FixRegisterBanking: improved logic that causes the insertion
7858         of bank switching,
7859         * InlineFunction: functions that are called once, are not any more
7860         inlined. This can be a port option in the future,
7861
7862         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7863
7864         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7865         hold the corresponding uninitialized symbols,
7866         * pic16_allocProcessorRegister: registers have explicit marked the
7867         accessBank field,
7868         * pic16_allocInternalRegister: registers are explicit marked as
7869         not used,
7870         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7871         processing list, so bit registers were lost,
7872         *
7873
7874         * ralloc.h: added field 'accessBank' and original symbol operand
7875         in register definition,
7876         * removed the field isMapped from register definition,
7877
7878         ** Several functions have been removed from various sources:
7879         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7880         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7881         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7882         pic16_assignRelocatableRegisters
7883
7884         ** others have been introduced:
7885         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7886         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7887
7888 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7889
7890         * support/scripts/inc2h.pl: changed definition of BIT_AT
7891         to emit 'sbit at' instead of 'bit at'. This was a request.
7892
7893         PIC16 port related preliminary changes:
7894         * gen.c: prefixed function popRegFromString with
7895         pic16_ and all references to it corrected
7896         * pcode.c: all pic16_pc_* hardware registers prefixed
7897         with underscore (_),
7898         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7899         * ralloc.c: newReg(): when register is REG_SFR then
7900         set address to rIdx,
7901         pic16_allocProcessorRegister(): marks register wasUsed=0
7902         pic16_writeUsedRegs(): added a call to assign processor
7903         registers via pic16_assignFixedRegisters
7904
7905 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7906
7907         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7908         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7909         variables in unused register banks.  Also the SSEG is placed
7910         wherever there is enough space for it, and IDATA can be anywhere
7911         in internal RAM.  For now compile using -Wl-Y[stack_size].
7912         The mem file is different for this option as well, since it
7913         makes no sense of talking about DSEG lenght.
7914
7915 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7916
7917         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7918         in certain cases, e.g. when ROM assignment, patch provided
7919         from Albert den Haan.
7920
7921 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7922
7923         Many signedness and type propagation fixes:
7924         * src/SDCCicode.c: made geniCodeCast() static
7925         replaced SPEC_ by IS_ (cosmetic)
7926         (operandOperation): fixed div and mod operation
7927         (usualBinaryConversions): added support for promotion of char
7928         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7929         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7930         (geniCodeAdd): an array index will stay unsigned, even if promoted
7931         from char to int
7932         (geniCodeArray): ditto
7933         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7934         * src/SDCCsymt.c (computeType): added more support for char;
7935         promotion of char is selectable by promoteCharToInt, fixed signedness
7936         for all cases
7937         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7938         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7939         * src/SDCCval (val*): replaced signedness calculation by
7940         computeType()
7941         rearranged if-branches (cosmetic)
7942         (valShift): added warning W_SHIFT_CHANGED
7943         (valCompare): fixed problem with different types
7944         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7945         * support/regression/tests/literalop.c: added many cases
7946         * support/regression/tests/ast_constant_folding.c: changed finally to
7947         'unsigned int'
7948         * .version: new year, new version: 2.3.7
7949         * src/SDCCmain.c (main): applied patch #866468
7950         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7951         provided by Scott Bronson
7952         * doc/sdccman.lyx: updated documentation for sdcdb
7953         updated and added chapter tips
7954
7955 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7956
7957         * src/SDCCsymt.h: missing from yesterday's commits
7958
7959 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7960
7961         * src/SDCC.y (struct_or_union_specifier),
7962         * support/Util/SDCCerr.c,
7963         * support/Util/SDCCerr.h: verify that struct & union tags are used
7964         as declared.
7965
7966 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7967
7968         * src/SDCCglobl.h: missing from yesterday's commits
7969
7970 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7971
7972         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7973         sft_attributes, struct_declaration, parameter_declaration,
7974         type_name, start_block, declaration_list),
7975         * src/SDCC.lex (check_type): support redefinition of typedef names
7976
7977 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7978
7979         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7980         aligned xdata arrays. Erik helped me with the if clause.
7981
7982 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7983
7984         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7985         warning
7986
7987 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7988
7989         * src/SDCCast.h,
7990         * src/SDCCast.c (newAst_),
7991         * src/SDCCicode.h,
7992         * src/SDCCicode.c (ast2iCode, newiCode),
7993         * src/SDCCglobl.h,
7994         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
7995         expr, statement, expression_statement, selection_statement,
7996         iteration_statement, expr_opt, jump_statement): foundation for tracking
7997         sequence points
7998         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
7999         point code too)
8000
8001 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8002
8003         * support/Util/SDCCerr.c,
8004         * src/SDCCast.h,
8005         * src/SDCCast.c (createCase, createDefault, decorateType),
8006         * src/SDCClabel.c (labelUnreach),
8007         * src/SDCC.y (labeled_statement, jump_statement): More improvements
8008         to error messages.
8009         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
8010         (with thanks to Stas Sergeev)
8011         * device/include/time.h,
8012         * device/lib/time.c (CheckTime): suppress unreachable code warning
8013
8014 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8015
8016         * src/SDCCast.c (createIvalCharPtr),
8017         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
8018         bug #753752)
8019         * support/regression/tests/nullstring.c: tests for these two bugs
8020
8021 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8022
8023         * support/Util/SDCCerr.h,
8024         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
8025         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
8026         about storage class and 'at' used inside struct or union
8027         * src/SDCCBBlock.c (iCodeFromeBBlock),
8028         * src/SDCCcse.c (ifxOptimize),
8029         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
8030         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
8031         printIval, emitStaticSeg, emitOverlay),
8032         * src/SDCClabel.c (deleteIfx),
8033         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
8034         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
8035         gatherAutoInit, processParms),
8036         * support/Util/SDCCerr.h,
8037         * support/Util/SDCCerr.c (werrorfl): Support for better error location
8038         reporting for post-parse errors.
8039
8040 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8041
8042         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
8043         implicit casts via union; they don't work on big endian systems
8044         (possible fix for bug #861138)
8045
8046 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8047
8048         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
8049         * src/mcs51/main.c: fixed the fix for bug #737001
8050
8051 2003-12-15  Borut Razem <borut.razem AT siol.net>
8052
8053         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
8054
8055 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8056
8057         * support/makebin/makebin.c: put output in binary mode
8058
8059 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8060
8061         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
8062         xdata and data memory on startup. Set the environment variable
8063         SDCC_NOGENRAMCLEAR to disable this.
8064         * src/mcs51/peephole.def,
8065         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
8066         (allows non-interrupt and interrupt code to safely compete for a resource
8067         without the non-interrupt code having to disable interrupts)
8068
8069 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8070
8071         * src/SDCCicode.c (geniCodeAdd),
8072         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
8073         with valFromType if type might be a pointer and host is big endian).
8074         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
8075         types, not just integer types.
8076         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
8077         multiply defined with mismatching "at" address.
8078
8079 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8080
8081         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
8082         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
8083         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
8084         with embedded nulls (fixed bug #753752)
8085
8086 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8087
8088         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
8089         Apparently this did not see much testing (endless loop)
8090
8091 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8092
8093         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
8094
8095 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8096
8097         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
8098         gracefully handle NULL memmap pointers
8099
8100 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8101
8102         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
8103         instead of deleting the iCode when an operand is volatile
8104         * src/z80/gen.c (genDummyRead),
8105         * src/mcs51/gen.c (genDummyRead),
8106         * src/ds390/gen.c (genDummyRead),
8107         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
8108         not just IC_RIGHT
8109         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
8110         * src/SDCC.y: fixed bug #850420
8111
8112 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8113
8114         Applied z80 i/o port patch from Peter Townson and fixed some operators
8115         to better handle operands in A register.
8116         * device/include/z180.h
8117         * src/SDCC.y
8118         * src/SDCCglue.c
8119         * src/z80/gen.c
8120         * src/z80/gen.h
8121         * src/z80/main.c
8122         * src/z80/peeph-z80.def
8123         * src/z80/peeph.def
8124         * src/z80/z80.h
8125
8126 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8127
8128         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
8129
8130 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8131
8132         * device/lib/hc08/_mullong.c: Removed extra #endif
8133
8134 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8135
8136         * sim/ucsim/hc08.src/inst.cc,
8137         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
8138         carries from x to h
8139         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
8140         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
8141         * device/include/stdarg.h: fixed varargs for hc08
8142         * device/lib/Makefile.in,
8143         * device/lib/hc08/Makefile,
8144         * device/lib/hc08/_mulint.c,
8145         * device/lib/hc08/_mullong.c: fixed some endian problems
8146
8147 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8148
8149         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
8150         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
8151         * device/lib/_gptrget.c,
8152         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
8153
8154 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8155
8156         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
8157         * src/SDCCast.c (astErrors): fixed bug #846007
8158         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
8159
8160 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8161
8162         * src/SDCCast.c (decorateType): disabled a transformation I added in
8163         revision 1.188 (access to fields of a structure at an absolute address);
8164         it breaks with bitfields, extern declarations, and gcse analysis.
8165         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
8166         could be assigned through a pointer, so don't complain.
8167         * src/SDCCast.c (astErrors),
8168         * src/SDCCast.h,
8169         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
8170
8171 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
8172
8173         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
8174         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
8175         output of __config directives, since gpasm now supports them
8176         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
8177         pre-processor macro, i.e. -DMCU=p18f452
8178         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
8179         and modified to handle 'cast' icode similarly to '=' icode
8180         * src/pic16/device.h (typedef struct PIC_device): added field
8181         'extMIface' to indicate that chip has external memory interface
8182         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
8183         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
8184         18F8720
8185
8186 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8187
8188         * src/SDCC.y (pointer): fixed bug #846006
8189         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
8190         * src/SDCCast.c (decorateType): fixed bug #846009
8191         * src/ds390/peeph.def,
8192         * src/ds390/gen.c (genAnd, genOr),
8193         * src/mcs51/peeph.def,
8194         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
8195
8196 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8197
8198         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
8199         * src/SDCCdflow.c
8200         * src/SDCCcse.c
8201         * src/SDCCcse.h
8202         * src/SDCCBBlock.h
8203         * src/SDCCBBlock.c
8204
8205 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
8206
8207         fixed bug #845089
8208         * src/SDCCbitv.h,
8209         * src/SDCCbitv.c: added function to free a bitvector
8210         * src/SDCClrange.h,
8211         * src/SDCClrange.c: added function to recompute the liveranges
8212         * src/avr/ralloc.c,
8213         * src/ds390/ralloc.c,
8214         * src/hc08/ralloc.c,
8215         * src/mcs51/ralloc.c,
8216         * src/pic/ralloc.c,
8217         * src/pic16/ralloc.c,
8218         * src/xa51/ralloc.c,
8219         * src/z80/ralloc.c: recompute the liveranges after register packing
8220
8221 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
8222
8223         * src/SDCCloop.c (newInduction): fixed bug #845630
8224
8225 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8226
8227         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
8228         inadvertantly left behind from my 2003-11-12 change
8229
8230 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8231
8232         Updated headers I neglected to commit yesterday.
8233         * src/SDCClrange.h,
8234         * src/SDCCicode.h
8235
8236 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8237
8238         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
8239         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
8240         * src/SDCCopt.c (eBBlockFromiCode),
8241         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
8242         the creation of the key hash table from the sequencing so it can be used
8243         earlier (for some GCSE bug fixes still pending)
8244
8245 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8246
8247         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
8248         * support/regression/tests/addsub.c: testing genPlus shortcut
8249
8250 2003-11-15  Borut Razem <borut.razem AT siol.net>
8251
8252         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
8253
8254 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8255
8256         * src/SDCCcse.c (cseBBlock): fixed bug #527779
8257         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
8258         ordering is immaterial.
8259         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
8260
8261 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8262
8263         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
8264         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
8265         (SIGSEV) of bug #840381
8266         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
8267         unlink new file before rename if new and old filenames are the same)
8268
8269 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8270
8271         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
8272         uninitialized variables) for the mcs51. Set environment variable
8273         SDCC_GENRAMCLEAR to test.
8274         xdata initialization slightly shorter
8275
8276 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8277
8278         * src/SDCCsymt.h,
8279         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
8280         #838241 & 780691 (basicly the same bug)
8281         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
8282         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
8283
8284 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
8285
8286         * src/SDCCmain.c (linkEdit): "fix" #834252
8287
8288 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8289
8290         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
8291         * src/SDCCast.h,
8292         * src/SDCC.y: fixed bug #819403
8293
8294 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8295
8296         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
8297         the reentrant attribute.
8298         * src/hc08/gen.c (genPackBits): added missing stack readjustment
8299         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
8300         simulation
8301         * src/SDCCast.c (decorateType): fixed bug with storage class not being
8302         updated during pointer dereference; f.e. ~(((char *)1)*) was being
8303         erroneously reduced to a literal.
8304         * src/hc08/ralloc.c (packRegisters, rematStr),
8305         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
8306         some cases
8307
8308 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8309
8310         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
8311         * doc/sdccman.lyx: changed from 'article' to 'book'
8312         * doc/Makefile: readded test_suite_spec and cdbfileformat
8313
8314 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
8315
8316         * device/include/stdlib.h: include malloc.h to comply with ANSI
8317         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
8318
8319 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8320
8321         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
8322         * doc/clean.mk: also remove *.out files
8323         * doc/sdccman.lyx: some additions, larger top/bottom margins
8324
8325 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8326
8327         * src/SDCC.y: fixed bug #837365
8328         * support/regression/tests/bitopcse.c
8329         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
8330         a symbol (might be valop instead)
8331         * device/lib/Makefile.in: added errno.c to HC08SOURCES
8332         * device/lib/clean.mk: added hc08 to the cleaning list
8333
8334 2003-11-04  Borut Razem <borut.razem AT siol.net>
8335
8336         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
8337           made 2003-11-04
8338         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8339           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
8340           malloc is declared in standard stdlib.h
8341
8342 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8343
8344         * device/lib/hc08/Makefile: need to clean .rel not .o files
8345         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
8346
8347 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8348
8349         * src/port.h,
8350         * src/hc08/main.c,
8351         * src/mcs51/main.c,
8352         * src/ds390/main.c,
8353         * src/z80/main.c,
8354         * src/avr/main.c,
8355         * src/pic/main.c,
8356         * src/pic16/main.c,
8357         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
8358         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
8359         tests (which uses the port's oclsExpense function)
8360         * src/SDCC.y,
8361         * src/SDCCast.c,
8362         * src/SDCCicode.c,
8363         * src/hc08/gen.c,
8364         * src/ds390/gen.c,
8365         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
8366
8367 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8368
8369         * src/SDCCcse.c (ifxOptimize),
8370         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
8371         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
8372         deleting the IFX iCode.
8373         * src/hc08/ralloc.c: reduced unneeded slocs
8374         * src/hc08/gen.c: fixed bug in asmopToBoolean
8375
8376 2003-11-04  Borut Razem <borut.razem AT siol.net>
8377
8378         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
8379           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8380           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
8381           transferred to configure
8382
8383 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
8384
8385         Use headers defined in the C[++] standards:
8386         * sim/ucsim/gui.src/serio.src/fileio.cc
8387         * sim/ucsim/gui.src/serio.src/frontend.cc
8388         * sim/ucsim/gui.src/serio.src/main.cc
8389         * sim/ucsim/gui.src/serio.src/posix_signal.cc
8390         * support/Util/NewAlloc.c
8391         * as/hc08/lklibr.c
8392         * as/mcs51/lklibr.c
8393         * as/z80/aslist.c
8394         * as/z80/assym.c
8395
8396 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8397
8398         * Added MSVC projects for hc08 assembler and linker:
8399         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
8400         /as/hc08/link_hc08.dsp
8401
8402 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
8403
8404         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
8405
8406 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
8407
8408         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
8409
8410 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8411
8412         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
8413
8414 2003-10-31  Borut Razem <borut.razem AT siol.net>
8415
8416         * support/cpp2/cpplib.h,
8417           support/cpp2/cpplib.c,
8418           support/cpp2/cpplex.c,
8419           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
8420           to switch _asm block preprocessing on / off. Default is
8421           #pragma preproc_asm +
8422
8423 2003-10-31  Borut Razem <borut.razem AT siol.net>
8424
8425         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
8426           when outputting comment blocks (when executed with -C option) and
8427           _asm (SDCPP specific) blocks
8428
8429 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8430
8431         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
8432
8433 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
8434
8435         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
8436
8437 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
8438
8439         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
8440         * src/SDCCast.c (decorateType): fixed bug #832664
8441
8442 2003-10-31  Borut Razem <borut.razem AT siol.net>
8443
8444         * support\cpp2\cpplex.c: fixed for SDCPP:
8445           comments(when executed with -C option) and _asm blocks
8446           were included even if they where in skipped #if block.
8447           Applied solution from GCC cpp 3.3.2
8448
8449 2003-10-31  Borut Razem <borut.razem AT siol.net>
8450
8451         * src/SDCC.lex: sdcc now understands both formats:
8452           '# <line_number> <file_name>' and
8453           '#line <line_number> <file_name>'
8454         * support/cpp2/cppmain.c: sdcpp now generates the standard
8455           '# <line_number> <file_name>' instead of former
8456           '#line <line_number> <file_name>'
8457
8458 2003-10-30  Borut Razem <borut.razem AT siol.net>
8459
8460         * support/cpp2/cpphash.h,
8461         * support/cpp2/cpplib.h
8462         * support/cpp2/cpplex.c,
8463         * support/cpp2/cppmain.c,
8464         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8465
8466 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8467
8468         Fixed a number of problems revealed by bug #827883.
8469         * src/SDCCloop.c (loopInvariants): Spill location of the
8470         result operand should be recomputed if extracted from
8471         a loop. Also, don't extract assignments of an iTemp
8472         from a literal.
8473         * src/SDCCast.c (isConformingBody): loop reversal should
8474         not occur if the control variable is involved with a
8475         relational operator.
8476
8477 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8478
8479         * .version: bumped to 2.3.6 to reflect the big improvements
8480         made by Erik and Klaus. Thanks!
8481
8482 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8483
8484         Replaced the livrange code.
8485         * src/SDCClrange.c: added new LR code
8486         * src/SDCCloop.c,
8487         * src/SDCCBBlock.h: removed remainig parts from old LR code
8488         * src/ds390/ralloc.c,
8489         * src/ds390/gen.c: minor fixes to make it work with new code
8490
8491 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8492
8493         * as/hc08/asm.h,
8494         * as/hc08/lkrloc.c,
8495         * src/hc08/gen.c,
8496         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8497         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8498         (tweaked fix for bug #818696)
8499
8500 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8501
8502         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8503
8504 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8505
8506         * src/SDCCmain.c,
8507         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8508         * src/mcs51/gen.c (gencjneshort),
8509         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8510         more efficient (per Scott Bronson's suggestion)
8511
8512 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8513
8514         Extended the semantics of the critical keyword to include
8515         individual statements. See RFE #827755 and #799831
8516         * src/SDCC.y
8517         * src/SDCCicode.c
8518         * src/SDCCopt.c
8519         * src/SDCCast.c
8520         * support/Util/SDCCerr.c
8521         * support/Util/SDCCerr.h
8522         * src/mcs51/gen.c
8523         * src/ds390/gen.c
8524         * src/hc08/gen.c
8525
8526 2003-10-19  Borut Razem <borut.razem AT siol.net>
8527
8528         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8529
8530 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8531
8532         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8533         Fixed bug #818696
8534         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8535         and predecrement operand is displayed
8536
8537 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8538
8539         * src/SDCCval.c (valMinus): fixed bug #826041
8540
8541 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8542
8543         Some hc08 related updates that I missed earlier
8544         * sim/ucsim/stypes.h
8545         * support/regression/ports/hc08/spec.mk
8546
8547 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8548
8549         New target "hc08" for the Motorola 68hc08 family of micros
8550
8551         * configure
8552         * configure.in
8553         * Makefile
8554         * src/hc08/*
8555         * src/SDCCmain.c
8556         * src/port.h
8557         * sim/ucsim/hc08.src/*
8558         * sim/ucsim/configure.in
8559         * src/ucsim/configure
8560         * sim/ucsim/packages_in.mk
8561         * as/hc08/*
8562         * as/Makefile
8563         * device/include/mc68hc908qy.h
8564         * device/lib/hc08/*
8565         * device/lib/Makefile.in
8566         * support/regression/ports/hc08/*
8567         * support/regression/Makefile
8568
8569 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8570
8571         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8572         regression test
8573         * src/ds390/gen.c (genCast): fixed bug #821957
8574
8575 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8576
8577         * device/lib/logf.c: "fixed" overlay bug
8578         * support/regression/ports/host/spec.mk: added m library
8579         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8580         * support/regression/tests/float_trans: added (for Eric)
8581
8582 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8583
8584         * src/mcs51/gen.c (genCpl): fixed bug
8585         http://sf.net/mailarchive/message.php?msg_id=6263915
8586
8587 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8588
8589         * src/SDCCast.c (decorateType): added extended constant folding
8590         * src/SDCCsymt.c (computeType): cleanup
8591         * src/SDCCval.c (valShift): minor optimization
8592         * support/regression/tests/ast_constant_folding.c: added
8593
8594 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8595
8596         * src/SDCCmain.c: removed some unintended changes
8597
8598 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8599
8600         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8601         * src/z80/gen.c: fixed part of bug #817589
8602         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8603
8604 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8605
8606         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8607         * src/SDCCcflow.c
8608         * src/SDCCcse.c
8609         * src/SDCCdflow.c
8610         * src/SDCClabel.c
8611         * src/SDCClrange.c
8612         * src/SDCCmem.c
8613         * src/SDCCopt.c
8614         * src/SDCCpeeph.c
8615         * src/SDCCset.c
8616         * src/avr/ralloc.c
8617         * src/ds390/ralloc.c
8618         * src/izt/ralloc.c
8619         * src/mcs51/ralloc.c
8620         * src/pic/ralloc.c
8621         * src/pic16/ralloc.c
8622         * src/xa51/ralloc.c
8623         * src/z80/ralloc.c
8624         * src/z80/gen.c: removed unused label "release:"
8625
8626 2003-10-06  Borut Razem <borut.razem AT siol.net>
8627
8628         * src/SDCC.lex: removed definition of unused variables
8629           save_optimize and save_options
8630
8631 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8632
8633         * clean.mk: removed '=' in "-maxdepth=1"
8634         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8635         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8636
8637 2003-10-06  Borut Razem <borut.razem AT siol.net>
8638
8639         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8640           my_unput() replaced by unput()
8641
8642 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8643
8644         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8645         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8646         type-punned pointer will break strict-aliasing rules"
8647         Old LR behaviour is again default; Klaus' LR can be choosen by
8648         defining the environment variable LRKLAUS
8649         * src/SDCCBBlock.h
8650         * src/SDCCloop.c
8651         * src/SDCClrange.c
8652         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8653         * clean.mk: fixed removal of files in bin/CVS/
8654         * device/lib/clean.mk: fixed removal of directories small and large
8655         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8656         * src/SDCCicode.c,
8657         * src/SDCCval.c: removed superflous test for pedantic
8658
8659 2003-10-05  Borut Razem <borut.razem AT siol.net>
8660
8661         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8662           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8663           message "unmatched #pragma SAVE and #pragma RESTORE"
8664
8665 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8666
8667         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8668           assembly, critical functions, atomic, nojtbound)
8669
8670 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8671
8672         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8673         * src/SDCCBBlock.h
8674         * src/SDCCloop.c
8675         * src/SDCCloop.h
8676         * src/SDCClrange.c
8677
8678 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8679
8680         * src/z80/gen.h,
8681         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8682         * src/mcs51/gen.h
8683         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8684         * src/ds390/gen.h
8685         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8686         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8687         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8688
8689 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8690
8691         * src/z80/gen.c (genRet): fixed bug #524753
8692         * src/z80/gen.c (genCast): fixed internal error on cast from
8693         pointer to long
8694         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8695         fix for bug #477835 to the z80
8696         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8697         for tracking iCodes in the peephole optimizer for z80
8698
8699 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8700
8701         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8702         the other part of bug #814548
8703         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8704
8705 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8706
8707         * src/SDCCcse.c: fixed part of bug #814548
8708
8709 2003-09-28  Borut Razem <borut.razem AT siol.net>
8710
8711         * src/asm.c: rewrite of printILine() to use temporary file instead
8712           a pipe
8713         * src/xa51/main.c: commented out declaration of int rewinds
8714
8715 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8716
8717         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8718
8719 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8720
8721         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8722         * src/asm.c (printILine): Fixed bug #811015
8723
8724 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8725
8726         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8727         freeing.
8728
8729 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8730
8731         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8732         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8733         to correctly handle general case of AOP_PAIRPTR
8734         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8735
8736 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8737
8738         * src/mcs51/ralloc.c (fillGaps),
8739         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8740         register positioning bug)
8741
8742 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8743
8744         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8745
8746 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8747
8748         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8749         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8750         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8751         (ralloc doesn't intentionally do this now, but perhaps later)
8752         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8753         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8754         register positioning bugs (Fixed bug #762602 and #795325)
8755         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8756         (Fixed bug #808779)
8757         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8758         lines that --i-code-in-asm generates
8759
8760 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8761
8762         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8763         trying to fclose a FILE* that was already closed.
8764
8765 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8766
8767         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8768         of const struct should be treated as if const themselves)
8769
8770 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8771
8772         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8773
8774 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8775
8776         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8777         Unix (/n) and DOS (/r/n) line terminations.
8778
8779 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8780
8781         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8782         bug #613775
8783
8784 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8785
8786         * src/mcs51/gen.c (genFunction, genEndFunction),
8787         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8788         and restore of EA so that stack offsets to parameters are
8789         correct when using both critical and reentrant/stack-auto.
8790         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8791         size (can be triggered in error if sloc is shared between
8792         different sized objects)
8793         * device/include/float.h: fixed macros to explicitly use
8794         unsigned long where needed
8795
8796 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8797
8798         Feature req. 799831: added code to allow nesting of critical functions
8799         * src/mcs51/gen.c (genFunction, genEndFunction)
8800         * src/ds390/gen.c (genFunction, genEndFunction)
8801
8802 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8803
8804         * src/SDCCsymt.c (sclsFromPtr),
8805         * src/SDCCsymt.h,
8806         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8807         support for standard C idiom of memory mapped variables; for
8808         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8809         to xdata int at 0x1234 tempvar = 1.
8810         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8811         provided by Akiya ISHIDA
8812
8813 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8814
8815         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8816         * src/SDCCval.c (constVal): added reduction from int to char
8817         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8818         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8819         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8820         to ignore the sign
8821         * support/regression/tests/shifts.c: fixed
8822
8823 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8824
8825         * src/z80/gen.c (genXor): Fixed bug #805445
8826
8827 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8828
8829         Fixed bug #621531 (const & volatile confusion in the type chain).
8830         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8831         refer to the const or volatile state of the pointer itself.
8832
8833         * src/SDCCast.c
8834         * src/SDCCglue.c
8835         * src/SDCCicode.c
8836         * src/SDCCsymt.c
8837         * src/SDCCval.c
8838         * src/SDCC.y
8839         * src/SDCCsymt.h
8840         * src/pic/gen.c
8841         * src/pic/ralloc.c
8842         * src/pic16/gen.c
8843         * src/pic16/ralloc.c
8844         * support/regression/tests/const.c
8845
8846 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8847
8848         When checking for duplicated modules, use absolute paths
8849         instead of relative paths.  Files changed:
8850
8851         * as/mcs51/lklib.c
8852         * link/z80/lklib.c
8853
8854 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8855
8856         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8857
8858 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8859
8860         * device/include/string.h: added size_t typedef, changed
8861         prototypes to use size_t, eliminated separate reentrant and
8862         non-reentrant declarations, added _memmove declaration
8863         * device/lib/_memcpy.c: changed to use size_t instead of int,
8864         changed /4 to >>2 to avoid division library call
8865         * device/lib/_memcmp.c,
8866         * device/lib/_memset.c,
8867         * device/lib/_strncat.c,
8868         * device/lib/_strncpy.c,
8869         * device/lib/_strncmp.c: changed to use size_t instead of int
8870         * device/lib/_memmove.c: new file (fixed bug #772294)
8871         * device/lib/Makefile.in: added _memmove.c
8872         * device/lib/z80/asm_strings.s: fixed bug #772290
8873         * support/regression/tests/bitfields.c: attempt to fix host assertion
8874         failure on amd64-unknown-linux2.2
8875
8876 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8877
8878         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8879         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8880         * as/z80/asmain.c (main): fixed bug #801766
8881
8882 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8883
8884         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8885         compilers
8886
8887 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8888
8889         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8890         reported in bug #800609
8891
8892 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8893
8894         * Top header beautifications in src/pic16 directory:
8895           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8896           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8897           pcoderegs.h, ralloc.c, ralloc.h
8898         * main.c: added top header and GPL license notice
8899         * pcode.c: fixed the if-conditional warning
8900
8901 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8902
8903         * device/lib/_mullong.c: replaced int by short for gcc
8904
8905 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8906
8907         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8908         and JUMPTABLE iCodes properly now (worked by accident before)
8909         * src/mcs51/gen.c (leftRightUseAcc),
8910         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8911         iCode properly now. Use getSize instead of nRegs since a & b
8912         aren't part of the nRegs tally.
8913
8914 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8915
8916         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8917         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8918           before instructions that use the _STATUS register
8919
8920 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8921
8922         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8923         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8924         fetching of the pointer
8925         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8926         copied from genNearPointerSet()
8927         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8928         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8929         If they pop r0/r1 they must be called in the opposite order than aopOp().
8930         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8931         (resp. --stack-auto), prepared for --xstack
8932
8933 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8934
8935         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8936
8937 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8938
8939         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8940         these ports have their own __sdcc_external_start()
8941
8942 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8943
8944         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8945         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8946         type for bits was changed. It resulted in bit variables becoming
8947         global, which is not permitted in PIC 14 assembly output.
8948
8949 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8950
8951         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8952
8953 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8954
8955         Z80 and MCS51 linkers complaint if a public symbol is defined
8956         in more than one library module:
8957
8958         * as/mcs51/lklib.c
8959         * link/z80/lklib.c
8960         * as/mcs51/Makefile.in
8961
8962 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8963
8964         A few small changes that speed up the peephole optimizer.
8965
8966         * src/SDCCpeeph.c
8967
8968 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8969
8970         Try to make the peephole optimizer smarter by maintaining
8971         an association between the assembly source code and the
8972         iCodes that originated them. Put this information to use
8973         with a new peephole rule condition "notVolatile" so that
8974         the rules can be aggressive yet still safe.
8975
8976         * src/SDCCpeeph.c
8977         * src/SDCCpeeph.h
8978         * src/mcs51/gen.c
8979         * src/mcs51/peeph.def
8980
8981 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8982
8983         Fixed bug #741761
8984
8985         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8986         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8987         if the left or right operand symbols have the accuse flag set.
8988
8989 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8990
8991         Changed the type of the result of the ! (NOT) operator to char;
8992         previously it returned the same type as the source. This allows
8993         us to eliminate all the genFloatNot functions (all of its target
8994         implementations were very buggy) since !float can use the same
8995         code as !long now.
8996
8997         * src/SDCCicode.c (ast2iCode): ! returns char
8998         * src/mcs51/gen.c (genNot, genNotFloat),
8999         * src/ds390/gen.c (genNot, genNotFloat),
9000         * src/z80/gen.c (genNot, genNotFloat),
9001         * src/pic/gen.c (genNot, genNotFloat),
9002         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
9003
9004 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
9005
9006         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
9007         1. Interrupt would not compile properly. Ensure PCLATH register is saved
9008            during interrupts. Ensure WSAVE is located at a shared bank address.
9009         2. Fixed page selection in some places
9010         3. Fixed BTFSS/C to where necessary use registers directly and not simply
9011            the registers name strings.
9012         4. Fixed "signed / unsigned compare" compiler warnings.
9013         5. The PIC port manages its own allocation of the general purpose
9014            registers, but makes no attempt to reuse them. As a result when
9015            compiling it soon runs out of general purpose registers. Some
9016            additional code was added to the files pcode.c and device.c to walk
9017            through the function call tree and rename the registers so that they
9018            get reused.
9019
9020         * src/pic/device.c
9021         * src/pic/gen.c
9022         * src/pic/glue.c
9023         * src/pic/pcode.c
9024         * src/pic/pcode.h
9025         * src/pic/ralloc.c
9026         * src/pic/ralloc.h
9027         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
9028         genPlus() & genMinus() when the result is the same as left or right
9029
9030 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9031
9032         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
9033
9034 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9035
9036         Made bitfield a distinct type from bit so that bitfields
9037         convert as per ANSI C and bits retain their traditional
9038         boolean style behaviour. Implemented bitfield support in
9039         the z80 port.
9040
9041         * src/SDCCsymt.h,
9042         * src/SDCCsymt.c,
9043         * src/SDCCast.c,
9044         * src/cdbFile.c,
9045         * src/mcs51/gen.c,
9046         * src/ds390/gen.c: bit v bitfield split
9047         * src/z80/gen.c: New support for bitfields
9048         * support/regression/tests/bitfields.c: reenabled z80,
9049         added more tests
9050
9051 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9052
9053         Rules 246.x, 247.x relate to bitfields, the others speed up
9054         access to xdata mapped I/O devices.
9055
9056         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
9057
9058 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9059
9060         Cleaned up genPackBits and genUnpackBits and added two helper
9061         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
9062         for literal assignments in genPackBits (thanks to Frieder for
9063         reminding me).
9064
9065         * src/mcs51/gen.c
9066         * src/ds390/gen.c
9067
9068 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9069
9070         Fixed bug #748310 (pointer to function type mishandled when the
9071         function name is omitted). Also fixed a SIGSEGV when a function
9072         attribute (reentrant, etc) is used on a non-function or on a
9073         function but misplaced before the parameter list.
9074
9075         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
9076         bug #748310
9077         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
9078         * support/Util/SDCCerr.h,
9079         * support/Util/SDCCerr.c: Added func attr misuse error msg
9080
9081 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9082
9083         Fixed bug #787649 by anonymous
9084         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
9085         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
9086
9087 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9088
9089         Fixed numerous bitfield problems.
9090
9091         * src/SDCC.y: More bitfield related error checking
9092         * src/SDCCsymt.h,
9093         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
9094         * support/Util/SDCCerr.h,
9095         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
9096         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9097         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9098         * support/regression/tests/bitfields.c: tests added
9099
9100 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9101
9102         Made the constant following the "interrupt" keyword optional. If
9103         omitted, the function will not automatically be given an entry
9104         in the interrupt vector table (similar to #pragma NOIV, but
9105         less syntacticly kludgy). The interrupt number is also now
9106         range checked. Also fixed a bug in the high order bit example
9107         in the manual.
9108
9109         * src/SDCC.y
9110         * src/SDCCmem.c
9111         * src/SDCCglue.c
9112         * src/SDCCsymt.h
9113         * support/Util/SDCCerr.c
9114         * support/Util/SDCCerr.h
9115         * doc/sdccman.lyx
9116
9117 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9118
9119         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
9120         * src/SDCCicode.c (operandOperation): rewritten some ops
9121         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
9122         * src/SDCCsymt.c (computeType): literals are handled the same way as any
9123         other type
9124         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
9125         be re-activated by defining REDUCE_LITERALS)
9126         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
9127         unsigned, but are signed by default
9128         * src/SDCCval.c (constVal): rearranged
9129         * src/SDCCval.c (valMod): preliminary fix
9130         * src/SDCCval.c (valCastLiteral): use TYPE_* types
9131         * support/regression/literalop.c: added, work in progress
9132
9133 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9134
9135         Generate warnings for useless declarations like "char data;"
9136         that don't do what new users expect.
9137
9138         * src/SDCC.y
9139         * support/Util/SDCCerr.h
9140         * support/Util/SDCCerr.c
9141
9142 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
9143
9144         * src/SDCCval.c (valMult): fix overflow detection of negative int
9145
9146 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9147
9148         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
9149
9150         Changes to support big endian targets:
9151
9152         * src/ports.h
9153         * src/SDCCglue.c
9154         * src/avr/main.c
9155         * src/ds390/main.c
9156         * src/izt/i186.c
9157         * src/mcs51/main.c
9158         * src/pic/main.c
9159         * src/pic16/main.c
9160         * src/xa51/main.c
9161         * src/z80/main.c
9162
9163 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
9164
9165         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
9166         * device/lib/time.c: fixed warning "integer overflow in expression"
9167
9168 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
9169
9170         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
9171         * src/SDCCval.c (constVal): changed default to signed; hex and octal
9172         constants are unsigned; added recognition of "u" flag for unsigned
9173         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
9174         * src/SDCCval.c (valDiv, valMod): fixed signdness
9175         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
9176         signedness of modulo, left and right shift
9177         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
9178         * support/Util/SDCCerr.h: added warning W_INT_OVL
9179         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
9180         * src/SDCCast.c (ast_print): improved output of constants
9181
9182 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9183
9184         Fixed some warnings when building with MSVC:
9185
9186         * as\mcs51\asdata.c
9187         * as\z80\asdata.c
9188         * as\mcs51\asm.h
9189         * as\z80\asm.h
9190         * link\z80\aslink.h
9191         * link\z80\lkdata.c
9192         * link\z80\lkeval.c
9193         * link\z80\lkgb.c
9194         * link\z80\lkihx.c
9195         * link\z80\lks19.c
9196         * link\z80\lksym.c
9197         * support\cpp2\cpplib.c
9198         * src\ds390\gen.c
9199         * src\mcs51\gen.c
9200
9201 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
9202
9203         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
9204
9205 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9206
9207         * support\librarian\clean.mk: Do not remove Makefile.
9208         * support\librarian\Makefile: added.
9209
9210 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9211
9212         Added librarian to MSVC build:
9213         * all.dsp
9214         * sdcc.dsw
9215         * support\librarian\librarian.dsp
9216
9217         'configure' not needed for librarian, removed:
9218         * support\librarian\configure
9219         * support\librarian\configure.in
9220         * support\librarian\config_in.h
9221         * support\librarian\Makefile.in
9222
9223         Hopefully these ones built the librarian and the rest of sdcc properly:
9224         * Makefile
9225         * Makefile.common.in
9226
9227         Messed up 'configure', so revert to previous version:
9228         * configure
9229         * configure.in
9230
9231 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
9232
9233         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
9234         there, while the mantissa of a double is "only" 53 bits wide.
9235
9236 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9237
9238         Adding sdcclib to the build.  MSVC project coming soon.
9239         Files added/changed:
9240
9241         * support\librarian\clean.mk
9242         * support\librarian\configure
9243         * support\librarian\configure.in
9244         * support\librarian\config_in.h
9245         * support\librarian\Makefile.bcc
9246         * support\librarian\Makefile.in
9247         * support\librarian\sdcclib.c
9248         * Makefile.bcc
9249         * Makefile
9250         * Makefile.common.in
9251         * configure
9252         * configure.in
9253
9254 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9255
9256         Linker now complaints if linked modules have conflicting options, for
9257         example, one compiled using --model-large and another one compiled with
9258         --model-small.  The following files were modified:
9259
9260         * as\mcs51\asdata.c
9261         * as\mcs51\aslink.h
9262         * as\mcs51\asm.h
9263         * as\mcs51\asmain.c
9264         * as\mcs51\asout.c
9265         * as\mcs51\i51pst.c
9266         * as\mcs51\lkdata.c
9267         * as\mcs51\lklibr.c
9268         * as\mcs51\lkmain.c
9269         * as\z80\asdata.c
9270         * as\z80\asm.h
9271         * as\z80\asmain.c
9272         * as\z80\asout.c
9273         * as\z80\z80pst.c
9274         * link\z80\aslink.h
9275         * link\z80\lkdata.c
9276         * link\z80\lklibr.c
9277         * link\z80\lkmain.c
9278         * src\SDCCglue.c
9279
9280 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9281
9282         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
9283         as/mcs51/lklibr.c: Generate a warning when a library is not found.
9284
9285 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
9286
9287         * src/z80/mappings.i: fix _mul[us][int,long] entries
9288
9289 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9290
9291         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
9292
9293 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9294
9295         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
9296         * support/regression/tests/bitopcse.c: added
9297         fixed warning:
9298         * src/avr/gen.c:
9299         * src/pic/gen.c:
9300         * src/pic16/gen.c:
9301         * src/z80/gen.c:
9302         * src/xa51/gen.c:
9303
9304 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9305
9306         added support for new library format to z80, gbz80 linkers:
9307         *link/z80/aslink.h
9308         *link/z80/lklex.c
9309         *link/z80/lklib.c
9310         *link/z80/lklist.c
9311
9312 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9313
9314         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
9315         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
9316
9317 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
9318
9319         added DUMMY_READ_VOLATILE:
9320         * src/SDCC.y:
9321         * src/avr/gen.c:
9322         * src/xa51/gen.c:
9323         * src/z80/gen.c:
9324         * src/pic/gen.c:
9325         * src/pic16/gen.c:
9326         * src/mcs51/gen.c:
9327         * src/ds390/gen.c:
9328         * src/SDCCcse.c (algebraicOpts): many improvements
9329         * src/SDCCcse.h: removed algebraicOpts()
9330         * src/SDCCicode.c (picDummyRead): added
9331
9332 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9333
9334         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
9335         "Insufficient space in data memory".
9336
9337 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9338
9339         * src/mcs51/gen.c: fixed bug #771358
9340         * src/z80/gen.c: fixed bug #759087
9341
9342 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
9343
9344         * src/pic16/glue.c: minor cleanup by Vangelis
9345
9346 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9347
9348         * device/include/regc515c.h: fixed #758477
9349         * device/lib/_gptrget.c: saving some cycles in generic pointer get
9350         * device/lib/_gptrput.c: saved a few bytes
9351         * my tab spacing is 8, yours too?)
9352         * device/lib/_ser.c: process RX bytes earlier than TX bytes
9353         * device/lib/serial.c: process RX bytes earlier than TX bytes
9354         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
9355
9356 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9357
9358         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
9359
9360 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9361
9362     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
9363
9364 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
9365
9366         * device/lib/Makefile.in: bad fix, reverted to 1.43
9367
9368 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
9369
9370         * device/lib/Makefile.in: added missing z80 object files
9371
9372 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
9373
9374         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
9375         pic16 progress by Vangelis:
9376         * src/SDCCglobl.h:
9377         * src/SDCCmain.c:
9378         * src/pic/Makefile:
9379         * src/pic:
9380         * pic/Makefile:
9381         * pic16/device.c:
9382         * pic16/device.h:
9383         * pic16/gen.c:
9384         * pic16/gen.h:
9385         * pic16/genarith.c:
9386         * pic16/glue.c:
9387         * pic16/main.c:
9388         * pic16/pcode.c:
9389         * pic16/pcode.h:
9390         * pic16/pcodepeep.c:
9391         * pic16/peeph.def:
9392
9393 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9394
9395     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
9396
9397 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9398
9399     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
9400     added gbz80 build to MSVC project.
9401     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
9402     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
9403     from 8051 stuff and setup so it links using a .lnk file.
9404
9405 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9406
9407     * support/librarian/sdcclib.c: sdcc librarian.
9408     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
9409     with sdcclib.
9410
9411 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9412
9413     * as/mcs51/lkmain.c: properly handle extensions in function afile.
9414
9415 2003-07-02  Borut Razem <borut.razem AT siol.net>
9416
9417         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
9418         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
9419         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
9420         src/xa51/main.c, src/z80/main.c:
9421         virtualization of glue() function: each port has it's own glue function,
9422         which is accessed by do_glue function pointer in PORT.general structure
9423
9424 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
9425
9426         * DS800C400 fun, improved ROM interface and tinibios.
9427
9428 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
9429
9430         * More support for DS80C400. Now includes beginning of interface to ROM.
9431
9432 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
9433
9434         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
9435
9436 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9437
9438         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
9439
9440 2003-06-19  Borut Razem <borut.razem AT siol.net>
9441
9442         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
9443
9444 2003-06-19  Borut Razem <borut.razem AT siol.net>
9445
9446         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
9447         fixed Z80 port - crt0.o: cannot open.
9448
9449 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
9450
9451         * support/Util/MySystem.c (merge_command): revert bad fix
9452
9453 2003-06-18  Borut Razem <borut.razem AT siol.net>
9454
9455         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9456
9457 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9458
9459         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9460         option --use-stdout sends errors to stdout instead of stderr.
9461
9462 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9463
9464         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9465
9466 2003-06-15  Borut Razem <borut.razem AT siol.net>
9467
9468         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9469         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9470         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9471         fixed width array of pointers replaced with sets;
9472         multiple include and lib paths ared transferred to preprocessor and linker
9473         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9474         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9475         fixed width array of pointers
9476         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9477         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9478         fixupPath(), getPathDifference()
9479         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9480         fixed width array of pointers
9481
9482 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9483
9484         * src/pic16/ralloc.c: fix warnings
9485         * src/pic16/pcode.c: fix warning
9486
9487 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9488
9489          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9490         know all the details, but essentially this set of changes enable
9491         the pic16 port to generate movff instructions and generate assembler
9492         directives,
9493         * src/SDCCmain.c:
9494         * src/pic16/gen.c:
9495         * src/pic16/glue.c:
9496         * src/pic16/pcode.c:
9497         * src/pic16/device.c:
9498         * src/pic16/main.c:
9499         * src/pic16/pcode.h:
9500         * src/pic16/pcoderegs.c:
9501         * src/pic16/ralloc.c:
9502         * src/pic16/ralloc.h:
9503
9504 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9505
9506         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9507         added option --vc, so sdcc errors and warnings are compatible with
9508         Microsoft Visual Studio.
9509
9510 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9511
9512         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9513           device/lib/libfloat.lib: added atof function.
9514
9515 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9516
9517         * doc/sdccman.lyx: updated to Lyx 1.3
9518         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9519         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9520         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9521
9522 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9523
9524         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9525
9526 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9527
9528         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9529           additions to the "related tools/documentation" section
9530
9531 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9532
9533         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9534
9535 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9536
9537         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9538         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9539
9540 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9541
9542         * doc/sdccman.lyx: fix double dash and other minor things
9543         * doc/Makefile: fix double dash
9544
9545 2003-05-28  Karl Bongers(patches from Martin Helmling)
9546         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9547           condition and ignore commands.
9548
9549 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9550
9551         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9552           is in parts still quite out of date, I did changes as far as I felt makes sense
9553           for a non-native english speaker.
9554           Please feel free to add to the manual or to correct my changes.
9555         * doc/Makefile: undid touching the date of intermediate tex files.
9556
9557 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9558
9559         * doc/sdccman.lyx: Manual has an index now
9560
9561 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9562
9563         Finalize muluint/mulsint and mululong/mulslong merging:
9564         * device/lib/_mulint.c
9565         * device/lib/_mullong.c
9566         * device/lib/gbz80/mul.s
9567         * device/lib/gbz80/stubs.s
9568         * device/lib/z80/mul.s
9569         * device/lib/z80/stubs.s
9570         * src/SDCCsymt.c (initCSupport)
9571
9572 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9573
9574         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9575         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9576           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9577           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9578           instead of /Zm500.
9579
9580 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9581
9582         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9583           the regression tests I'm not brave enough to enable 245.b, 245.c
9584         * doc/sdccman.lyx: added latex preamble for hyperref package.
9585           Using pdflatex this will give you a hyperlinked pdf file with
9586           bookmarks. (prepend '%' before /usepackage if this breaks something)
9587
9588 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9589
9590          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9591
9592 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9593
9594         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9595
9596 2003-05-21    <johan AT balder>
9597
9598         * src/SDCCglue.c (printIval): fixed bug #739934
9599
9600 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9601
9602         Applied patch from bug 737905 (renamed yylineo to mylineno):
9603         * src/altlex.c
9604         * src/SDCCast.c
9605         * src/SDCglobl.h
9606         * src/SDCC.lex
9607         * src/SDCCsymt.c
9608         * src/SDCCval.c
9609         * src/pic16/pcode.c: Cleaned warnings
9610         * src/pic16/pcodeflow.c: Cleaned warnings
9611         * src/pic16/pcoderegs.c: Cleaned warnings
9612
9613 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9614
9615         * src/pic16/pcode.c: Cleaned warnings
9616         * src/pic16/pcodepeep.c: Cleaned warnings
9617         * src/pic16/ralloc.c: Cleaned warnings
9618
9619 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9620
9621         * doc/sdccman.lyx: fixed bug 739745
9622         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9623
9624 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9625
9626         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9627         it can be defined with CFLAGS when running configure
9628         * src/SDCCmain.c: fixed compiling + linking with object files
9629
9630 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9631
9632         * configure.in: configure for pic16 port,
9633             added --disable-pic16-port
9634         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9635         * src/SDCCmain.c: linkOptions is changed to set *,
9636             added if/endif conditional macros to remove options help
9637             messages from optionsTable when a port is not configured, added
9638             support for the PIc16 port in the ports table, when executing
9639             the compiler with no port specified on command line, a default
9640             port is selected with the new macro DEFAULT_PORT which is
9641             defined in port.h, in setDefaultOptions() linkOptions is removed
9642             from initialization assignment, since now it is a set,
9643             parseCmdLine uses setParseWithComma for linkOptions, in
9644             linkEdit() linkOptions are accessed with new function indexSet()
9645             which returns the i'th item of a set variable. See SDCCset.c, in
9646             linkEdit() when calling buildCmdLine(), added linkOptions as
9647             last argument. Now users can pass arguments to gplink via the
9648             -Wl option, main() uses pic16glue() to glue up pic16 programs
9649         * src/SDCCpeeph.c: various changes to support pic16
9650         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9651             return the i'th item of the set
9652         * src/SDCCset.h: added function prototype for indexSet()
9653         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9654         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9655         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9656             added macro DEFAULT_PORT
9657         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9658         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9659             generated
9660         * src/pic16/glue.c: commented out some error producing lines
9661         * src/pic16/main.c: __config directives are commented out to stop
9662             gpasm complaining and test the linkage with gplink, _linkCmd and
9663             _asmCmd changed to be more gplink and gpasm friendly
9664         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9665             produced an error when parsed, peep rule 12 is added to utilize
9666             movff, but it is commented out since the pCode does not support
9667             yet a command with 2 address arguments
9668
9669 2003-05-18    <johan AT balder>
9670
9671         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9672         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9673 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9674
9675         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9676   Added feature to script commands from file.
9677
9678 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9679
9680         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9681         * src/SDCCutil.c: include ctype.h for win32
9682
9683 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9684
9685         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9686
9687 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9688
9689         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9690   Fixed so you can set breakpoints prior to run, run does not stop
9691   on entry now.  Add tbreak.  Other enhancements and fixes for use
9692   with ddd.
9693
9694 2003-05-12  Borut Razem <borut.razem AT siol.net>
9695
9696         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9697
9698 2003-05-11  Borut Razem <borut.razem AT siol.net>
9699
9700         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9701         the path of bin directory, so that PATH is the only env. variable, which has to be set
9702         in case of standard installation.
9703         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9704         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9705         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9706
9707 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9708
9709         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9710         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9711         temp files are in the port dir; clean the gen/test directory when
9712         generating new test.c
9713         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9714         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9715         * support/regression/tests/zeropad.c: added
9716
9717 2003-05-09    <johan AT balder>
9718
9719         * src/SDCCglue.c: fixed bug #597940
9720
9721 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9722
9723         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9724   cache sfr, optimize next,step, fix off by one sourceline,
9725   support ddd list function.
9726         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9727
9728 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9729
9730         * support/regression/HTMLgen.py: added compare_s2f()
9731         * support/regression/Makefile: redo 1.27
9732         * support/regression/generate-cases.py: redo 1.5
9733
9734 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9735
9736         * support/regression/tests/float.c: workaround 33 bit hex constant
9737         * support/regression/tests/simplefloat.c: fix division for host
9738
9739 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9740
9741         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9742         that tame's the PIC's over-aggressive optimizer.
9743
9744 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9745
9746          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9747          support for MSVC.
9748
9749 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9750
9751         Initial support for DS80C400. "Hello world" runs on TINIm400
9752         (with polled I/O).
9753
9754 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9755
9756          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9757          * Some notes on ddd usage added in debugger/README
9758          Martin Helmling adding more features and fixes for ddd GUI debugger.
9759          Code added for nexti, stepi, up, down, and other adjustments.
9760
9761 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9762
9763         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9764         * src/pic/peeph.def Added two rules to optimize carry manipulation
9765         * src/pic/* removed debug printfs
9766
9767 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9768
9769         * debugger/mcs51/cmd.c: added header newalloc.h
9770
9771 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9772
9773         * as/Makefile: new EXEEXT
9774         * as/z80/Makefile: remove trailing slash of BUILDIR
9775         * as/z80/clean.mk: new EXEEXT
9776         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9777         * support/cpp2/Makefile.in: new EXEEXT
9778         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9779
9780 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9781
9782         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9783         EXEEXT was introduced to fix all related problems with targets
9784         "clean", "install" and "uninstall"; a couple of further flaws
9785         especially with "clean" have been fixed too
9786         * as/mcs51/Makefile.in
9787         * as/mcs51/clean.mk
9788         * as/z80/Makefile
9789         * Makefile
9790         * clean.mk
9791         * debugger/mcs51/Makefile.in
9792         * debugger/mcs51/clean.mk
9793         * link/z80/Makefile
9794         * link/z80/Makefile.in
9795         * link/z80/clean.mk
9796         * link/Makefile
9797         * packihx/Makefile.in
9798         * packihx/clean.mk
9799         * sim/ucsim/Makefile
9800         * sim/ucsim/clean.mk
9801         * sim/ucsim/avr.src/Makefile.in
9802         * sim/ucsim/avr.src/clean.mk
9803         * sim/ucsim/s51.src/Makefile.in
9804         * sim/ucsim/s51.src/clean.mk
9805         * sim/ucsim/xa.src/Makefile.in
9806         * sim/ucsim/xa.src/clean.mk
9807         * sim/ucsim/z80.src/Makefile.in
9808         * sim/ucsim/z80.src/clean.mk
9809         * sim/ucsim/main_in.mk
9810         * sim/ucsim/packages_in.mk
9811         * sim/ucsim/gui.src/Makefile.in
9812         * sim/ucsim/gui.src/serio.src/Makefile.in
9813         * sim/ucsim/gui.src/serio.src/clean.mk
9814         * src/Makefile.in
9815         * src/clean.mk
9816         * support/cpp2/Makefile.in
9817         * support/cpp2/clean.mk
9818         * support/makebin/Makefile
9819         * support/makebin/clean.mk
9820         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9821         * doc/sdccman.lyx: --program-suffix no longer needed
9822
9823 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9824
9825          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9826          Martin Helmling added support for ddd GUI debugger.
9827          Code added to display assembly, set variables, and other commands
9828          to interface to ddd.
9829
9830 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9831
9832         * as/Makefile: fix target clean
9833         * as/clean.mk: fix target clean
9834         * as/z80/clean.mk: fix target clean
9835
9836 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9837
9838         * Makefile.common.in: added  AT EXEEXT AT
9839         * configure.in: removed all mingw32 stuff
9840         * configure: rebuilt from configure.in
9841         * doc/sdccman.lyx: updated section "installation"
9842         * support/scripts/sdcc_mingw32: adapted to configure
9843         * support/scripts/sdcc_cygwin_mingw32: added
9844
9845 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9846
9847         * src/pic Added object file support for the PIC port
9848         * src/pic Applied patch from Craig Franklin (this started the object file support)
9849         * src/regression Updated the PIC regression tests for object files
9850
9851 2003-04-20  Borut Razem <borut.razem AT siol.net>
9852
9853         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9854           lklex.c: In function `getfid':
9855           lklex.c:203: warning: array subscript has type `char'
9856         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9857           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9858         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9859           stack handling macros
9860
9861 2003-04-19  Borut Razem <borut.razem AT siol.net>
9862
9863         * "handling space characters in file path" task:
9864         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9865         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9866         * support/Util/MySystem.h: make it self-sufficient
9867         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9868           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9869           handling space characters in file path
9870         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9871           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9872         * support/Util/MySystem.c: handling space characters in executable's path
9873
9874 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9875
9876         * as/z80/Makefile: fix permanent rebuild of z80
9877         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9878         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9879
9880 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9881
9882         * src/SDCCopt.c: add special case optimization to replace modulo by
9883           a power of two with a bitwise AND.
9884
9885 2003-04-18    <johan AT balder>
9886
9887         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9888
9889 2003-04-17    <johan AT balder>
9890
9891         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9892         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9893
9894 2003-04-13  Borut Razem <borut.razem AT siol.net>
9895
9896         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9897         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9898           fixed mingw problem in adl_NORMALIZE_PATH
9899
9900 2003-04-12  Borut Razem <borut.razem AT siol.net>
9901
9902         * fixed "#pragma SAVE/RESTORE can not be nested":
9903         * src/SDCC.lex: reworked pragma handling functions
9904         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9905         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9906
9907 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9908
9909         * src/SDCCutil.c (pathEquivalent): defined but not used
9910         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9911         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9912         * configure: rebuilt from configure.in
9913         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9914         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9915         * device/include/Makefile.in: replace sdcc_datadir
9916         * device/lib/Makefile.in: replace sdcc_datadir
9917         * Makefile.common.in: add LDFLAGS from configure
9918         * packihx/Makefile.in: use LDFLAGS
9919         * src/Makefile.in: use LDFLAGS
9920         * support/cpp2/Makefile.in: add LDFLAGS from configure
9921         * support/makebin/Makefile: use LDFLAGS
9922         * .version: bumped version number to 2.3.5
9923
9924 2003-04-12  Borut Razem <borut.razem AT siol.net>
9925
9926         * completed "different paths" task:
9927         * src/SDCCmacro.c: fixed bug in handling quotes
9928         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9929         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9930
9931 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9932
9933         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9934
9935 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9936
9937         * ds390/gen.c ds390/peeph.def: fix bug 706781
9938
9939 2003-04-11  Borut Razem <borut.razem AT siol.net>
9940
9941         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9942
9943 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9944
9945         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9946         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9947          set - this bit used to not be set...).
9948         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9949           bad code in PIC Port
9950         * src/regression/and2.c added to test bug 609268
9951         * src/regression/Makefile added and2.c to regression test
9952
9953
9954 2003-04-08    <johan AT CP255758-A>
9955
9956         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9957         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9958         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9959
9960 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9961
9962         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9963         fix bug #487815
9964         * support/cpp2/Makefile.in: fix bug #487815
9965         * configure: rebuilt from configure.in
9966         * Makefile.common.in: docdir changed, new path suffixes
9967         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9968         * sdcc_vc_in.h: reflect changes from sdccconf.h
9969         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9970         * src/SDCCutil.h: remove BINDIR hack
9971         * doc/sdccman.lyx: update new path hierarchy
9972
9973 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9974
9975         * src/SDCCpeeph.c: added okToRemoveSLOC test
9976
9977 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9978
9979         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9980
9981 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9982
9983         * src/SDCCpeeph.c: added labelIsReturnOnly test
9984         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9985
9986 2003-04-05    <johan AT balder>
9987
9988         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
9989         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
9990         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
9991         * src/SDCCast.c: fixed a warning
9992         * src/SDCCast.h: fixed a warning
9993         * src/SDCCicode.c (operandFromAst): fixed a warning
9994
9995 2003-04-04    <johan AT balder>
9996
9997         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
9998         * src/SDCCast.c (decorateType): fixed bug #715076
9999         * src/SDCC.y: fixed bug #702907
10000
10001 2003-04-03    <johan AT balder>
10002
10003         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
10004         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
10005         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
10006         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
10007         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
10008
10009 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
10010
10011         * _decdptr.c: fix return values
10012         * _gptrget.c: fix return values
10013         * _gptrgetc.c: fix return values
10014         * _gptrput.c: fix return values
10015         * _mulint.c: fix return values
10016         * as/z80/Makefile: fix 'make -j' problem
10017
10018 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
10019
10020         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
10021         * configure.in: big cleanup, updated to autoconf 2.5x
10022         * configure: rebuilt from configure.in
10023         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
10024         * sdcc_vc_in.h: reflect changes from sdccconf.h
10025         * doc/Makefile: fixed a flaw in "make install"
10026
10027 2003-04-02    <johan AT balder>
10028
10029         * src/ds390/gen.c (genCmp): no comments
10030         * src/mcs51/gen.c (genCmp): no comments
10031         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
10032         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
10033
10034 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
10035
10036         * support/regression/generate-cases.py: place generated file in given sub directory
10037         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
10038         * support/regression/Makefile: improvements for 'make -j';
10039         side effect: it's simpler and faster now
10040
10041 2003-03-31  Borut Razem <borut.razem AT siol.net>
10042
10043         * src/z80/main.c: link-{port} and as-{port} defined without path
10044         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
10045
10046 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
10047
10048         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
10049
10050 2003-03-30  Borut Razem <borut.razem AT siol.net>
10051
10052         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
10053           changed type of list parameter to set
10054         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
10055         * src/port.h: changed type of do_assemble() parameter to set
10056         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
10057           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
10058           definition of "cppoutfilename" macro with NULL value in preProcess()
10059         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
10060         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
10061         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
10062           replaced with set *binPathSet
10063         * shash_add() deallocates the item, if allready exsists, before adding the new one
10064         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
10065
10066 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
10067
10068         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
10069           a nested for loop bug in the PIC port
10070         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
10071           for loops
10072
10073 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
10074
10075         * support/Util/dbuf.h: remove C++ stuff to make it portable
10076
10077 2003-03-28  Borut Razem <borut.razem AT siol.net>
10078
10079         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
10080           literal strings in stringLiteral()
10081         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
10082         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
10083           to the project
10084
10085 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
10086
10087         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
10088
10089 2003-03-26    <johan AT balder>
10090
10091         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
10092         * src/ds390/gen.c (saveRegisters): catched symbol abuse
10093         * src/SDCCast.c (decorateType): fixed " -v < 3"
10094
10095 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
10096
10097         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
10098         Added Lenny Story's debug infrastructure changes:
10099         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
10100         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
10101         * src/cdbFile.c: added
10102         * src/SDCCdebug.c: added
10103         * src/SDCCdebug.h: added
10104         * src/SDCCast.c (createFunction)
10105         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
10106         * src/SDCCmain.c (parseCmdLine, main)
10107         * src/SDCCmem.c (redoStackOffsets)
10108         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
10109         * src/SDCCsymt.h
10110         * src/common.h
10111         * src/avr/gen.c (genAVRCode)
10112         * src/ds390/gen.c (gen390Code)
10113         * src/mcs51/gen.c (gen51Code)
10114         * src/pic/gen.c (genpic14Code)
10115         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
10116         * src/xa51/gen.c (genXA51Code)
10117         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
10118
10119 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10120
10121         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
10122         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
10123
10124 2003-03-22    <johan AT balder>
10125
10126         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
10127
10128 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
10129
10130         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
10131         * doc/cdbfileformat.lyx: added, written by Lenny Story
10132         * doc/Makefile: added cdbfileformat.lyx
10133         * doc/clean.mk: added cdbfileformat.lyx
10134
10135 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
10136
10137         * src/mcs51/peeph.def: fix bug #705773
10138
10139 2003-03-20    <johan AT balder>
10140
10141         An sfr/sbit can have an "at #" AND an initializer
10142         * src/SDCCsymt.c (checkSClass):
10143         * src/SDCCmem.c (allocGlobal):
10144         * src/SDCCmem.c (allocLocal):
10145         * src/SDCCast.c (createBlock):
10146
10147 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
10148
10149         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
10150
10151 2003-03-16    <johan AT balder>
10152
10153         Undid the hackup of const and volatile, the problem is much bigger
10154         * src/SDCC.y:1.65
10155         * src/SDCCast.c:1.171
10156         * src/SDCCglue.c:1.138
10157         * src/SDCCicode.c:1.146
10158         * src/SDCCsymt.c:1.150
10159         * src/SDCCval.c:1.65
10160
10161 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
10162
10163         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
10164         * src/ds390/gen.c (genAddrOf): fixed bug #704087
10165
10166 2003-03-13    <johan AT balder>
10167
10168         Hackup const and volatile modifiers in type chains a bit:
10169         * src/SDCC.y:1.63
10170         * src/SDCCast.c:1.169
10171         * src/SDCCglue.c:1.136
10172         * src/SDCCicode.c:1.143
10173         * src/SDCCsymt.c1.146
10174         * src/SDCCsymt.h1.59
10175         * src/SDCCval.c:1.63
10176
10177 2003-03-12    <johan AT balder>
10178
10179         * src/SDCCBBlock.h: more LRH debugging junk
10180         * src/SDCCcflow.h: more LRH debugging junk
10181         * src/SDCCloop.c: more LRH debugging junk
10182         * src/SDCC.y (struct_declaration): fixed bug #697590
10183         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
10184         * src/ds390/gen.c (aopForRemat): fixed bug #700031
10185         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
10186
10187 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10188         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
10189         test function names must now match exactly).
10190         * src/SDCCcse.c: added special case in findCheaperOp to allow
10191         extending a short integer. Makes less awful code for bug 700121 test case.
10192
10193 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10194
10195         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
10196         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
10197
10198 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10199
10200         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
10201         actually called (operandsNotEqual() was called for all
10202         operandsNotEqualX tests).
10203
10204 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10205
10206         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
10207         with shorter literals. Fixes bug 700121.
10208
10209 2003-03-11    <johan AT balder>
10210
10211         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
10212
10213 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
10214
10215         * src/SDCCloop.c (mergeRegions): an evil beast is dead
10216         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
10217
10218 2003-03-10  Borut Razem <borut.razem AT siol.net>
10219
10220         * src/SDCCmain.c: pipe preprocessor's output
10221         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10222         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10223         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10224         which closes all pipes in pipeSet set
10225         * src/SDCCset.c: free deleted item in function deleteSetItem()
10226         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10227         moved from z80 to src subproject
10228         * .version: increased version number to 2.3.4
10229
10230 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
10231
10232         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
10233         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
10234         * support/regression/ports/xa51/spec.mk: fix typo
10235
10236 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
10237
10238         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
10239
10240 2003-03-09  Borut Razem <borut.razem AT siol.net>
10241
10242         * src/SDCCmain.c: pipe preprocessor's output
10243         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10244         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10245         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10246         which closes all pipes in pipeSet set
10247         * src/SDCCset.c: free deleted item in function deleteSetItem()
10248         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10249         moved from z80 to src subproject
10250
10251 2003-03-09  Borut Razem <borut.razem AT siol.net>
10252
10253         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
10254         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
10255         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
10256         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
10257         * src/SDCCglobl.h: unification of WIN32 native definitions
10258
10259 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10260
10261         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
10262
10263 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10264
10265         * src/configure.in:   check for endianess (even while cross-compiling)
10266         * src/configure:      check for endianess (even while cross-compiling)
10267         * src/configure_in.h: check for endianess (even while cross-compiling)
10268         * src/avr/gen.c:        remove old endianess stuff
10269         * src/mcs51/gen.c:      remove old endianess stuff
10270         * src/ds390/gen.c:      remove old endianess stuff
10271         * src/pic/gen.c:        remove old endianess stuff
10272         * src/pic/genarith.c:   remove old endianess stuff
10273         * src/pic/glue.c:       fix endianess check
10274         * src/pic16/gen.c:      remove old endianess stuff
10275         * src/pic16/genarith.c: remove old endianess stuff
10276         * src/pic16/glue.c:     fix endianess check
10277         * src/xa51/gen.c:       remove old endianess stuff
10278         * src/z80/gen.c:        fix endianess check
10279         * src/SDCCglue.c:       fix endianess check
10280         * src/ds390/peeph.def: fix bug 700036
10281
10282 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10283
10284         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
10285         * src/configure: find appropriate data-types on host for SDCC's int and long
10286         * src/configure.in: find appropriate data-types on host for SDCC's int and long
10287         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
10288         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
10289
10290 2003-03-07    <johan AT balder>
10291
10292         Just a big NOOP:
10293                 some minor cleanups before the big shot
10294                 OP_DEFS and OP_USES now use Kevin's protection
10295                 new option --nolabelopt
10296
10297         * src/SDCCBBlock.c:
10298         * src/SDCCast.c,:
10299         * src/SDCCcflow.c:
10300         * src/SDCCcse.c:
10301         * src/SDCCicode.c:
10302         * src/SDCCicode.h:
10303         * src/SDCClabel.c:
10304         * src/SDCCloop.c:
10305         * src/SDCCmain.c:
10306         * src/ds390/ralloc.c:
10307         * src/mcs51/ralloc.c:
10308         * src/pic/ralloc.c:
10309         * src/xa51/ralloc.c:
10310         * src/z80/ralloc.c:
10311
10312 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
10313
10314         * src/pic/pcode.c (get_op): fix 64 bit warnings
10315         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
10316         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
10317         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
10318         * support/regression/tests/malloc.c: fix 64 bit warnings
10319
10320 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
10321
10322         * src/mcs51/gen.c (genMinus): fixed bug 696436
10323
10324 2003-03-02  Borut Razem <borut.razem AT siol.net>
10325
10326         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
10327
10328 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
10329
10330         * configure.in: test for mkstemp
10331         * sdccconf_in.h: add HAVE_MKSTEMP
10332
10333 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
10334
10335         * device/include/ctype.h: removed warning while using --stack-auto
10336         * device/include/malloc.h: removed warning while using --stack-auto
10337         * device/include/string.h: removed warning while using --stack-auto
10338
10339 2003-02-23  Borut Razem <borut.razem AT siol.net>
10340
10341         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
10342         because NDEBUG is defined (see man assert)
10343         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
10344
10345 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10346
10347         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
10348         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
10349
10350 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10351
10352         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
10353         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
10354
10355 2003-02-18    <johan AT balder>
10356
10357         * as/mcs51/asmain.c (asmbl): module can start with a digit
10358         * as/z80/asmain.c (asmbl): module can start with a digit
10359
10360 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
10361
10362         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
10363         * src/asm.c: fix pipe() for Mingw32
10364
10365 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
10366
10367         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
10368         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
10369         make -V work again; --c1mode reads now from stdin
10370         * doc/sdccman.lyx: added --c1mode
10371         * support/Util/SDCCerr.c: new messages for c1 mode
10372         * support/Util/SDCCerr.h: new messages for c1 mode
10373         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
10374
10375 2003-02-15    <johan AT balder>
10376
10377         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
10378
10379 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
10380
10381         * doc/sdccman.lyx: Environment variables, -o and other minor things
10382
10383 2003-02-14    <johan AT balder>
10384
10385         * src/xa51/main.c: before anyone really tries to use it :)
10386
10387         * Install doc's in share/sdcc/doc
10388         * removed some obsolete files
10389         * Do a proper make distclean and uninstall
10390         M Makefile.common.in
10391         R sdccbuild.sh
10392         M as/Makefile
10393         M device/include/Makefile.in
10394         M device/lib/Makefile.in
10395         M doc/sdccman.lyx
10396         M link/Makefile
10397         M sim/ucsim/doc/Makefile.in
10398         M src/clean.mk
10399         R src/avr/peeph.rul
10400         R src/xa51/peeph.rul
10401         M support/cpp2/Makefile.in
10402         M support/makebin/Makefile
10403
10404
10405 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
10406
10407         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
10408
10409 2003-02-10  Borut Razem <borut.razem AT siol.net>
10410
10411         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
10412         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
10413         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
10414         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
10415         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
10416         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
10417         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
10418         src/z80/Makefile.bcc: Borland Makefile cleanup
10419         * as/z80/Makefile.bcc: Added Borland Makefile
10420         * support/cpp2/borland.h: Removed
10421
10422 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
10423
10424         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
10425         * src/SDCC.lex: new pragma NOIV
10426         * src/SDCCglobl.h: new pragma NOIV
10427         * src/SDCCmem.c: new pragma NOIV
10428
10429 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10430
10431         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
10432
10433 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10434
10435         * src/SDCCmain.c: signal handling is switched off by --debug
10436         * doc/Makefile: small fix for install; use clean.mk again
10437         * doc/clean.mk: clean *.pdf and *.html too
10438
10439 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
10440
10441         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
10442         * device/lib/printfl.c: fix a ds390 bug by making it portable
10443         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
10444         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
10445         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
10446         * debugger/mcs51/cmd.c: converted multi-line string literals
10447         * sim/ucsim/globals.cc: converted multi-line string literals
10448         * src/SDCCmain.c: introduced signal handler to remove temp files
10449         * doc/Makefile: small tweaks, implement clean
10450         * doc: removed generated files
10451
10452 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10453
10454         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10455         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10456         Address Record is not correctly generated for DS390."
10457
10458 2003-02-02  Borut Razem <borut.razem AT siol.net>
10459
10460         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10461         * as/mcs51/asm.h: fixed compilation with Borland C
10462         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10463         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10464         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10465         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10466         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10467         src/z80/Makefile.bcc: delete $(LIB) only if exist
10468         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10469
10470 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10471
10472         * device/include/malloc.h: introduced NULL
10473         * device/include/string.h: introduced NULL
10474         * device/include/stdlib.h: introduced NULL
10475         * device/lib/_memcpy.c: removed NULL
10476         * device/lib/_strcat.c: removed NULL
10477         * device/lib/_strchr.c: removed NULL
10478         * device/lib/_strcmp.c: removed NULL
10479         * device/lib/_strcpy.c: removed NULL
10480         * device/lib/_strcspn.c: removed NULL
10481         * device/lib/_strlen.c: removed NULL
10482         * device/lib/_strncat.c: removed NULL
10483         * device/lib/_strncmp.c: removed NULL
10484         * device/lib/_strncpy.c: removed NULL
10485         * device/lib/_strpbrk.c: removed NULL
10486         * device/lib/_strrchr.c: removed NULL
10487         * device/lib/_strspn.c: removed NULL
10488         * device/lib/_strstr.c: removed NULL
10489         * device/lib/_strtok.c: removed NULL
10490         * device/lib/malloc.c: removed NULL, include own header
10491
10492 2003-02-02    <johan AT balder>
10493
10494         * 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
10495         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10496         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10497         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10498         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10499         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10500
10501 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10502
10503         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10504         area 'DATA'"
10505
10506 2003-02-01    <johan AT balder>
10507
10508         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10509
10510 2003-01-31    <johan AT CP255758-A>
10511
10512         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10513
10514 2003-01-30    <johan AT balder>
10515
10516         * src/SDCCBBlock.c: automatic bug detection
10517         * src/SDCCicode.c: automatic bug detection
10518
10519 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10520
10521         * src/SDCCglobl.h:   now --xram-size 0 works
10522         * src/SDCCmain.c:    now --xram-size 0 works
10523
10524 2003-01-29    <johan AT balder>
10525
10526         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10527
10528 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10529
10530         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10531         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10532         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10533         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10534         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10535         * src/SDCCmain.c:    Added options --xram-size and --code-size
10536
10537 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10538
10539         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10540         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10541
10542 2003-01-27    <johan AT balder>
10543
10544         * src/SDCC.y: fixed bug #613764
10545
10546 2003-01-26    <johan AT balder>
10547
10548         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10549         * src/SDCCsymt.h: fixed bug #673374
10550         * src/SDCCglue.c: fixed bug #661910
10551         * src/SDCCast.c: fixed bug #458099 and 673374
10552
10553 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10554
10555         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10556         * as/mcs51/strcmpi.h: added
10557         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10558         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10559         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10560         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10561         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10562         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10563         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10564         * as/mcs51/Makefile.aslink: new module strcmpi
10565         * as/mcs51/Makefile.asx8051: new module strcmpi
10566         * as/mcs51/Makefil.bcc: new module strcmpi
10567         * as/mcs51/Makefile.in: new module strcmpi
10568         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10569
10570 2003-01-26    <johan AT balder>
10571
10572         * src/SDCCglue.c: reverted back to 1.124
10573         * src/SDCCast.c: reverted back to 1.156
10574         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10575
10576 2003-01-25    <johan AT balder>
10577
10578         * src/SDCCglue.c: A better fix for bug #661910
10579         * src/SDCCast.c: A better fix for bug #661910
10580         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10581
10582 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10583
10584         * src/Makefile.in: remove spawn.o
10585         * src/SDCCmain.c: remove spawn.h
10586         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10587         * src/spawn.c: removed
10588         * src/spawn.h: removed
10589         * support/regression/ports/ds390/spec.mk: link with -r
10590
10591 2003-01-24    <johan AT CP255758-A>
10592
10593         * src/ds390/gen.c (aopOp): fixed bug #667458
10594         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10595         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10596         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10597
10598 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10599
10600         * src/mcs51/peeph.def: better assembler identation by Frieder
10601         * src/mcs51/gen.c: better assembler identation by Frieder
10602
10603 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10604
10605         * as/z80/string.h: removed for gcc 3.2
10606         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10607         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10608
10609 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10610
10611         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10612         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10613         * support/regression/Makefile: separate temp files for ports
10614         * support/regression/generate-cases.py: separate temp files for ports
10615         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10616         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10617
10618 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10619
10620         * moved tinitalk to device/examples/ds390
10621
10622 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10623
10624         * as/mcs51/lkmem.c: rflag is for DS390
10625         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10626         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10627                          (linkEdit): move mem- and map-files the same way as ihx-files
10628         * src/z80/main.c (_setDefaultOptions): removed --generic
10629         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10630         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10631         * src/pic/glue.c (picglue): --c1mode works again
10632         * src/pic16/glue.c (pic16glue): --c1mode works again
10633         * src/asm.c (printCLine): fix #660034
10634
10635 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10636
10637         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10638         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10639         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10640         * as/mcs51/lkmem (summary): better fix for sp problem
10641         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10642         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10643         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10644                                               remove --stack-after-data
10645
10646 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10647
10648         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10649         * src/SDCCutil.c (join): ugly bug: missing '\0'
10650         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10651
10652 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10653
10654         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10655         * src/port.h: typo
10656         * src/pic/main.c (_asmCmd): gpasm supports -o
10657         * src/z80/main.c: more general macros
10658         * device/lib/Makefile.in: remove intermediate files
10659
10660 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10661
10662         * .version: Bumped version number to 2.3.3
10663         * src/SDCCBBlock.c: new option -o
10664         * src/SDCCglobl.h: new option -o
10665         * src/SDCCglue.c: new option -o
10666         * src/SDCCmain.c: new option -o
10667         * src/asm.c: new option -o
10668         * src/ds390/main.c: new option -o
10669         * src/pic/glue.c: new option -o
10670         * src/pic/pcode.c: new option -o
10671         * src/pic/ralloc.c: new option -o
10672         * src/pic16/glue.c: new option -o
10673         * src/pic16/pcode.c: new option -o
10674         * src/pic16/ralloc.c: new option -o
10675         * src/z80/main.c: new option -o
10676         * device/lib/Makefile.in: use -o
10677         * support/regression/ports/ds390/spec.mk: use -o
10678         * support/regression/ports/gbz80/spec.mk: use -o
10679         * support/regression/ports/mcs51/spec.mk: use -o
10680         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10681         * support/regression/ports/z80/spec.mk: use -o
10682         * support/regression/ports/ucz80/spec.mk: use -o
10683         * support/regression/ports/xa51/spec.mk: use -o
10684         * support/regression/fwk/lib/timeout.c: fix usage string
10685
10686 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10687         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10688
10689 2003-01-07    <johan AT balder>
10690
10691         * src/SDCCast.c (decorateType): fixed bug #600035
10692
10693 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10694         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10695         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10696         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10697         * src/pic/pcode.c: outcommented unused variable to remove warnings
10698         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10699
10700 2003-01-06    <karl AT turbobit.com>
10701         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10702    regression tests.
10703
10704 2003-01-06    <johan AT balder>
10705
10706         * src/SDCCicode.c: fixed array add
10707
10708 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10709         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10710         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10711
10712 2003-01-04    <johan AT balder>
10713
10714         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10715
10716 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10717         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10718
10719 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10720         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10721         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10722
10723 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10724         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10725
10726 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10727         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10728
10729 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10730         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10731
10732 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10733
10734     * in \sdcc\as\mcs51\ changed these files in order to create an
10735     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10736     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10737     following files to include the previous two files: aslink.dsp,
10738     Makefile.aslink, Makefile.bcc, and Makefile.in.
10739
10740     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10741     .adb instead of .cdb
10742
10743 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10744
10745         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10746         value from option --iram-size.
10747
10748 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10749
10750         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10751         dram[] array.
10752
10753 2002-09-18    <wiml AT hhhh.org>
10754
10755         * SDCClrange.h: exposed setFromRange() and setToRange()
10756         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10757           packRegsForAccUse() (bug 542397)
10758         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10759           multiple times and emitting the fetch operations more than once
10760           added aopGetUsesAcc() function to allow binary operators to
10761           fetch their operands in the correct order; made genMinus() emit
10762           compact code for X = LITERAL - Y
10763
10764 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10765         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10766         sprintf() in line 1267.
10767
10768 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10769         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10770         like ports.
10771
10772 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10773         Changes to aslink (All the changes are marked with 'JCF'):
10774
10775         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10776         summary().
10777
10778         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10779         area BSEG.  Also moves, if possible, the DATA area down into the internal
10780         ram so more space is available.
10781
10782         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10783         sflag.
10784
10785         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10786         not bytes.  Function summary() which creates a memory usage summary
10787         file with extension .mem.  Reports of overlaping stack and small stack
10788         size.  If the space for the stack is less than 16 bytes aslink trows a
10789         warning.
10790
10791         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10792         the 8051.  Option 'y' for memory summary output file.
10793
10794         Changes to sdcc (All the changes are marked with 'JCF'):
10795
10796         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10797
10798         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10799         overlaying area for it (uses RegBankUsed[4]).
10800
10801         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10802         bank zero as used by default.  By default aslink locates the stack
10803         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10804         the creation of the .mem file.  Delegates the allocation of data area
10805         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10806         the begining of the stack area to aslink.
10807
10808         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10809         glue() in SDCCglue.c creates an area for it.
10810
10811 2002-09-03  Borut Razem <borut.razem AT siol.net>
10812         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10813         sdcc/src/pic/glue.c:
10814         introduced atexit() handler for teporay files removal in case of
10815         errors, assertions, ...
10816
10817 2002-08-29  Borut Razem <borut.razem AT siol.net>
10818         * sdcc/support/cpp2/auto-host_vc_in.h:
10819         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10820         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10821         Maybe there is a similar problem with BORLANDC? It should be checked!
10822
10823         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10824         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10825         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10826         was not executed, and the compiler (cl) launched a warning:
10827         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10828
10829 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10830         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10831
10832 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10833         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10834
10835         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10836           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10837           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10838           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10839           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10840           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10841           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10842         - added Release configuration in VS projects
10843         - review of compiler an linker options
10844         - VC .exe files are generated in bin_vc directory, not to interfere
10845           with binaries generated from other projects (cygwin, mingw, bcc ...)
10846
10847         * sdcc/src/yacc.dsp: added
10848
10849         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10850         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10851         and insert the version number definitions from .version
10852
10853         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10854
10855         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10856         added - genarate auto-host.h using auto-host_vc_in.h as template
10857
10858         * sdcc/sdcc_vc.h,
10859         removed from CVS, generated automatically
10860
10861 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10862         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10863
10864 2002-08-11  Borut Razem <borut.razem AT siol.net>
10865         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10866
10867 2002-08-10  Borut Razem <borut.razem AT siol.net>
10868         * src/SDCCmain.c (main):
10869         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10870         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10871         The consequence was that some temporary files were not removed.
10872
10873         * src/SDCCglue.c:
10874         unification of code in functions tempfilename() and tempfile():
10875         function tempnam() is defined in Visual Studio 6.0 and .NET
10876
10877         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
10878
10879         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10880           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
10881         - removed compiler command line option /WX: Treats all warnings as errors
10882         - update a list of source files, included into the project
10883
10884         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10885           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10886         changed project type to Generic Project so that can be correcly converted to VS.NET project
10887
10888         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10889
10890         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10891
10892         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10893
10894         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10895         added return 0 statements after assert() to make compiler happy
10896
10897         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10898         added newline in the def file to keep MSC compiler satisfied
10899
10900         * sdcc/src/z80/gen.c:
10901         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10902           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10903         - solved MSC error in function aopDump()
10904
10905         * sdcc_vc.h: define PREFIX as "\\sdcc"
10906
10907 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10908         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10909
10910 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10911         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10912         - Rewrote the register banking algorithm.
10913         - Added pCode live-range analysis to registers (for now, only non-used and
10914         singly-used registers optimized away)
10915
10916         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10917
10918         * 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.
10919
10920 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10921         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10922
10923 2002-04-22  Michael Hope  <michaelh AT vroom>
10924
10925         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10926
10927         * configure.in (DD_COPT): Added include support required for gbdk.
10928
10929         * .version: Bumped version number just to increase it.
10930
10931         * src/SDCCmain.c: Added -nostdinc to the default options.
10932
10933 2002-04-15  Michael Hope  <michaelh AT vroom>
10934
10935         * device/lib/z80/printf.c (sprintf): Added.
10936
10937         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10938
10939         * src/z80/peeph.def: Added transpose redundent load rule.
10940
10941         * src/z80/main.c: Added force callee saves for jaune.
10942
10943         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10944
10945         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10946
10947 2002-03-28  Johan Knol  <johan AT balder>
10948
10949         * src/SDCCval.c: fixed bug #532436
10950
10951 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10952         * /src/port.h:
10953         Added "char *Processor" field to the port structure.
10954
10955         * /src/SDCCmain.c:
10956         Added -p option. Allows port dependent processor to be specified.
10957
10958         * all ports:
10959         Initialized the new field char *Processor field to NULL in all ports
10960
10961         * /src/pic/*:
10962         Compiler generated registers for interrupt context saving
10963         were not getting allocated.
10964
10965 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10966
10967         * /src/SDCCast.c:
10968         Fixed left shift. Will promote the left side of a left shift
10969         if a) left shifting more than size of operand or b) when assigned
10970         to something size > size of left side
10971
10972 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10973         * src/pic/*
10974         tons of changes. Register allocation has been
10975         rewritten. Added customization for the various PICs. Flow
10976         analysis is restructured. ...
10977
10978         * src/pic/device.h:
10979         Added
10980
10981         * src/pic/device.c:
10982         Added. device.c is a PIC port hack to accomodate variations
10983         in PIC devices.
10984
10985 2002-03-13  Michael Hope  <michaelh AT vroom>
10986
10987         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10988
10989 2002-03-04  johanknol  <johanknol AT manik>
10990
10991         * /src/SDCCval.c: fixed
10992
10993         const unsigned char arr[][2] = { { 0, 1 } };
10994         t18.c:1: error: Initializer element is not constant
10995
10996 2002-03-04  bela  <bela AT manik>
10997
10998         * /device/include/mcs51reg.h:
10999         ds89c420 register definition update
11000
11001 2002-03-03    <johan AT FRIJA>
11002
11003         * support/Util/SDCCerr.c: did something, but don't no why anymore
11004
11005         * support/regression/tests/bug-524691.c: made it a little less shy
11006
11007         * src/SDCCast.c (decorateType): fixed bug #524697
11008
11009         * src/SDCCast.c: made some lineno improvements
11010
11011         * src/SDCCval.c (getNelements): changed warning to error
11012
11013         * src/SDCCglue.c (printIvalArray): changed warning to error
11014
11015         * src/SDCCicode.c: fixed a warning for mingw
11016
11017         * src/SDCCast.c (decorateType): fixed the << promotion for ops
11018
11019         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
11020
11021 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
11022
11023         * src/ds390/peeph.def:
11024         Added some more peephole rules
11025
11026         * src/ds390/gen.c: Various fixes & enhancements
11027
11028         * src/SDCClrange.c, src/SDCClrange.h:
11029         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
11030
11031         * src/ds390/ralloc.c:
11032         various fixes & enhancements (ds390) specific
11033
11034         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
11035         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
11036         from rallocs.
11037
11038         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
11039
11040 2002-03-02    <johan AT FRIJA>
11041
11042         * src/SDCCast.c (decorateType): fixed bug #524708
11043
11044         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
11045
11046         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
11047
11048 2002-03-01  Michael Hope  <michaelh AT vroom>
11049
11050         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
11051
11052         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
11053
11054 2002-03-01    <johan AT FRIJA>
11055
11056         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
11057
11058         * src/SDCCast.c (decorateType): fixed bug #524209
11059
11060         * src/SDCCval.c (valNot): fixed bug #524195
11061
11062 2002-02-26    <johan AT balder>
11063
11064         * src/xa51/gen.c: fixed a warning
11065
11066         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
11067
11068         * src/SDCCast.c (decorateType): fixed bug #522534
11069
11070 2002-02-23    <johan AT balder>
11071
11072         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
11073
11074 2002-02-22    <johan AT balder>
11075
11076         * src/SDCCast.c: fixed bug #514865
11077
11078         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
11079
11080 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
11081
11082         * sdcc/src/SDCCloop.c:
11083         Previous fix was not good. basic blocks that have "break" or "return" are
11084         not really partof a loop , but live ranges used in these blocks should
11085         be live thru the entire loop, so set partOfLoop but don't add them to
11086         loop region
11087
11088 2002-02-21    <johan AT FRIJA>
11089
11090         * src/SDCCcse.c: fixed bug #514308
11091
11092 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
11093
11094         * src/SDCCloop.c:
11095         Fixed BUG #519583. If a conditional block ended in a return/break
11096         statement inside a loop, it was not being considered part of the loop.
11097
11098         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
11099
11100 2002-02-10  Karl Bongers <karl AT turbobit.com>
11101
11102         * debugger/*:
11103         Fixed up SDCDB debugger somewhat.  Updated debugger/README
11104         with lots of comments and notes.
11105
11106         * device/examples/test2.c:
11107         Fix bug, "red" variable not being initialized(compiler complained).
11108
11109         * device/examples/Makefile, examples/test3.c:
11110         Add Makefile in device/examples folder, compiles test3.c
11111         for use as a multiple module SDCDB test case.
11112
11113         * sim/ucsim/cmd.src/cmdset.cc:
11114         Took out debug printfs in ucsim "next" command.
11115
11116         * sim/ucsim/xa.src:
11117         Karl and Johan start ucsim XA support.  Most dissassembly working,
11118         about 75% emulation done(plenty of work remaining).
11119
11120         * sim/ucsim/z80.src:
11121         Add Z80 support to ucsim, add test-ucz80 regression test,
11122         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
11123         Notice z80 compiler fails on examples/test3.c/crc code.
11124
11125 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
11126
11127         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
11128         Added support for --parms-in-bank1
11129
11130         * src/ds390/peeph.def:
11131         added a few more peephole optimzations
11132
11133         * src/ds390/main.c:
11134         1) added __builtin_inp & __builtin_outp used to read in data of given length
11135            from a memory mapped port
11136         2) added __builtin_memcmp
11137         3) added __builtin_swapw swap bytes of a short
11138
11139         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
11140         1) handle multiple send & receives from register bank1
11141         2) ralloc can now allocate DPTR1 to some liveRanges
11142
11143         * src/SDCCsymt.c, src/SDCCsymt.h:
11144         changes to handle multiple sends & receives
11145
11146         * src/SDCCptropt.h:
11147         added some pointer arithmetic optimization
11148
11149         * src/SDCCptropt.c:
11150         added some pointer arithmetic optimizations but not stable yet so not
11151         called from anywhere (will get this working shortly)
11152
11153         * src/SDCCopt.c: fixed for multiple sends & receives
11154
11155         * src/SDCCmain.c:
11156         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
11157         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
11158            set preprocessor defines (depending on options)
11159
11160         * src/SDCCicode.c, src/SDCCicode.h:
11161         changes made to handle multiple sends & receives
11162
11163         * src/SDCCglobl.h:
11164         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
11165
11166         * src/SDCCcse.c, src/SDCCcse.h:
11167         added function findbackward def (to be used in upcoming optimization)
11168
11169         * src/SDCCcflow.c, src/SDCCcflow.h:
11170         added function returnAtEnd - to determine if a basic block terminates with
11171         a RETURN iCode
11172
11173         * src/SDCCast.c, src/SDCCast.h:
11174         added option parms-in-bank1
11175
11176         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
11177         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
11178         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
11179         adjusted for --parms-in-bank1 option
11180
11181         * device/include/string.h:
11182         donot redefine "reentrant" keyword
11183
11184         * device/include/ds80c390.h: Added some more SFRs
11185
11186 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
11187
11188         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
11189
11190 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
11191
11192         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
11193
11194 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
11195
11196         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
11197
11198 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
11199
11200         * Added --xram-movc option
11201
11202 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
11203
11204         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
11205
11206 2002-01-11  Johan Knol
11207
11208         * Added math lib of Jesus Calvino-Fraga
11209
11210 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
11211
11212         * src/SDCCmain.c (processFile): fix processing of ../../src.c
11213         * support/regression/Makefile: new target test-mcs51-stack-auto
11214         * support/regression/ports/mcs51-stack-auto/spec.mk: added
11215
11216 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11217
11218         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
11219
11220 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11221
11222         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
11223
11224 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
11225
11226         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
11227
11228         * src/SDCCglue.h: add definition for printIvalChar()
11229
11230 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11231
11232         * src/SDCCast.c: fix #498138 by Johan
11233
11234         * src/SDCCglue.c: fix #498138 by Johan
11235
11236 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11237
11238         * support/regression/Makefile: fix clean
11239
11240         * support/regression/ports/ds390/support.c: fix transmission of last character
11241
11242 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
11243
11244         * /sdcc/src/ds390/gen.c:
11245         a) improved computing address of stack variable
11246         b) took out some #if 0 code
11247         c) improved parmBytes adjustment
11248         d) improved genPlusIncr & genMinusIncr
11249         e) genCmp could generate bad code (when left assigned to DPTR)
11250         f) Fixed bug in hasInc
11251
11252         * /sdcc/src/ds390/ralloc.c:
11253         a) packRegsForSupport could mess up live information (Fixed)
11254         b) packRegsDPTRuse could be incorrect for left & right shift
11255
11256         * /sdcc/src/mcs51/ralloc.c:
11257         packRegsForSupport could mess up the live information (Fixed)
11258
11259         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
11260
11261         * /sdcc/src/SDCCast.c:
11262         can reverse a loop even if function call is present as long
11263         as the loop control variable is local & is not passed as parameter
11264
11265 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11266
11267         * /sdcc/ChangeLog: *** empty log message ***
11268
11269         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
11270         More builtin function additions for TININative
11271
11272         * /sdcc/src/ds390/ralloc.c:
11273         Had broken the regression testsuite
11274
11275         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
11276
11277         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
11278         Added funcattr hasStackParms will be set for reentrant functions when there
11279         are paramteres on the stack, this helps in minimizing frame pointer generation
11280         typeFromStr can handle function pointers now
11281
11282         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
11283         *** empty log message ***
11284
11285 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11286
11287         * /src/ds390/gen.c, /src/ds390/main.c:
11288         More builtin function additions for TININative
11289
11290         * /src/ds390/ralloc.c:
11291         Had broken the regression testsuite
11292
11293         * /src/SDCCast.c: Fixed a bug in dumptree
11294
11295         * /src/SDCCsymt.c, /src/SDCCsymt.h:
11296         Added funcattr hasStackParms will be set for reentrant functions when there
11297         are paramteres on the stack, this helps in minimizing frame pointer generation
11298         typeFromStr can handle function pointers now
11299
11300         * /doc/builtins.txt, /doc/TININative.txt:
11301         *** empty log message ***
11302
11303
11304 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11305
11306         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
11307         ALPHA version for -mTININative
11308
11309         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
11310         updated to reflect changes in the port structure
11311
11312         * /src/port.h:
11313         added function do_assemble (similar to do_link) if non-null this function
11314         will be called to do assembly (-mTININative) requires a multi command
11315         assembly
11316         added function genAssemblerEnd will be called to generate assembler Epilogue
11317
11318         * /src/SDCCsymt.c:
11319         added _JavaNative to debug info printing
11320
11321         * /src/SDCCmain.c: added option --tini-libid
11322         added port->do_assemble function (-mTININative) has a multi command assemble
11323
11324         * /src/SDCCglue.c: Disabled "constExpr" check
11325         added port->genAssemblerEnd function
11326
11327         * /src/SDCCglobl.h: Added option --tini-libid value
11328
11329         * /src/SDCCast.h:
11330         tookout optimizeCompare from the header (has no external references)
11331
11332         * /src/SDCCast.c: made one more function "static"
11333
11334 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
11335
11336         * src/z80/mappings.i: Added z80asm support.
11337
11338         * src/z80/main.c: Added z80asm support on --asm=z80asm
11339
11340         * src/z80/gen.c: Fixed asm portability issues.
11341
11342         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
11343
11344         * src/SDCCglue.c (printExterns): Added global/extern split.
11345
11346 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
11347
11348         * support/regression/Makefile: added test for mcs51 model large
11349
11350         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
11351
11352         * support/regression/ports/gbz80/spec.mk: added -mgbz80
11353
11354 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
11355
11356         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
11357
11358 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
11359
11360         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
11361
11362         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
11363
11364 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
11365
11366         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
11367
11368         * support/regression/tests/simplefloat.c: Port to mcs51.
11369
11370 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
11371         * support/regression/tests/bug-485362.c: Added.
11372
11373         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
11374
11375         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
11376
11377         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
11378
11379         * src/z80/gen.c (aopDump): Added a dump function.
11380
11381 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
11382         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
11383
11384         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
11385
11386         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
11387
11388         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
11389
11390         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
11391
11392         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
11393
11394         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
11395
11396         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
11397
11398         * support/regression/ports/ds390/support.c: Use tinibios.
11399
11400         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
11401
11402 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
11403
11404         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
11405         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
11406
11407         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
11408
11409         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
11410
11411 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
11412
11413         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
11414
11415         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
11416         (packRegsForIYUse): Created and optimised.
11417
11418 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11419
11420         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
11421 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
11422
11423         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
11424
11425         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
11426
11427         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
11428
11429 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11430
11431         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
11432
11433         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
11434
11435 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11436
11437         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
11438
11439         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
11440
11441         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
11442
11443 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11444
11445         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
11446         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
11447         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
11448
11449         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
11450
11451         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
11452         (genNotFloat): Added.
11453         (genUminusFloat): Added.
11454
11455         * device/lib/z80/Makefile: Added floating pt stubs.
11456
11457         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11458
11459         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11460
11461         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11462
11463 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11464
11465         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11466
11467         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11468
11469         * sdcc/support/regression/Makefile: Add port ds390.
11470
11471         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11472
11473         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11474
11475         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11476
11477         * sdcc/support/regression/ports/ds390/support.c: Added.
11478
11479         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11480
11481         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11482
11483         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11484
11485 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11486
11487         * device/include/malloc.h: Added z80 and gbz80 support.
11488
11489         * device/lib/gbz80/heap.s: Added.
11490
11491         * device/lib/z80/heap.s: Added.
11492
11493         * device/lib/malloc.c: Added z80 and gbz80 support.
11494
11495         * support/regression/tests/malloc.c (testMalloc): Added.
11496
11497         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11498
11499         * support/regression/tests/bug-478094.c: Added.
11500
11501         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11502
11503 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11504
11505         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11506
11507         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11508
11509         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11510
11511         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11512
11513         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11514
11515 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11516
11517         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11518
11519 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11520
11521         * support/regression/tests/bug-477927.c: Added.
11522
11523         * src/z80/peeph.def: Added minor rules.
11524
11525         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11526
11527         * src/z80/peeph.def: Added jump optimisation modification.
11528
11529 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11530
11531         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11532
11533 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11534
11535         * support/regression/tests/funptrs.c: Added.
11536
11537 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11538
11539         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11540
11541 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11542
11543         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11544
11545         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11546
11547         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11548         (movLeft2ResultLong): Created.
11549
11550         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11551         (joinPushes): Added.  Joins two char pushes into a word push.
11552
11553 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11554
11555         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11556
11557         * support/makebin/Makefile (install): Added creation of dest dir.
11558
11559 2001-10-24 Karl Bongers <karl AT turbobit.com>
11560
11561         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11562
11563 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11564
11565         * src/z80/ralloc.c: Turned off faulty pack for one use.
11566
11567         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11568
11569         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11570
11571 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11572
11573         * support/regression/Makefile: Improved clean
11574
11575         * support/regression/ports/gbz80/spec.mk: Added clean
11576
11577         * support/regression/ports/host/spec.mk: Added clean
11578
11579         * support/regression/ports/z80/spec.mk: Added clean
11580
11581         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11582
11583         * support/regression/ports/mcs51/timeout.c: little improvements
11584
11585 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11586
11587         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11588
11589         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11590
11591         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11592
11593 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11594
11595         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11596
11597         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11598
11599 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11600         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11601
11602         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11603
11604         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11605
11606         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11607
11608         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11609
11610         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11611
11612         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11613
11614         * support/regression/tests/longor.c: Added.
11615
11616 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11617
11618         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11619
11620         * as/mcs51/aslink.h: define PATH_MAX
11621
11622         * as/mcs51/asm.h: define PATH_MAX
11623
11624         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11625
11626         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11627
11628         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11629
11630         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11631
11632         * src/SDCCglobl.h: define PATH_MAX
11633
11634         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11635
11636         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11637
11638 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11639
11640         * src/z80/gen.c (gencjneshort): Fixed
11641
11642         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11643
11644 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11645
11646         * support/regression/tests/bug-469671.c: Added.
11647
11648         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11649
11650 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11651
11652         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11653
11654         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11655
11656 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11657
11658         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11659
11660         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11661
11662         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11663
11664         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11665
11666         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11667
11668         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11669
11670         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11671
11672 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11673
11674         * 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.
11675
11676         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11677
11678         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11679
11680 2001-10-07    <johan AT FRIJA>
11681
11682         * device/lib/gets.c (gets): fixed the return value.
11683
11684 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11685         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11686
11687         * 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.
11688
11689         * 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.
11690
11691         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11692
11693         * src/pic/gen.c: Removed Safe_strdup.
11694
11695         * configure.in: Added option to enable libgc support.
11696
11697         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11698         (bitVectUnion): Optimised.
11699         (bitVectIntersect): Optimised.
11700         (bitVectBitsInCommon): Optimised.
11701         (bitVectCplAnd): Optimised.
11702
11703         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11704
11705 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11706
11707         * src/SDCCmain.c: distinguish between assembler debug and plain options
11708
11709         * src/avr/main.c:   remove standard assembler options
11710
11711         * src/ds390/main.c: remove standard assembler options
11712
11713         * src/mcs51/main.c: remove standard assembler options
11714
11715         * src/port.h: removed "PENDING" comment
11716
11717 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11718
11719         * src/device/lib/_mulint.c  : new, with assember functions
11720
11721         * src/device/lib/_mullong.c : new, with assember functions
11722
11723         * src/device/lib/_divuint.c : with assember functions
11724
11725         * src/device/lib/_divsint.c : with assember functions
11726
11727         * src/device/lib/_divulong.c: with assember functions
11728
11729         * src/device/lib/_divslong.c: with assember functions
11730
11731         * src/device/lib/_moduint.c : with assember functions
11732
11733         * src/device/lib/_modsint.c : with assember functions
11734
11735         * src/device/lib/_modulong.c: with assember functions
11736
11737         * src/device/lib/_modslong.c: with assember functions
11738
11739         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11740
11741         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11742
11743         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11744                                       replaced _mululong.c and _mulslong.c by _mullong.c
11745
11746 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11747
11748         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11749
11750 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11751
11752         * src/SDCCglue.c: test, if win32api is available for MINGW
11753
11754 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11755
11756         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11757         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11758         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11759         * support/regression/ports/host/spec.mk: removed GENERIC
11760         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11761         * support/regression/ports/z80/spec.mk: removed GENERIC
11762
11763 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11764
11765         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11766
11767         * support/regression/tests/bug-467035.c: Created.
11768
11769 2001-10-01    <johan AT FRIJA>
11770
11771         * src/SDCC.y: fixed bug #466586 part 1
11772
11773 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11774
11775         * SDCCicode.c: z80 has no generic pointers
11776         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11777
11778 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11779
11780         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11781
11782 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11783
11784         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11785
11786         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11787
11788 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11789
11790         * configure.in: Fixed up so that ucsim is only configured once.
11791
11792         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11793
11794         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11795         (getPathDifference): As above.
11796
11797         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11798
11799         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11800
11801 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11802         * .version: Updated to 2.3.1
11803
11804         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11805         Added copyright header.
11806
11807         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11808         (assemble): Added support for macro based assembler commands.
11809         (linkEdit): Added support for macro based linker commands.
11810         (preProcess): Changed the pre-processor to use macros.
11811         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11812         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11813
11814         * device/lib/z80/crt0.s: Added module name for debugging.
11815
11816 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11817
11818         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11819
11820         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11821
11822         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11823
11824         * src/Makefile.in: Added SDCCmacro and SDCCutil
11825
11826 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11827
11828         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11829
11830 2001-09-16    <johan AT FRIJA>
11831
11832         * 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.
11833
11834 2001-09-15    <johan AT FRIJA>
11835
11836         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11837         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11838
11839 2001-09-11    <johan AT FRIJA>
11840
11841         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11842
11843 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11844
11845         * support/regression/tests/bug-460444.c: Added test case.
11846
11847         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11848         (genCast): Added justification for all of the asserts.
11849
11850 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11851
11852         * support/regression/support.c: _xdata replaced by xdata
11853
11854         * support/regression/spec.mk: removed _generic
11855
11856 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11857
11858         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11859
11860         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11861         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11862
11863         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11864
11865         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11866
11867         * support/regression/tests/bug-460010.c: Added test case.
11868
11869         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11870
11871 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11872
11873         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11874
11875         * support/regression/testfwk.c: removed workaround for bug #436344
11876
11877         * support/regression/tests/bp.c: use less memory with mcs51
11878
11879         * support/regression/tests/bug-441448.c: use less memory
11880
11881         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11882
11883         * support/regression/collate-results.py: typo
11884
11885 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11886
11887         * support/regression/tests/fetchoverlap.c: Added new test case.
11888
11889         * support/regression/tests/bp.c: Added new test case.
11890
11891         * support/regression/tests/bug-448984.c: Added new test case.
11892
11893         * support/regression/tests/pow2shifts.c: Added new test case.
11894
11895         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11896         (genlshTwo): Fixed right shift for count > 8.
11897
11898         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11899
11900 2001-09-08    <johan AT FRIJA>
11901
11902         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11903
11904 2001-09-07    <johan AT FRIJA>
11905
11906         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11907
11908         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11909
11910 2001-09-06    <johan AT FRIJA>
11911
11912         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11913         * bernhard noted me at this: "() equals to (void)" (1.38)
11914
11915 2001-09-05    <johan AT FRIJA>
11916
11917         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11918
11919 2001-09-04    <johan AT FRIJA>
11920
11921         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11922
11923
11924 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11925
11926         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11927
11928 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11929
11930         * link/z80/aslink.h: Fixed path for PATH_MAX
11931
11932 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11933
11934         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11935
11936         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11937
11938         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11939
11940         * 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.
11941
11942 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11943
11944         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11945         (genCmp): Fixed up genCmp for the GB with longs.
11946
11947         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11948
11949         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11950
11951         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11952
11953         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11954
11955 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11956
11957         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11958
11959 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11960
11961         * 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.
11962
11963         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11964
11965 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11966
11967         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11968
11969         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11970
11971 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11972
11973   * sim/ucsim/configure:    little improvement of Cygwin-detection
11974   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11975   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11976   * support/regression/tests/bug-221100.c: small changes for mcs51
11977   * support/regression/tests/bug-221168.c: small changes for mcs51
11978   * support/regression/tests/bug-227710.c: small changes for mcs51
11979   * support/regression/tests/staticinit.c: small changes for mcs51
11980   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11981   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11982   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11983
11984 $Revision$