* src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
[fw/sdcc] / ChangeLog
1 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
4
5 2006-07-06 Borut Razem <borut.razem AT siol.net>
6
7         * support/regression/tests/bitfields.c:
8           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
9         * support/regression/tests/constantRange.c:
10           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
11
12 2006-07-04 Borut Razem <borut.razem AT siol.net>
13
14         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
15           src/port.mk,
16           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
17           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
18           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
19           reverted changes from 2006-07-03
20         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
21         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
22           added CPPFLAGS, used by the host port
23
24 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
25
26         * support/regression/valdiag/tests/switch.c,
27         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
28         * support/regression/tests/libmullong.c: fixed for host
29         * support/regression/ports/host/spec.mk: disable all warnings for host,
30         SDCC runs with --less-pedantic too
31
32 2006-07-03 Borut Razem <borut.razem AT siol.net>
33
34         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
35           defined CPPFLAGS
36         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
37         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
38           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
39           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
40           include ../port.mk
41         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
42           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
43           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
44           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
45
46 2006-07-02 Raphael Neider <rneider AT web.de>
47
48         * src/pic16/devices.inc,
49         * device/include/pic16/pic18fregs.h,
50         * device/include/pic16/pic18f4550.h,
51         * device/lib/pic16/pics.all,
52         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
53
54 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
55
56         * as/hc08/lkaomf51.c (OutputName),
57         * as/mcs51/lkaomf51.c (OutputName),
58         * as/z80/asmain.c (asmbl),
59         * src/ds390/main.c (asmLineNodeFromLineNode),
60         * src/hc08/ralloc.c (hc08_assignRegisters),
61         * src/mcs51/main.c (asmLineNodeFromLineNode),
62         * src/xa51/ralloc.c (checkRegMask),
63         * src/xa51/gen.c (emitcode),
64         * src/z80/gen.c (_emit2),
65         * src/SDCCast.c (searchLitOp),
66         * src/SDCCglobl.h,
67         * support/packihx/packihx.c,
68         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
69         * src/ds390/gen.c (aopPutUsesAcc),
70         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
71         * support/regression/tests/libmullong.c (mullong_wrapper),
72         * src/SDCCsymt.c (powof2),
73         * src/SDCCast.c,
74         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
75         * src/SDCCsymt.h: added TYPE_TARGET_*
76         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
77         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
78         SDCCast because 1) header problems 2) this is the right place
79         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
80         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
81         prototype
82
83 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
84
85         * src/SDCCicode.h: removed buggy semicolon in unused macro
86         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
87         search for previous definiton of auto symbols too,
88         (findPrevUse): fixed logic of emitWarnings
89
90 2006-06-26 Raphael Neider <rneider AT web.de>
91
92         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
93           PCLATH and PCLATU on interrupts, potentially fixes #1505141
94
95 2006-06-25 Raphael Neider <rneider AT web.de>
96
97         * device/lib/pic/libm: NEW, added math library functions
98         * device/lib/pic/libsdcc: NEW; added float support functions
99         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
100         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
101           NEW, added math related headers
102         * device/include/asm/pic/features.h: NEW
103         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
104           (popGet): allow larger offsets for AOP_PCODE,
105           (genDataPointerSet): handle literals explicitly, more debug output,
106           (genAssign): fixed for float using aopLiteral ;-)
107         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
108           GOTO initialisation routine
109         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
110           flag on registers, fixes #1469043 (local variables do not work)
111         * src/pic/main.c (_pic14_do_link),
112         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
113           available
114
115 2006-06-25 Borut Razem <borut.razem AT siol.net>
116
117         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
118           characters printed (not including the trailing '\0' used to end
119           output to strings). Problem detected in regression test bug-927659.c.
120           NOTE: printf() family functions should return int instead
121           unsigned int!
122         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
123           specifier are printed as themselves
124         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
125           support flags, width and precision specifiers
126
127 2006-06-24 Borut Razem <borut.razem AT siol.net>
128
129         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
130           to the list of sdcc tagrets not supporting bit type
131         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
132           testfor pic16 due to bug:
133           [ 1511794 ] pic16: regression test bug-895992.c fails
134
135 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
136
137         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
138         * src/SDCCglue.c (initPointer), fixed bug 1496419
139         * support/regression/tests/bug1496419.c: new, added
140
141 2006-06-22 Borut Razem <borut.razem AT siol.net>
142
143         * support/regression/ports/pic16/support.c: use gpsim usart module from
144           libgpsim_modules library
145
146 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
147
148         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
149         IP0H to IPH0.
150
151 2006-06-19 Raphael Neider <rneider AT web.de>
152
153         * src/pic/glue.h,src/pic16/glue.h: added prototypes
154         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
155           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
156           (pic14printExterns,pic14printPublics,pic16printPublics,
157           pic16_printExterns): use new functions to emit symbols
158           (picglue,pic16glue): emit publics before emitting externs
159         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
160           locally defined functions to avoid bug #1443651
161         * support/regression/tests/bug-716242.c: removed pic16 workaround
162         * support/regression/ports/pic16/spec.mk: ignore errors during build
163
164 2006-06-19 Raphael Neider <rneider AT web.de>
165
166         * src/pic/glue.h: added pic14aopLiteral prototype
167         * src/pic/glue.c (pic14aopLiteral): return unsigned int
168         * src/pic/gen.c: removed stdint.h dependency
169           (aopGet): use Safe_strdup()
170           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
171           (genDataPointerSet): use pic14aopLiteral()
172         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
173           for pic16; thanks to Bernhard and Maarten
174
175 2006-06-18 Borut Razem <borut.razem AT siol.net>
176
177         * support/regression/tests/structflexarray.c: flexible array members
178           not supported by gcc < 3
179         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
180           GUI tool by default
181         * src/pic/gen.c: don't include [p]strdin.h on solaris
182         * support/Util/pstdint.h: addad svn attributes
183         * support/regression/tests/constantRange.c,
184           support/regression/tests/rotate.c: include inttypes.h instead
185           stdint.h on solaris, addad svn attributes
186
187 2006-06-18 Raphael Neider <rneider AT web.de>
188
189         * src/SDCCsymt.c (initCSupport): change return type of divschar to
190           int for PIC16
191         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
192           (pic16_genMinusBits): simplified sign-extension
193           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
194             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
195             adjusted to correctly handle mixed-signed operands, disabled
196             now unused multiplciation routines
197         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
198           (assignResultValue): added argument denoting the size of the result
199             as returned by the function (fixes upcasts in assigning from
200             function calls: char foo(); int i = foo();)
201           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
202             function result to assignResultValue
203           (genMult): disabled inlined multiplication code
204           (genDiv): augmented to also handle the modulus operator, fixed to
205             handle mixed-signed operands correctly
206           (genMod): simply call genDiv, disabled unused code
207           (genAssign): fixed missing (sign-)extension on result
208         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
209             valid char operands, allow signed operands for native code, added
210             division and modulo operator handling
211         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
212
213         As a consequence, onebyte.c (if split into two files) and muldiv.c
214         pass regression tests.
215
216 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
217
218         * doc/Makefile.in: two runs of makeindex seem needed to get
219         correct page references in the index of sdccman.pdf
220         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
221
222 2006-06-17 Borut Razem <borut.razem AT siol.net>
223
224         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
225
226 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
227
228         * doc/sdccman.lyx: updated, added (porting source code, debugging),
229         mentioned ec2drv and paulmon
230
231 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
232
233         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
234           consecutive abs areas
235           (find_empty_space, allocate_space): added map to handle codemap or
236            xdatamap,
237           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
238            absolute idata and xdata
239         * as/mcs51/lkmem.c (summary2): updated legend
240
241 2006-06-16 Raphael Neider <rneider AT web.de>
242
243         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
244
245 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
246
247         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
248           1208515
249         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
250
251 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
252
253         * src/port.h (struct PORT): added field gp_tags, to hold the tag
254         value of generic pointers,
255         * src/avr/main.c,
256           src/ds390/main.c,
257           src/hc08/main.c,
258           src/izt/i186.c,
259           src/izt/tlcs900h.c,
260           src/mcs51/main.c,
261           src/pic/main.c,
262           src/pic16/main.c,
263           src/xa51/main.c,
264           src/z80/main.c: PORT structure, added elements for gp_tags field,
265         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
266         fields in the PORT structure of each port,
267         * src/SDCCast.c (decorateType): allow processing of generic pointers
268         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
269         S_FIXED symbols
270
271 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
272
273         * link/z80/lkgb.c,
274         * link/z80/lkgg.c,
275         * src/pic16/gen.c,
276         * src/pic16/main.c,
277         * src/pic16/pcode.c,
278         * src/pic/main.c,
279         * src/pic/pcoderegs.c,
280         * src/SDCCicode.c,
281         * src/SDCCmain.c,
282         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
283           bug 1504689 on minGW
284
285 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
286
287         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
288
289 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
290
291         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
292
293 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
294
295         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
296           for optimization
297
298 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
299
300         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
301         to a char variable. Fixed bug #1504211
302         * device/include/pic16/adc.h,
303         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
304         and fixed bug #1364390
305
306 2006-06-10 Borut Razem <borut.razem AT siol.net>
307
308         * CVSROOT: removed the CVS left-over
309
310 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
311
312         * as/hc08/asmain.c (asexit),
313         * as/hc08/lkmain.c (lkexit),
314         * as/mcs51/asmain.c (asexit),
315         * as/mcs51/lkmain.c (lkexit),
316         * src/SDCCglue.c (DEFSETFUNC),
317         * src/SDCCmain.c (linkEdit, assemble),
318         * support/librarian/sdcclib.c (AddRel),
319           replaced unlink() by standard C remove()
320         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
321         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
322           gatherImplicitVariables): new, added to fix bug 608752,
323           (createFunction): added gatherImplicitVariables()
324         * src/SDCCast.h: added createRMW prototype
325         * src/SDCCsymt.h (struct symbol): added infertype
326         * support/regression/tests/bug608752.c: new, added
327
328 2006-06-10 Raphael Neider <rneider AT web.de>
329
330         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
331           multibyte dummy reads (fixes #1503234)
332
333 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
334
335         * device/include/mcs51/compiler.h: new, added header file to enable
336           creating common sfr definition header files for different compilers
337
338 2006-06-05 Raphael Neider <rneider AT web.de>
339
340         * src/pic16/{pcode.h,genarith.c}:
341           introduced pCodeOp combining any two pCodeOps (previously only
342           two register operands could be combined), removed pcop2 from
343           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
344         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
345         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
346           rewritten to use new PO_TWO_OPS
347         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
348         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
349           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
350           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
351           (pic16_get_op): embraced return arg to allow #define return(x),
352             added new case for combined opcodes
353           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
354           (pic16_pCode2str,pic16_getRegFrompCodeOp,
355            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
356
357 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
358
359         * src/SDCCval.c (checkConstantRange): added
360         * src/SDCCval.h: added checkConstantRange
361         * support/Util/SDCCerr.c,
362         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
363         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
364         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
365         * src/SDCCast.c (decorateType): added checkConstantRange,
366         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
367         can be emitted with the correct always true/false warning,
368         added optimization for double '!';
369         result of decorateType() must be assigned back to the tree, because
370         decorateType() can change the tree
371         * src/SDCCicode.c (geniCodeLogic),
372         (geniCodeAssign): replaced new checkConstantRange, added warnings,
373         (checkConstantRange): removed, it was only a fragment which never
374         emitted a warning
375         * src/SDCCsymt.c (computeType): fixed promotion for
376         "-1 < (unsigned bit) b"
377         * src/pic/ralloc.c (packRegsForAssign),
378         * src/pic16/ralloc.c (packRegsForAssign),
379         * src/hc08/ralloc.c (packRegsForAssign),
380         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
381         from mcs51
382         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
383         * support/regression/tests/constantRange.c: added
384         * support/valdiag/tests/constantRange.c: added
385         * support/valdiag/valdiag.py: added -DPORT_HOST=1
386
387 2006-06-02 Borut Razem <borut.razem AT siol.net>
388
389         * support/regression/ports/pic16/support.c: increase stack size
390           to 255 bytes
391         * support/regression/Makefile.in: sort tests by name so that the
392           resutlts can be compared on different machines / platforms
393
394 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
395
396         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
397         * src/ds390/gen.c (emitLabel): new, added,
398           (genDjnz): fixed stack overflow bug,
399           (throughout): cosmetic changes to sync with mcs51/gen.c,
400           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
401         * src/mcs51/gen.c (genEndFunction): small optimization,
402           (throughout): cosmetic changes to sync with ds390/gen.c
403
404 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
405
406         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
407           (_print_format): fixed printing pointers
408         * src/mcs51/gen.c (emitLabel, movb): new, added,
409           (genAssign): small optimization,
410           (genDjnz): fixed stack overflow bug,
411           (throughout): replaced sprintf with SNPRINTF,
412           replaced mcs51_regWithIdx with REG_WITH_INDEX,
413           replaced emitcode("mov", "b,...") with MOVB(...),
414           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
415           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
416         * src/mcs51/peeph.def: added rules 140 and 264
417         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
418           so they may get optimized into registers
419
420 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
421
422         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
423           immediately when encountered,
424           (printUsage): always use stderr even on windows
425
426 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
427
428         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
429         (processParms): fixed bug #1247551
430         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
431         parseCmdLine, main): print '--version' to stdout,
432         print 'help' to stdout if --help is given,
433         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
434         arguments are given; fixed --help
435
436 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
437
438         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
439         * support/regression/tests/bug-1493710.c: added
440
441 2006-05-27 Borut Razem <borut.razem AT siol.net>
442
443         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
444           static instead auto
445         * support/regression/ports/pic16/support.c: increase stack size
446           from default 64 bytes to 128 bytes
447         * support/regression/tests/staticinit.c,
448           support/regression/tests/float.c: regression tests fully enabled
449           for pic16 port by putting the initialized data arrays into the code
450           section
451         * support/regression/ports/pic16/spec.mk: don't link default libraries.
452           This was changed by mistake in the previous version.
453
454 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
455
456         * src/pic16/gen.c (genFunction, genEndFunction): some
457         beautifications, fixed bug with falsely restoring FSR2 in large
458         stack model, thanks to Beau E. Cox for reporting the bug
459
460 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
461
462         * debugger/mcs51/break.c,
463         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
464           use %p to print pointers, made address variables unsigned
465         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
466         * debugger/mcs51/symtab.c (parseSymbol): must return something
467         * src/mcs51/gen.c (aopForSym): small optimization,
468            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
469           (freeAsmop): added missing break,
470           (aopPut): removed parameter bvolatile, determine it inside the function,
471           (saveRegisters, unsaveRegisters): small optimization,
472           (genIpush): removed pointless check,
473           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
474           replaced sprintf with SNPRINTF,
475           replaced strcpy with strncpyz,
476           updated aopPut calls,
477           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
478         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
479
480 2006-05-24 Borut Razem <borut.razem AT siol.net>
481
482         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
483           modification of test for the pic16 port, put the array to the code
484           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
485
486 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
487
488         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
489         * support/Util/pstdint.h: added
490
491 2006-05-22 Borut Razem <borut.razem AT siol.net>
492
493         * src/regression/Makefile: removed bool2.c test, added -q linker option
494         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
495           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
496           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
497           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
498           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
499           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
500           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
501           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
502           define SUPPORT_BIT_TYPES 0, removed unused bit variables
503
504 2006-05-22 Raphael Neider <rneider AT web.de>
505
506         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
507           bug #1492360 (problematic due to generic pointers, see code)
508
509 2006-05-22 Borut Razem <borut.razem AT siol.net>
510
511         * support/regression/ports/pic16/specs.mk: removed stack size linker
512           directive
513         * support/regression/tests/array.c,
514           support/regression/tests/bitopcse.c,
515           support/regression/tests/bug-908454.c,
516           support/regression/tests/malloc.c: modified for pic16 regression test
517         * support/regression/tests/bitfields.c:
518           pic16 - excluded bitfileds of size > 8
519         * support/regression/tests/bp.c: pic16 - reduced data size
520         * support/regression/tests/bug-221100.c: pic16 - reduced data size
521         * support/regression/tests/bug-460010.c:
522           pic16 - used the absolute address the fits in memory
523         * support/regression/tests/bug-716242.c:
524           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
525         * support/regression/tests/float.c:
526           pic16 - excluded - data size too big
527         * support/regression/tests/onebyte.c:
528           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
529         * support/regression/tests/shifts.c:
530           pic16 - function names probably have to differ in first X characters
531           (gpasm limitation?)
532         * support/regression/tests/staticinit.c:
533           pic16 - excluded some tests due error: no target memory available for
534           section ".idata"
535
536 2006-05-22 Borut Razem <borut.razem AT siol.net>
537
538         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
539           second try. Thanks Stas Sergeev once more.
540
541 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
542
543         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
544           (genLeftShift, genRightShift): fixed bug 1491627
545         * src/hc08/peeph.def (rules 7, 8.x): added
546         * support/regression/tests/shifts.c (ShiftLeftByParam,
547           ShiftRightByParam, testShiftByParam): added to test variable shifting
548
549 2006-05-20 Raphael Neider <rneider AT web.de>
550
551         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
552         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
553           (allocReg): add only new registers to dynAllocRegs,
554           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
555             #1489055, #1445850, and probably #1483693
556
557 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
558
559         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
560         bug in for-loop that didn't emit the last of CONFIG and ID registers
561
562 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
563
564         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
565           with offset
566         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
567           1489016, 1434401 and 1490124
568         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
569           1489016, 1434401 and 1490124
570
571 2006-05-17 Borut Razem <borut.razem AT siol.net>
572
573         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
574           thanks Stas Sergeev
575
576 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
577
578         * device/include/mcs51/P89c51RD2.h,
579         * device/include/mcs51/P89LPC901.h,
580         * device/include/mcs51/P89LPC922.h,
581         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
582
583 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
584
585         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
586         to fix missing stack pragma in compiled binary object file,
587
588 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
589
590         * support/packihx/configure.in,
591         * support/packihx/configure: removed warning, autoconf >= 2.5x can
592         determine sizeof basic types even while cross compiling
593
594 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
595
596         * src/avr/gen.c (aopop),
597         * src/ds390/gen.c (aopOp),
598         * src/hc08/gen.c (aopOp),
599         * src/mcs51/gen.c (aopop),
600         * src/pic16/gen.c (pic16_aopOp),
601         * src/pic/gen.c (aopOp),
602         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
603         if size of operand is smaller than spill location
604
605 2006-05-12 Borut Razem <borut.razem AT siol.net>
606
607         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
608           have to have CR/LF line endings even if they are checked out on *nix
609           or on WIN32 in cygwin binmode
610
611 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
612
613         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
614         * device/include/ds80c390.h: added sfr16 definitions
615         * src/ds390/gen.c,
616         * src/ds390/gen.h,
617         * src/ds390/main.c,
618         * src/ds390/ralloc.c,
619         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
620           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
621           bit returning functions
622         * support/regression/tests/sfr16.c: enabled test on ds390
623
624 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
625
626         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
627         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
628
629 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
630
631         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
632         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
633           (cl_address_space constructor): removed expensive initialization,
634           (cl_address_space::get_cell): extended for late initialization,
635           (cl_address_space::*): use late initialization,
636           (cl_address_decoder::activate): removed expensive initialization,
637           This reduced regression test running time by 25%
638
639 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
640
641         * packihx/,
642         * configure.in,
643         * configure,
644         * sdcc.dsw,
645         * Makefile.bcc,
646         * Makefile.in,
647         * support/packihx/Makefile.in,
648         * support/packihx/clean.mk,
649         * support/packihx/Makefile.bcc,
650         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
651
652 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
653
654         * src/SDCCval.c (valNot): fix for regression test failure
655           of not.c on big endian hosts
656
657 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
658
659         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
660
661 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
662
663         * device/lib/mcs51/Makefile.in: changed string comparison operator
664           to = for POSIX compliance; == is bash extension
665
666 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
667
668         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
669           kosmonaut_pirx
670
671 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
672
673         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
674         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
675         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
676         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
677         bug report #1478657,
678
679 2006-05-05 Borut Razem <borut.razem AT siol.net>
680
681         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
682           making the html
683
684 2006-05-02 Borut Razem <borut.razem AT siol.net>
685
686         * doc/Makefile.in: removed *.ind dependency since there is no rule to
687           create *.ind, which made make to fail if invoked with -j 2
688
689 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
690
691         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
692           Hubert Sack for patch 1479782
693
694 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
695
696         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
697
698 2006-05-01 Raphael Neider <rneider AT web.de>
699
700         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
701           (create_pic): store only prefix-free device name,
702           (init_pic): check for device names with "16" prefix,
703           (list_valid_pics),
704         * src/pic/device.h (struct PIC_device),
705         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
706             stored device name,
707         * device/include/pic/pic12f{635,675,629,683}.h,
708         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
709         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
710         * device/include/pic/pic16f505.h,
711         * device/lib/pic/libdev/pic16f505.c: removed
712         * device/include/pic/pic14devices.txt: added support for pic12f
713             devices, removed unsupported non 16-bit devices
714             [above changes provided by patch from Zik Saleeba]
715         * src/pic/*, src/pic16/*, device/include/pic16/*,
716           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
717
718 2006-05-01 Borut Razem <borut.razem AT siol.net>
719
720         * configure.in, configure, doc/Makefile.in:
721           sync with nightly build makefile - latex, dvipdf and dvips
722           not needed any more
723
724 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
725
726         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
727         in the library source
728
729 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
730
731         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
732
733 2006-04-28 Raphael Neider <rneider AT web.de>
734
735         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
736         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
737           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
738         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
739
740 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
741
742         * device/lib/pic/libdev/Makefile.in,
743         * device/lib/hc08/Makefile.in,
744         * device/lib/gbz80/Makefile.in,
745         * device/lib/z80/Makefile.in,
746         * device/lib/ds390/Makefile.in,
747         * device/lib/ds400/Makefile.in: added srcdir to include search path,
748         thanks to Borut for the bug report
749         * configure.in,
750         * configure: always create doc/Makefile independent from --enable-doc
751         * Makefile.in: always install from directory doc independent from
752         --enable-doc
753         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
754         removed
755         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
756         * doc/Makefile.in: install *.txt if present
757         * device/include/Makefile.in (install): added installation of pic/*.inc
758         and pic/*.txt files again, they were erroneously removed
759
760 2006-04-28 Raphael Neider <rneider AT web.de>
761
762         * src/pic/{gen.c,main.h,pcode.c},
763         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
764             concerning signedness with casts
765
766 2006-04-28 Raphael Neider <rneider AT web.de>
767
768         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
769             definition of an interrupt handler,
770         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
771             interrupt handler stuff from picglue() to separate routine,
772           (picglue): enabled definition of intr handlers in files w/o main()
773
774 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
775
776         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
777           compilation with MSVC 2005 Express Edition (VC8)
778
779 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
780
781         * device/lib/Makefile: fixed build of gbz80 lib
782
783 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
784
785         * support/regression/tests/bug-460010.c,
786         * support/regression/tests/bug-524691.c,
787         * support/regression/tests/bug-716242.c: removed conditional defines
788           that are already in testfwk.h
789
790 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
791
792         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
793           (AccAXRsh1): added, shift right by 1,
794           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
795            AccAXLrl1
796         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
797
798 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
799
800         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
801         remove cast to same type
802         * src/SDCCast.c (decorateType): fix for RFE 1475742,
803         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
804         * as/z80/Makefile,
805         * link/z80/Makefile: removed, they have moved to
806         Makefile.in files
807         * configure,
808         * configure.in: replaced duplicate message about ucsim by missing sdcpp
809         * install-sh: fix bug #1204398 by setting umask 0022
810         * device/lib/Makefile: separate build of z80 and gbz80 lib
811
812 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
813
814         Enabled VPATH feature: changed nearly all Makefiles (149 files).
815         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
816
817         One basic decision: e.g. src/clean.mk includes further files. In order
818         to make this work there are two solutions:
819         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
820           run configure on them. This way they can use
821           'include $(srcdir)/port-clean.mk'
822         - always include clean.mk by the Makefile at the same level. To avoid
823           that `make clean` tries to include and build Makefile.dep the
824           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
825           implemented, because now even `make uninstall` doesn't create
826           Makefile.in. clean.mk could be eliminated by pasting it in
827           Makefile.in.
828
829         * debugger/mcs51/Makefile.in: build own objects from library sources
830         (SLIB, SDCC) in current directory
831
832         * configure, configure.in: renamed --disable-device-lib-build in
833         --disable-device-lib; added --enable-doc, the required tools are
834         searched by configure; added result message; the toolchain for the
835         belonging ports are now only built, if the port is enabled.
836
837         * support/regression/*: all output is written in directory gen, because
838         the fwk and ports directories don't livet in the build tree using vpath
839
840         * doc/sdccman.lyx: renamed --disable-device-lib-build to
841         --disable-device-lib, added --enable-doc, added section VPATH
842
843         * sim/ucsim/configure.in,
844         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
845         z80 are enabled by default
846
847 2006-04-24 Raphael Neider <rneider AT web.de>
848
849         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
850             to config word, "pic14_"-prefixed some extern functions
851           (pic14_emitConfigWord): emit __config directive(s) if assignment to
852             config word has been found
853         * src/pic/device.h: added prototypes
854         * src/pic/pcode.c: added "pic14_"-prefix where needed
855         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
856             fixup
857         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
858             words,
859           (pic14emitRegularMap): ignore config words,
860           (pic14createInterruptVect): moved generating __config directives away
861           (picglue): have __config directives emitted
862
863 2006-04-24 Borut Razem <borut.razem AT siol.net>
864
865         * doc/Makefile: sync with nightly build makefile
866
867 2006-04-24 Raphael Neider <rneider AT web.de>
868
869         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
870             registers that have not been assigned proper liveranges,
871             fixes #1469504 and #1474602,
872           (pCodeRegOptimizeRegUsage): fixed typo in comment
873
874 2006-04-24 Borut Razem <borut.razem AT siol.net>
875
876         * device/examples/main8051.c: deleted - it was removed from CVS
877           24.mar.2000 and after that modified 18.feb.2001, so it reappered
878           after the transition to Subversion
879         * src/SDCCalloc.h: deleted - it was removed  from CVS
880           3.feb.2001 and after that modified 18.feb.2001, so it reappered
881           after the transition to Subversion
882         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
883           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
884           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
885           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
886
887 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
888
889         * as/asx8051.dsp: added mcs51/strcmpi.h
890         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
891         * as/hc08/aslink.h: updated lnksect prototype
892         * as/hc08/asm.h,
893         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
894         * as/hc08/asmain.c,
895         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
896           (newdot): handle A_ABS
897         * as/hc08/asout.c,
898         * as/mcs51/asout.c (outarea): output address
899         * as/hc08/lkaomf51.c,
900         * as/mcs51/lkaomf51.c: disabled unused array UsageType
901         * as/hc08/m08pst.c,
902         * as/mcs51/i51pst.c,
903         * as/z80/z80pst.c: "ABS" is not A_OVR
904         * as/hc08/lkarea.c (newarea): read a_addr,
905           (lnkarea): added codemap array, sort absolute areas to the front,
906            combine all GSINITx/GSFINAL,
907           (find_empty_space, allocate_space): new functions,
908           (lnksect): return next address, handle absolute sections
909         * as/mcs51/lkarea.c (newarea): read a_addr,
910           lnksect2 prototype changed,
911           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
912           (find_empty_space, allocate_space): new, factored out of lnksect2,
913           (lnksect2): return next address, handle absolute sections
914         * as/hc08/lkhead.c,
915         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
916         * as/hc08/lklibr.c (addfile, fndsym),
917         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
918           index out of range and detect both '\' and '/'
919         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
920         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
921           regression tests (ds390 cannot return bool yet)
922         * doc/sdccman.lyx: changed version number, document changed --no-peep,
923           document critical interrupts on z80, document changed SDCC define
924         * src/asm.c (_asxxxx_mapping): fixed .org directive,
925           (_a390_mapping): added .org directive
926         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
927           (genMultOneByte): fixed warnings
928         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
929           ones
930         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
931         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
932           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
933         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
934         * src/pic16/main.c: removed newReg prototype
935         * src/pic16/pcode.c,
936         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
937           warnings
938         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
939           ones
940         * src/pic16/ralloc.c
941         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
942           to fix warnings
943         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
944           from short to PIC_OPTYPE
945         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
946         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
947           optype from short to PIC_OPTYPE
948         * src/port.h: made int_size unsigned to fix warnings
949         * src/SDCC.y: fixed warning on MSVC
950         * src/SDCCicode.c (getArraySizePtr): return unsigned int
951         * src/SDCCopt.c (convertToFcall): fixed warnings
952         * src/SDCCsymt.h: removed double prototype for genSymName
953         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
954           offset int to fix warnings
955
956 2006-04-22 Borut Razem <borut.razem AT siol.net>
957
958         * doc/sdccman.lyx, */Makefile, */Makefile.in:
959           references to CVS replaced with Subversion
960
961 2006-04-21 Borut Razem <borut.razem AT siol.net>
962
963         * doc/sdccman.lyx, */Makefile, */Makefile.in:
964           references to CVS replaced with Subversion
965
966 2006-04-19 Borut Razem <borut.razem AT siol.net>
967
968         * src/version.awk: adapted for svn
969         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
970           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
971           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
972           /binutils-avr/etc/*.vi, *.jin: removed all properties
973           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
974
975 2006-04-19 Borut Razem <borut.razem AT siol.net>
976
977         * CVS to Subversion migration completed
978
979 2006-04-18 Borut Razem <borut.razem AT siol.net>
980
981         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
982           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
983
984 2006-04-17 Borut Razem <borut.razem AT siol.net>
985
986         * device/include/Makefile.in: added pic/*.inc to the installation
987
988 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
989
990         * support/regression/collate-results.py: fixed output in case of
991         a valdiag error
992         * support/regression/generate-cases.py: fixed splitting of pathnames
993         with dots
994         * as/hc08/lklibr.c (addfile),
995         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
996
997 2006-04-11 Raphael Neider <rneider AT web.de>
998
999         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
1000         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
1001         * src/pic16/pcode.c (assignValnums): fixed #1460578
1002
1003 2006-04-11 Raphael Neider <rneider AT web.de>
1004
1005         * device/lib/pic/libdev/*.c,
1006         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
1007           fixes #1468739, enables compilation in --std-c99 mode
1008         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
1009
1010 2006-04-11 Raphael Neider <rneider AT web.de>
1011
1012         * src/pic/device.c (find_device): removed debug output
1013           (list_valid_pics): enabled verbose listing of supported devices
1014         * device/include/stdbool.h: define bool as char for pic14/16 as well
1015
1016 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1017
1018         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
1019
1020 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1021
1022         * .version: bumped version to 2.5.6
1023         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
1024
1025 2006-04-06 Raphael Neider <rneider AT web.de>
1026
1027         * .version: bumped version to 2.5.6 (pic14 ABI changed)
1028         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
1029         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
1030           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
1031             pic14_constructAbsMap
1032           (pic14printPublics): declare absolute global symbols as global
1033           (pic14createInterruptVect),
1034         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
1035           (newReg): assume new registers unused, use correct name in
1036             hashtable (reg->name instead of name), more debugLog output
1037         * src/pic/device.h (PIC_device): added fields for verbose output
1038         * src/pic/device.c: moved device definition to pic14devices.txt,
1039             added routines for runtime parsing of pic14devices.txt,
1040             added support for second config word
1041         * src/pic/main.c (_process_pragma): removed #pragma maxram,
1042           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
1043           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
1044           (_pic14_parseOptions): moved pCodeInitRegisters here
1045           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
1046         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
1047           (pCodeInitRegisters): rewrapped comments, perpared new approach to
1048             handling the pseudo stack
1049         * device/lib/Makefile.in: ignore failures in objects-pic16,
1050         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
1051         * device/lib/pic/NEWS: document new dependency on picXXX.lib
1052         * device/lib/pic/Makefile.subdir,
1053         * device/lib/pic16/Makefile.subdir: improved clean rules
1054         * device/lib/pic/libdev/: NEW, pic14 device libraries
1055         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
1056         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
1057         * device/include/Makefile.in: create subdir and install pic14 headers
1058         * device/include/pic/p16f_common.inc: removed unused declarations
1059         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
1060             PICs from inc2h.pl v1.6,
1061             replaced BIT_AT macros with struct declarations
1062         * device/include/pic/pic14devices.txt: definition of supported devices,
1063             all above improvements contributed by Zik Saleeba, thanks
1064         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
1065         * support/scripts/sdcc.nsi: also install pic14 device libraries and
1066             headers
1067
1068 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1069
1070         * device/include/mcs51/c8051f410.h: added interrupt numbers,
1071         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
1072           thanks to Charles Olds
1073
1074 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1075
1076         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
1077
1078 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1079
1080         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
1081         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
1082         * support/regression/bug1464657.c: added, new test
1083
1084 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1085
1086         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
1087           version number
1088
1089 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1090
1091         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
1092           --no-peep and --peep-file <file> are used don't use default rules but
1093           do use the <file>
1094
1095 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1096
1097         * src/mcs51/gen.c (genCall): fixed bug 1457608
1098
1099 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1100
1101         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
1102         changes seem to cause (trigger?) problems with the build system.
1103
1104 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
1105
1106         * src/SDCCpeeph.c (operandsLiteral): new, added,
1107           (callFuncByName): inserted operandsLiteral
1108         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
1109
1110 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1111
1112         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
1113         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
1114
1115 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1116
1117         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
1118           implemented patch 1120823 Thanks to Willy De la Court (normal
1119           interrupts need an interrupt number now if they are made critical),
1120           and enabled nesting of critical functions though not for gbz80
1121           (genCritical, genEndCritical): added functions
1122           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
1123         * src/z80/mappings.i: added "ei" to all mappings
1124
1125 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1126
1127         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
1128         submitted by the Debian SDCC maintainer Aurelien Jarno:
1129         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
1130         archive with gcc 4.1 on mips and wrote the patch"
1131
1132 2006-03-16 Raphael Neider <rneider AT web.de>
1133
1134         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
1135           the left operand is shorter than the result (c* = lit-c* + int),
1136           fixes bug #1450796
1137         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
1138           OP_SYMBOL
1139
1140 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
1141
1142         * src/.version: increased version number to 2.5.5
1143         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
1144         linking is done manually in pic16 port's _linkEdit,
1145         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
1146         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
1147         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
1148         allocate asmop as AOP_ACC,
1149         (aopForRemat): added parameter 'bool result' in function declaration,
1150         (pic16_aopGet): return AOP_ACC when accessing WREG,
1151         (pic16_popGetTempReg): minor modification,
1152         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
1153         'pic16_allocWithIdx',
1154         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
1155         calling function in absolute addresses,
1156         (genAssign): take into account AOP_ACC asmop,
1157         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
1158         * src/pic16/pcoderegs.c: some debug functions and lines added,
1159         * src/pic16/ralloc.c (decodeRegType): added but commented out,
1160         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
1161         register too,
1162         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
1163         call to allocReg, not by manually allocating a new one,
1164         (pic16_assignRegisters): now before going through the register
1165         allocating functions mark all registers as free. This eliminates some
1166         side effects resulting from peephole parser done earlier in the backbone
1167
1168 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
1169
1170         * src/SDCCicode.c (geniCodeLogic),
1171         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
1172
1173 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
1174
1175         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
1176           (genSend): bugfix, do not allocate and free twice,
1177           (shiftRLong): handle partially overlapping aops
1178         * support/regression/tests/bitopcse.c: fixed warning redefined idata
1179
1180 2006-03-08 Borut Razem <borut.razem AT siol.net>
1181
1182         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
1183           for pic16
1184
1185 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
1186
1187         * support/regression/tests/bug1409955.c: new, added
1188         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
1189         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
1190           (aopForSym, aopOp): increment asmop.allocated if reused,
1191           (freeAsmop): decrement asmop.allocated and check for zero instead of
1192           using asmop.freed,
1193           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
1194           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
1195            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
1196            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
1197            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
1198            genSignedRightShift, genRightShift, genDataPointerGet,
1199            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
1200            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
1201             in reverse order from allocation,
1202           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
1203             added swappedLR to keep track
1204         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
1205           pdata & code for GCC, z80, gbz80 & hc08
1206         * support/regression/tests/zeropad.c: moved defines to testfwk.h
1207
1208 2006-03-08 Raphael Neider <rneider AT web.de>
1209
1210         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
1211
1212 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
1213
1214         * device/include/mcs51/c8051f410.h: new SiLabs mcu
1215         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
1216         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
1217
1218 2006-03-06 Borut Razem <borut.razem AT siol.net>
1219
1220         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
1221           made the linker quiet
1222
1223 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
1224
1225         * src/pic16/gen.c (genPcall): fixed bug #1443644
1226         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
1227         which dumps before the function entry point a data byte which represents
1228         the number of the local variables used by the specified function, added
1229         'xinst' for initial support for Extended Instruction Support,
1230         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
1231         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
1232         port->fun_prefix anymore (may change later),
1233         (genFunction, genEndFunction): do not store/restore local registers for
1234         _main (this should take care the --main-return command line option in
1235         the future),
1236         (genOr): removed some legacy pic-port instructions,
1237         * src/pic16/genarith.c (genAddLit): re-enabled old code because
1238         performing operations with SFR's causes data to be written more than
1239         once to each SFR. Perhaps SFRs should be handled in special cases...
1240         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
1241         pcode.h
1242         * src/pic16/main.c (_process_pragma): stack bound checking did not take
1243         into account for stack starting position,
1244         (struct OPTIONS pic16_optionsTable): added command line argument
1245         --extended or -y for Extended Instruction Support,
1246         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
1247         (deassignLRs): *** perhaps the most important change, old 'for' code
1248         (commented out for reference), didn't account for some registers which
1249         were left marked 'not free' after a pointer operation. The change
1250         reduces register usage a lot in some cases
1251
1252 2006-03-04 Borut Razem <borut.razem AT siol.net>
1253
1254         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
1255           _clean
1256         * support/regression/tests/bug-524697.c: decreased array size for
1257           mcs51 to fit into the internal RAM
1258         * support/regression/Makefile.in: a little bit more verbose
1259
1260 2006-03-03 Borut Razem <borut.razem AT siol.net>
1261
1262         * support/regression/fwk/lib/testfwk.c,
1263           support/regression/fwk/include/testfwk.h: introduced function
1264           _prints(), nonrecursive _printn(), call _initEmu() from main()
1265         * support/regression/ports/gbz80/support.asm,
1266           support/regression/ports/ucz80/support.asm,
1267           support/regression/ports/z80/support.asm,
1268           support/regression/ports/ds390/support.c,
1269           support/regression/ports/hc08/support.c,
1270           support/regression/ports/host/support.c,
1271           support/regression/ports/mcs51/support.c,
1272           support/regression/ports/xa51/support.c: added empty _initEmu()
1273           function
1274         * support/regression/ports/pic16/gpsim.cmd,
1275           support/regression/ports/pic16/spec.mk,
1276           support/regression/ports/pic16/support.c,
1277           support/regression/Makefile.in: added pic16 regression test
1278
1279 2006-03-01 Raphael Neider <rneider AT web.de>
1280
1281         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
1282           genConstPointerGet): use safe way of generating MOVFF to cover
1283             literals as well as registers, fixes bug #1440527
1284         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
1285             dereference
1286           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
1287             more correctly, fixes bug #1232186
1288           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
1289         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
1290             gplink guess the correct processor in more cases, applied patch
1291             from Till Riedel attached to and fixing bug #1436552
1292
1293 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1294
1295         * support/regression/tests/array.c: added, contains check for #1434401
1296         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
1297
1298 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
1299
1300         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
1301         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
1302         * device/include/mcs51/c8051f326.h,
1303         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
1304         * device/include/mcs51/c8051f000.h,
1305         * device/include/mcs51/c8051f018.h,
1306         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
1307           PCON_IDLE,PCON_STOP and added sfr16 definitions
1308
1309 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1310
1311         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
1312           genGetWord): fixed bug 1409955
1313
1314 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1315
1316         * device/include/hc08/mc68hc908gp32.h,
1317         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
1318
1319 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
1320
1321         * src/SDCCast.c (constExprValue): return NULL if not a value
1322         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
1323         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
1324         * support/regression/tests/bitfields.c: enabled signed bitfield for all
1325
1326 2006-02-13 Borut Razem <borut.razem AT siol.net>
1327
1328         * src/regression/ptrarg.c: added, fails due to bug #1430967
1329         * src/regression/Makefile: ptrarg.c added, ...
1330
1331 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1332
1333         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
1334         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
1335
1336 2006-02-11 Borut Razem <borut.razem AT siol.net>
1337
1338         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
1339           print "Processor: xxx" message to stdout only if --verbose
1340
1341 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1342
1343         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
1344         * support/regression/tests/bug1426356.c: added
1345         * support/regression/tests/bitfields.c: removed 2 tests
1346
1347 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
1348
1349         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
1350         * device/include/mcs51/c8051f330.h,
1351         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
1352           PCON_IDLE,PCON_STOP and added sfr16 definitions
1353         * device/lib/_divsint.c,
1354         * device/lib/_divuint.c,
1355         * device/lib/_divulong.c,
1356         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
1357           register bank bug for small stackauto
1358
1359 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
1360
1361         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
1362
1363 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
1364
1365         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
1366         * all.dsp: corrected several bin paths
1367         * device/include/mcs51/c8051f120.h,
1368         * device/include/mcs51/c8051f300.h,
1369         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
1370           to PCON_IDLE,PCON_STOP
1371         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
1372         * device/lib/printf_large.c (output_float): fixed bug 1388703
1373         * support/regression/tests/bug1057979.c: added test for bug 1388703
1374
1375 2006-02-08 Raphael Neider <rneider AT web.de>
1376
1377         * src/pic/pcode.c (pciTRIS): fixed typo,
1378           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
1379           (LinkFlow): fixed handling of flows that end in a call,
1380           (ReuseReg): perform safety check earlier
1381         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
1382             to work with flows at the beginning of a pBlock,
1383             fixes #1426557 (Symbol not previously defined),
1384           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
1385             usage information
1386           (RemoveUnusedRegisters): update register usage info
1387         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
1388             created, reuse existing ones instead
1389         * src/pic/gen.c (genPcall): fixed #1424719
1390
1391 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
1392
1393         * link/z80/lkmain.c,
1394         * link/z80/lklex.c,
1395         * link/z80/lkdata.c,
1396         * link/z80/aslink.h: fixed build on current cygwin:
1397         replaced getline() by lk_getline()
1398
1399 2006-02-01 Borut Razem <borut.razem AT siol.net>
1400
1401         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
1402           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
1403           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
1404           src/regression/bool1.c, src/regression/bool2.c,
1405           src/regression/bool3.c, src/regression/call1.c,
1406           src/regression/compare.c, src/regression/compare10.c,
1407           src/regression/compare2.c, src/regression/compare3.c,
1408           src/regression/compare4.c, src/regression/compare5.c,
1409           src/regression/compare6.c, src/regression/compare7.c,
1410           src/regression/compare8.c, src/regression/compare9.c,
1411           src/regression/configword.c, src/regression/for.c,
1412           src/regression/inline.c, src/regression/mult1.c,
1413           src/regression/nestfor.c, src/regression/or1.c,
1414           src/regression/pointer1.c, src/regression/ptrfunc.c,
1415           src/regression/rotate1.c, src/regression/rotate2.c,
1416           src/regression/rotate3.c, src/regression/rotate4.c,
1417           src/regression/rotate5.c, src/regression/rotate6.c,
1418           src/regression/rotate7.c, src/regression/string1.c,
1419           src/regression/struct1.c, src/regression/sub.c,
1420           src/regression/sub2.c, src/regression/switch1.c,
1421           src/regression/while.c, src/regression/xor.c,
1422           src/regression/create_stc, src/regression/simulate,
1423           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1424           regression tests
1425         * src/regression/gpsim_assert.h: added
1426
1427 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1428
1429         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1430         ((void (code *) (void)) 0) ();
1431         * as/hc08/aslex.c,
1432         * as/hc08/aslink.h,
1433         * as/hc08/asm.h,
1434         * as/hc08/asmain.c,
1435         * as/hc08/lkdata.c,
1436         * as/hc08/lklex.c,
1437         * as/hc08/lkmain.c,
1438         * as/mcs51/aslex.c,
1439         * as/mcs51/aslink.h,
1440         * as/mcs51/asm.h,
1441         * as/mcs51/asmain.c,
1442         * as/mcs51/lkdata.c,
1443         * as/mcs51/lklex.c,
1444         * as/mcs51/lkmain.c,
1445         * as/z80/aslex.c,
1446         * as/z80/asm.h,
1447         * as/z80/asmain.c: fixed build on current cygwin:
1448         replaced getline() by as_getline()
1449
1450 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1451
1452         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1453         declarator in the symbol chain
1454         * src/SDCCsymt.h,
1455         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1456         parameter list for function pointers
1457         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1458         * support/regression/tests/bug-716242.c: added
1459
1460 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1461
1462         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1463         offset if possible
1464         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1465
1466 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1467
1468         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1469         inifinitely recurseable, added static
1470         * support/regression/tests/bug-1408066.c: added
1471
1472 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1473
1474         * src/SDCCicode.h,
1475         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1476         renamed, added possibility to create "postLoopLbl"-labels
1477         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1478         newiTempLoopHeaderLabel
1479         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1480         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1481         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1482         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1483         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1484         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1485         (basicInduction): fixed bug #136564, made static,
1486         (loopInduction): changed parameter of basicInduction, made static,
1487         (addPostLoopBlock): added
1488         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1489         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1490         findLoopEndSeq
1491         * support/regression/tests/bug-136564.c: added
1492         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1493         --std-sdcc99 to LIBSDCCFLAGS
1494
1495 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1496
1497         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1498         while loop
1499         * support/regression/tests/bug-1406131.c: added
1500
1501 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1502
1503         * src/SDCCast.c (decorateType): fix promotion of unary minus
1504         * src/SDCCsymt.c (computeType): beautified
1505         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1506         (valUnaryPM, valComplement): fix sign and promotion,
1507         (valNot): ANSI: result type is int (SDCC: unsigned char)
1508         * support/regression/tests/uminus.c: speedup by removing superflous
1509         test case 'int'
1510         * support/regression/tests/onebyte.c: added promotion and signedness
1511         tests for unary minus
1512         * support/regressions/tests/bug-477927.c: disable warning about
1513         uninitialized variables
1514         * support/regression/tests/not.c: added
1515
1516 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1517
1518         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1519         * src/mcs51/gen.c (gen51Code): show final register usage after
1520         fillGaps in asm with --i-code-in-asm
1521         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1522         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1523         incUsed, rliveClear, adjustIChain): made static,
1524         (setFromRange): excluded because it's unused,
1525         (findPrevUseSym, markWholeLoop): added,
1526         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1527         through all branches of predecessors enables sdcc to emit the warning
1528         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1529         (rlivePoint): made static, added parameter emitWarnings which is only
1530         true during the first run out of two,
1531         (findRecursiveSucc, findRecursivePred): removed,
1532         (computeLiveRanges): made static, added parameter emitWarnings,
1533         (dumpIcRlive): added for debugging only
1534         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1535         removed prototype of setFromRange()
1536         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1537         in call of computeLiveRanges()
1538         * support/regression/tests/bug-895992.c: added
1539         * support/regression/tests/bug-971834.c: added
1540         * support/valdiag/tests/bug-895992.c: added
1541         * support/valdiag/tests/bug-971834.c: added
1542
1543 2005-12-18 Raphael Neider <rneider AT web.de>
1544
1545         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1546           (genUnpackBits): improved code for direct operands,
1547           (genPackBits): improved code for literal assignment to bitfields
1548             and for direct destination operands (no FSR indirection),
1549             prevented redundant AND, fixes #1362800,
1550           (AccLsh): added parameter to disable masking of the result
1551         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1552           skip instructions with side-effects (like incfsz),
1553           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1554         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1555         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1556           fixes #1375263
1557
1558 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1559
1560         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1561         volatile variables as spill location
1562
1563 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1564
1565         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1566         replacing literals
1567         * support/regression/tests/bug-1376320.c: added
1568
1569 2005-12-08 Raphael Neider <rneider AT web.de>
1570
1571         * src/pic/device.c: renamed is_shared to pic14_is_shared
1572         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1573         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1574           (is_valid_identifier): added for above workaround
1575
1576 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1577
1578         * device/lib/Makefile.in: fixed to enable port-specific-objects
1579         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1580           char, thanks Hubert Sack
1581         * doc/sdccman.lyx: documented --xstack-loc,
1582           elaborated a bit more on interrupts and pitfalls,
1583           removed "setjmp/longjmp unsupported",
1584           documented some unsupported C99 features
1585         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1586         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1587           if, thanks Hubert Sack
1588         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1589         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1590           make make_library
1591         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1592           regression tests can report resource usage (rfe 700441)
1593         * support/regression/collate-results.py: report resource usage
1594         * support/regression/ports/ds390/spec.mk,
1595         * support/regression/ports/hc08/spec.mk,
1596         * support/regression/ports/mcs51/spec.mk,
1597         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1598         * support/regression/ports/ds390/uCsim.cmd,
1599         * support/regression/ports/hc08/uCsim.cmd,
1600         * support/regression/ports/mcs51/uCsim.cmd,
1601         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1602         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1603           library, use the default one
1604         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1605           building the library
1606
1607 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1608
1609         * config.dsp: added dependency on .version and configure_vc.awk
1610         * device/include/setjmp.h: updated for --stack-auto and --xstack
1611         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1612         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1613         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1614         * device/lib/libsdcc.lib: added _setjmp
1615         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1616           (decorateType): fixed bug 1372851,
1617           (optimizeGetHbit): fixed warning
1618         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1619           array initialisation
1620         * support/regression/tests/bug1057979.c: added test for bug 1358192
1621         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1622
1623 2005-12-03 Borut Razem <borut.razem AT siol.net>
1624
1625         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1626           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1627
1628 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1629
1630         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1631         createIval): implement symbol independant "flexible array member",
1632         (createIvalCharPtr): implemented flexible array initialisation with a
1633         string
1634         * src/SDCCsymt.c (copyStruct): removed,
1635         (getSize): fixed misleading comment,
1636         (getAllocSize): removed, the additional allocation size is now in
1637         sym->flexArrayLength,
1638         (checkStructFlexArray): new, syntax checks for flexible array members,
1639         (compStructSize): added syntax checks for "flexible array members"
1640         (copyStruct): removed,
1641         (copyLinkChain): removed inefficient fix for bug 770487
1642         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1643         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1644         symbol->flexArrayLength
1645         * src/SDCCerr.c,
1646         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1647         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1648         * support/regression/tests/structflexarray.c: added
1649         * support/valdiag/tests/structflexiblearray.c: added
1650
1651 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1652
1653         * src/SDCCast.c (decorateType): fixed bug 1368489
1654         * support/Util/SDCCerr.c,
1655         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1656
1657 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1658
1659         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1660           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1661
1662 2005-11-27 Borut Razem <borut.razem AT siol.net>
1663
1664         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1665           support/cpp2/mkdeps.h: added command line option
1666           -obj-ext=<extension> to SDCPP to define object file externion, used
1667           for generation of make dependencies (-M)
1668         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1669
1670 2005-11-26 Borut Razem <borut.razem AT siol.net>
1671
1672         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1673           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1674           added pic and pic16 libraries
1675
1676 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1677
1678         * device/include/float.h: Corrected typo in prototype of __fsgt
1679
1680 2005-11-25 Borut Razem <borut.razem AT siol.net>
1681
1682         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1683           added creation of model-mcs51-stack-auto libraries
1684
1685 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1686
1687         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1688         and fields-list too
1689         * src/SDCCast.c (createIvalArray): removed obsolete comment
1690
1691 2005-11-24 Borut Razem <borut.razem AT siol.net>
1692
1693         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1694           added missing device/lib/mcs51/crt*.asm sources
1695
1696 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1697
1698         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1699
1700 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1701
1702         * device/lib/_fs2schar.c,
1703         * device/lib/_fs2sint.c,
1704         * device/lib/_fs2slong.c: optimized inline asm
1705
1706 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1707
1708         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1709           Better handling of floats between -1.0 and 0.0.
1710
1711 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1712
1713         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1714           (the missing "if"s prohibited removal of redundant labels)
1715
1716 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1717
1718         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1719           Properly convert floats between -1.0 and 0.0 to long, int, and char
1720           types (max integer value of negative floats tends to zero).
1721         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1722           Removed changes made so to work properly with floats between
1723           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1724           and _fs2char.c
1725
1726 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1727
1728         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1729         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1730         (genCast) cosmetic change
1731         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1732         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1733         from mcs51
1734         * support/regression/tests/bitfields (testSignedBitfields): added
1735
1736 2005-11-18 Borut Razem <borut.razem AT siol.net>
1737
1738         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1739         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1740           introduced SILENT option to make building of pic16 libraries less
1741
1742 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1743
1744         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1745           Now they work properly with floats between -1.0 and 0.0
1746         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1747
1748 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1749
1750         * src/SDCCicode.c (printOperand): added missing else
1751
1752 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1753
1754         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1755         reformatted for better readability
1756         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1757         signed bitfields
1758
1759 2005-11-17 Borut Razem <borut.razem AT siol.net>
1760
1761         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1762           introduced SILENT option to make building of pic16 libraries less
1763           verbose - used for nightly snapshot build
1764         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1765           available on Win32 platforms.
1766         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1767           medium, large, pic and pic16
1768
1769 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1770
1771         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1772           printf("%f"...) sets fraction to zero.
1773
1774 2005-11-16 Raphael Neider <rneider AT web.de>
1775
1776         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1777           fixes #1357221
1778         * src/pic/gen.c (genIfx): implemented for CARRY bit
1779         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1780           to generic pointers, fixes #1357332,
1781           (pic16_movLit2f): NEW,
1782           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1783
1784 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1785
1786         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1787
1788 2005-11-11 Raphael Neider <rneider AT web.de>
1789
1790         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1791         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1792           compute pointer's type from operand,
1793           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1794           improved single bit reads, fixes bug #1353379
1795
1796 2005-11-09 Borut Razem <borut.razem AT siol.net>
1797
1798         * support/scripts/sdcc.nsi: added lib/pic to the package
1799
1800 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1801
1802         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1803
1804 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1805
1806         * support/regression/tests/bug1348008.c: added
1807         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1808         * support/regression/tests/bug1337835.c: updated comment
1809
1810 2005-11-06 Borut Razem <borut.razem AT siol.net>
1811
1812         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1813           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1814           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1815           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1816           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1817           dynamic construction of cl_error_class and derivates - 2.nd try
1818
1819 2005-11-05 Borut Razem <borut.razem AT siol.net>
1820
1821         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1822           bug, which caused Bus Errors on sparc solaris
1823
1824 2005-11-04 Borut Razem <borut.razem AT siol.net>
1825
1826         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1827           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1828           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1829           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1830           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1831           and derivates to resolve the initialization problem on OSX
1832
1833 2005-11-02 Borut Razem <borut.razem AT siol.net>
1834
1835         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1836           corrected typo - #include <winsock2.h>
1837
1838 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1839
1840         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1841           (_asxxxx_mapping): added org directive for future enhancements
1842
1843 2005-11-01 Borut Razem <borut.razem AT siol.net>
1844
1845         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1846           enabled sockets on WIN32
1847         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1848
1849 2005-10-31 Borut Razem <borut.razem AT siol.net>
1850
1851         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1852           WIN32 backslash path delimiters should be escaped when used in C strings
1853         * support/regression/tests/bitfields.c: exclude failing assertions for
1854           __CYGWIN32__ and __MINGW32__ hosts
1855
1856 2005-10-30 Borut Razem <borut.razem AT siol.net>
1857
1858         * src/SDCCutil.c: corrected double comparison typo
1859
1860 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1861
1862         * device/lib/medium/Makefile: added for new memory model medium
1863         * device/include/asm/mcs51/features.h: updated for medium/pdata
1864         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1865           added Multiply & Accumulate sbit's and MAC0_PAGE define
1866         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1867         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1868         * device/lib/_mullong.c: update for medium model
1869         * device/lib/incl.mk: added medium model
1870         * doc/sdccman.lyx: documented medium model
1871         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1872         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1873         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1874         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1875           (allocParms): set SCLS and OCLS to pdata for medium model
1876         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1877           for pdata,
1878           (powof2): return <0 if not power of 2
1879         * src/avr/gen.c (genBitWise): use updated powof2
1880         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1881           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1882           (shiftLLeftOrResult): use B if necessary
1883         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1884         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1885         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1886         * support/regression/Makefile.in: added test-mcs51-medium
1887         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1888
1889 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1890
1891         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1892         specifier unsigned
1893         * device/lib/time.c (mktime): fixed bug 1334315
1894
1895 2005-10-28 Raphael Neider <rneider AT web.de>
1896
1897         * device/include/pic/p16f_common.inc: added common declarations
1898         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1899
1900 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1901
1902         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1903           (aopPutUsesAcc): added to predict accumulator use,
1904           (assignResultValue): save acc if necessary,
1905           (genMinusDec): store result if indirectly addressed,
1906           (genDivOneByte):  save acc if necessary,
1907           (movLeft2Result): bugfix if left already in acc,
1908           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1909             attention to accumulator use (esp. pdata),
1910           (genReceive): receive pdata correctly
1911         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1912         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1913
1914 2005-10-27 Raphael Neider <rneider AT web.de>
1915
1916         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1917
1918 2005-10-27 Raphael Neider <rneider AT web.de>
1919
1920         * .version: changed version to 2.5.4
1921         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1922         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1923           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1924             arithmetics support routines
1925         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1926         * device/lib/Makefile.in: also create installdir for pic
1927
1928         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1929           pic14 port as well
1930         * src/pic/device.c (dump_sfr): rewritten to delegate register
1931           placement to the linker (use `extern sym' rather than sym EQU addr),
1932           (validAddress): fixed to check last specified address
1933         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1934           (popGetLit): truncate literal value to 8 bit,
1935           (popGet): moved assert to more appropriate place
1936           (popGetExternal): create pCode operand from and mark the according
1937             symbol as being `extern'
1938           (popGetAddr): added sanity check on immediate's offset, provide
1939             GPOINTER tag on demand
1940           (aopPut): fixed for immediates,
1941           (mov2w_op): move operand's address or contents to WREG (depending on
1942             operand type), safer variant of mov2w,
1943           (movwf,call_libraryfunc): NEW, handy abbreviations,
1944           (get_argument_pcop,get_return_val_pcop,pass_argument,
1945           get_returnvalue): interface for accessing function parameters and
1946             return values,
1947           (assignResultValuei,genRet): use new parameter/return value interface
1948           (pic14_getDataSize): back to old version handling generic pointers,
1949           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
1950             provided implementation and/or fixed old one,
1951           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
1952             calls, removed legacy 8051 reference code
1953           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
1954           (loadSignToC): NEW, move the operands sign bit to CARRY,
1955           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
1956             genRightShiftSigned, accepts negative shift counts,
1957           (setup_fsr): load FSR and adjust IRP (indirect memory access),
1958           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
1959             generic pointers, __data pointers and __code pointers,
1960           (genUnpackBits,genPackBits): rewritten to work with generic pointers
1961             and signed bitfields, limit bitfields to 8 bit,
1962           (genDataPointerGet): fixed number of bytes read,
1963           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
1964           (genPointerGet,genPointerSet): fixed handling of __code pointers,
1965             pointers to constant data are no longer assumed to point to __code
1966             space, removed invalid pointer types,
1967           (bitpatternFromVal): retrieve the PICs representation of an integer
1968             or float literal,
1969           (genDataPointerSet): fixed assigning to po_immediate operands,
1970           (genGenPointerSet): implemented as library call,
1971           (genIfx): fixed incorrect condition,
1972           (genAddrOf): limit generic pointers' addresses to 2 bytes,
1973             provide GPOINTER tag according to destination's storage class,
1974           (genCast): added code to handle casting to generic pointers, added
1975             sign-/zero extension of the result
1976           (aop_isLitLike,op_isLitLike): fixed handling of immediates
1977         * src/pic/gen.h: added macros to access IRP bit in STATUS register
1978         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
1979           extend the result
1980         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
1981           address/register resides in the shared banks
1982           (emitSymbolToFile): improved to handle global and `pinned' symbols,
1983             put all variables into separate sections (have the linker arrange
1984             them)
1985           (picglue): put init code and interrupt handlers in separate sections
1986         * src/pic/main.c: added port specific options table, modified to PORT
1987           structure to make GPOINTERs 3 byte, added pic14_options
1988           (_pic14_do_link): private linking routine (update paths to libraries,
1989             add libsdcc.lib by default)
1990         * src/pic/main.h: declare pic14_options
1991         * src/pic/pcode.c: fixed instructions i/o relations,
1992           (RegCond): reverted to correct version,
1993           (newpCodeOpLit): truncate literals to 8 bit,
1994           (genericPrint): added debug output,
1995           (getRegFromInstruction): fixed for various operand types, simplified
1996           (BuildFlow): fixed broken handling of isntructions with labels
1997           (LinkFlow): start at last instruction in flow (skip trailing comments),
1998             pass the flow on to the next instruction after CALL
1999           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
2000           (insertPCodeInstruction): fixed inserting after a skip instruction,
2001           (DoBankSelect): fixed for labeled instructions
2002           (OptimizepBlock): honor --nopeep switch
2003           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
2004         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
2005         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
2006           (pCodeOptime2pCodes): allow disabling this optimization via
2007             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
2008             but is still buggy), started implementation of a dataflow based
2009             pCode optimization (CSE + dead code elimination)
2010           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
2011         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
2012           names are independant of the stack location and therefore portable across
2013           devices
2014
2015 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
2016
2017         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
2018           (selectSpil): fixed bug 1337835 by not spilling bit variables
2019         * support/regression/tests/bug1337835.c: added test for this bug
2020         * src/mcs51/peeph.def: restart after rule 3.c,
2021           addded rules 263.x to optimize loading constants
2022
2023 2005-10-26 Raphael Neider <rneider AT web.de>
2024
2025         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
2026         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
2027           (genAssign): emit warning when casting literals to generic pointer
2028             type, also applies when taking the address of a fixed variable,
2029           (genCast): improved casting to generic pointers
2030         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
2031           extern variables, added verbose error message
2032         * device/include/pic16/{string.h,errno.h}: added #pragma library c
2033
2034 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
2035
2036         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
2037         carry must be complemented too
2038         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
2039         could be emitted by genMinus
2040         * src/SDCCval.c (constVal): fixed bug 1305065
2041
2042 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
2043
2044         * src/SDCCast.c (addCast): added promotion for bit variables
2045         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
2046         promotion casts + optimisation
2047         (optimizeGetWord): fix warning 'i' might be used uninitialized
2048         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
2049         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
2050
2051 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
2052
2053         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
2054         all chars are promoted to int; promotion should be handled in SDCCast.c
2055
2056 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2057
2058         * device/lib/_strcmp.c: Fixed bug 1326457
2059
2060 2005-10-11 Raphael Neider <rneider AT web.de>
2061
2062         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
2063         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
2064
2065 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
2066
2067         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
2068         * support/regression/tests/sfr16.c: added test for the sfr32 bug
2069
2070 2005-10-04 Raphael Neider <rneider AT web.de>
2071
2072         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
2073           device/lib/pic16/pics.all: added pic18f1320
2074         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
2075
2076 2005-09-30 Raphael Neider <rneider AT web.de>
2077
2078         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
2079         * src/pic16/devices.inc: NEW, provides device descriptions
2080         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
2081
2082 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
2083
2084         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
2085           GETHBIT
2086
2087 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
2088
2089         * doc/sdccman.lyx: updated Highest Order Bit documentation,
2090           documented Any Order Bit, Higher Order Byte and Higher Order Word
2091         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
2092         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
2093           (optimizeGetAbit): new, to get any bit, not only the high bit,
2094           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
2095           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
2096           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
2097           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
2098             RIGHT_OP: also try GETBYTE, GETWORD optimization,
2099             GETABIT, GETBYTE, GETWORD: decorate them,
2100           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
2101           (ast_print): added GETABIT, GETBYTE, GETWORD
2102         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
2103         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
2104           (geniCodeBinary): new generic binary icode,
2105           (ast2iCode): added GETABIT, GETBYTE, GETWORD
2106         * src/port.h: updated comment for PORT.hasExtBitOp
2107         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
2108           (genGetByte): new, to get a single byte,
2109           (genGetWord): new, to get a word from a long,
2110           (gen51Code): added GETABIT, GETBYTE, GETWORD
2111         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
2112
2113 2005-09-23 Raphael Neider <rneider AT web.de>
2114
2115         * configure.in, configure: have device/lib/pic configured
2116         * device/lib/Makefile.in: added model-pic14
2117         * device/lib/clean.mk: added pic/ to clean rule
2118         * device/lib/pic: added rudimentary pic14 library providing support
2119           functions for multiplication/division/generic pointer access
2120         * src/SDCCopt.c (convilong): mark support functions as extern
2121           for pic14 port as well
2122         * src/pic/gen.c (genMult): added assertions,
2123           (genpic14Code): emit warning on unhandled iCodes
2124         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
2125         * src/pic/pcode.c (pCodeOpCopy),
2126         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
2127           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
2128           SFR_REGISTER}), made safe for future extensions
2129         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
2130           instructions even if preceeded by SKIP instructions (also remove
2131           them); removed unused code
2132         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
2133           prevents leaving parts of the structure uninitialized after copying
2134
2135 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
2136
2137         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
2138           ago by me
2139         * support/regression/tests/addsub.c: added test for the bug
2140
2141 2005-09-21 Raphael Neider <rneider AT web.de>
2142
2143         * device/include/pic16/pic18f1220.h,
2144           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
2145         * device/lib/pic16/Makefile.rules: added missing opening paren
2146         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
2147           are provided in genutils.c,
2148           (genUminusFloat,genUminus,genCmpEq): added asserts on different
2149           operand/result sizes,
2150           (genCmp): assert on NULL pointers first, then check deref'ed values
2151         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
2152           result size
2153
2154 2005-09-18 Raphael Neider <rneider AT web.de>
2155
2156         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
2157           as these are now unused,
2158           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
2159         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
2160           local, avoids uninitialized pointer dereference on r->name
2161         * src/pic16/ralloc.c (newReg): fixed indentation
2162
2163 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
2164
2165         * src/SDCCval.c (constVal): fixed bug 730366
2166         * support/Util/SDCCerr.c,
2167         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
2168
2169 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
2170
2171         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
2172
2173 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
2174
2175         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
2176
2177 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
2178
2179         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
2180           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2181         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
2182           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2183         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
2184         * packihx/packihx.c (hexDigit): made c unsigned char
2185         * as/mcs51/lklibr.c (fndsym),
2186         * link/z80/lkgb.c (gb),
2187         * link/z80/lklibr.c (fndsym),
2188         * link/z80/lkrloc.c (relr),
2189         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
2190         * src/SDCC.lex (checkCurrFile, process_pragma),
2191         * src/SDCCglue.c (spacesToUnderscores),
2192         * src/SDCCmain.c (setParseWithComma, processFile),
2193         * src/asm.c (tvsprintf, printCLine),
2194         * src/avr/gen.c (emitcode, aopPut),
2195         * src/ds390/gen.c (emitcode),
2196         * src/hc08/gen.c (emitcode, emitinline),
2197         * src/mcs51/gen.c (emitcode, genInline),
2198         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2199           tokenizeLineNode),
2200         * src/pic/ralloc.c (debugLog),
2201         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2202           tokenizeLineNode),
2203         * src/pic16/ralloc.c (debugLog),
2204         * src/z80/main.c (_process_pragma):
2205            made all ctype.h function calls safe
2206         * src/SDCCopt.c: include math.h for fabs
2207         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
2208           and used them throughout the code to make ctype.h function calls safe
2209         * src/ds390/main.c (asmLineNodeFromLineNode),
2210         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
2211         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
2212            unsigned char*
2213         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
2214           (newpCodeAsmDir): made ctype.h function calls safe
2215         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
2216           pic16_emitcode):  made lbp unsigned char*
2217         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
2218           (pic16_newpCodeAsmDir): made ctype.h function calls safe
2219         * src/xa51/gen.c (emitcode),
2220         * src/z80/gen.c (_emit2): made lbp unsigned char*
2221         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
2222            char*
2223
2224 2005-09-05 Raphael Neider <rneider AT web.de>
2225
2226         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
2227           access bank splitpoint
2228
2229 2005-09-05 Raphael Neider <rneider AT web.de>
2230
2231         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
2232
2233 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
2234
2235         * .version: changed to version 2.5.3
2236         * doc/sdccman.lyx: changed version to 2.5.3,
2237           documented --codeseg and --constseg and pragma codeseg and constseg,
2238           documented bit parameters (reentrant) and bit returning
2239         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
2240            currFunc->recvSize, but is this ok for all ports?
2241           (ast2iCode): result of ~ on unsigned char must be cast to int for
2242            bool to work
2243         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
2244           function pointers in bit space
2245         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
2246           (processFuncArgs): call port.reg_parm() with reentrancy info
2247         * src/port.h,
2248         * src/avr/main.c,
2249         * src/ds390/main.c,
2250         * src/hc08/main.c,
2251         * src/pic/main.c,
2252         * src/pic16/main.c,
2253         * src/xa51/main.c,
2254         * src/z80/main.c: port.reg_parm prototype extended with
2255           "bool reentrant" parameter
2256         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
2257           options.stackAuto for allocating bit register parameters
2258         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
2259           (genSend): set BitBankUsed if it is,
2260           (selectRegBank): factored out of genCall for use in genPcall,
2261           (genCall): removed redundant dtype assignmen, use selectRegBank,
2262           (genPcall): handle returning in Carry properly, save in F0 if needed,
2263           (genReceive): handle bit register parameters
2264         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
2265           (mcs51_assignRegisters): enable bit registers for all reentrant
2266            functions and don't set BitBankUsed unconditionally
2267         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
2268         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
2269         * support/regression/tests/funptrs.c: added tests for BOOL and for return
2270
2271 2005-08-27 Borut Razem <borut.razem AT siol.net>
2272
2273         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
2274         ppc-osx (Darwin) does not support -u option. It seems that it is
2275         supported only on Linux - GNU cp
2276
2277 2005-08-25 Borut Razem <borut.razem AT siol.net>
2278
2279         * sim/ucsim/gui.src/serio.src/Makefile.in,
2280           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
2281           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2282           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
2283           install and strip, since the strip at /usr/ccs/bin should be used
2284           on solaris
2285
2286 2005-08-24 Borut Razem <borut.razem AT siol.net>
2287
2288         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
2289
2290 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
2291
2292         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
2293         ffffffffu
2294
2295 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
2296
2297         * as/mcs51/aslink.h: completed lkrloc.c prototypes
2298         * as/mcs51/lkmain.c (link_main): fixed warning
2299         * device/include/stdbool.h: ds390 has no advanced bit support yet
2300         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
2301         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
2302         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
2303           and updated their macros
2304         * src/SDCCval.c (constVal): updated comment for renamed b_long
2305
2306 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
2307
2308         * as/mcs51/asdata.c: changed ctype['['] to BINOP
2309         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
2310           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
2311           (oprio): set priority for '['
2312         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
2313            and adb_24_bit
2314         * as/mcs51/asm.h: added defines R_BIT and S_BIT
2315         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
2316         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
2317         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
2318           added overlayable BIT_BANK area
2319         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
2320           (summary2): explain 'T' in legenda
2321         * as/mcs51/lkrloc.c: replaced old K&R style,
2322           (relr): added R_BIT processing,
2323           (errmsg): added "Bit-addressable relocation error",
2324           (adb_bit): added for converting from byte- to bit-addressable space,
2325           (adb_24_bit): added for converting from byte- to bit-addressable space
2326         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
2327            used in reentrant functions now even as return value
2328         * device/lib/_gptrput.c (_gptrput): removed obsolete code
2329         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
2330           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
2331         * src/SDCCglobl.h: added indicator BitBankUsed
2332         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
2333            the bit registers b0-b7
2334         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
2335           (geniCodeCast): fixed bug 1263853,
2336           (geniCodeLogicAndOr): put result in bool or char,
2337           (geniCodeReceive): added parameter func for accessing the return type,
2338           (geniCodeFunctionBody): pass func to geniCodeReceive
2339         * src/SDCCmain.c: added indicator BitBankUsed
2340         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
2341         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
2342           (checkSClass): don't put automatic bool/bit on stack,
2343           (checkFunction): removed check on function cannot return bit
2344         * src/SDCCsymt.h: added newBoolLink prototype
2345         * src/mcs51/gen.c (rb1regs): added bit registers,
2346           (movc): created for assigning to carry,
2347           (pushReg, popReg): created for pushing registers,
2348           (sameRegs): check both AOP_REG and AOP_CRY types,
2349           (aopOp): handle bit registers,
2350           (aopPut): optimization no self-assign,
2351           (saveRegisters): push reg->base (bits) only once for bit registers,
2352            and use pushReg,
2353           (unsaveRegisters): pop reg->base only once and use popReg,
2354           (assignResultValue): added parameter func and return in carry for bits,
2355           (genIpush): optimization no reload in A if not changed,
2356           (genSend): bit parameters in reentrant functions are passed in bit
2357            registers by first assigning to bits in B, then save registers and
2358            copy B to bits,
2359           (genCall): handle returning in Carry properly, save it in F0 if needed,
2360           (genPcall): updated assignResultValue call, this is not safe yet for bit
2361            returning function !!!
2362           (genFunction): don't generate equ's for bit registers and use pushReg,
2363           (genEndFunction): take care of bit returning functions and use popReg,
2364           (genRet): return bit in Carry,
2365           (genIfx): optimize bit registers and other directly addressable bits,
2366           (genReceive): updated assignResultValue call
2367         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
2368           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
2369            registers when using stack-auto
2370         * src/mcs51/ralloc.c (_G): added allBitregs,
2371           (regs8051): added the bit registers,
2372           (createStackSpil): use macro IS_BIT,
2373           (getRegBit): added to allocate a bit register, else spill,
2374           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
2375           (updateRegUsage): factored out to ease stepping while debugging,
2376           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
2377            also allocate bit registers,
2378           (fillGaps): handle bit registers,
2379           (findAllBitregs): added to create bit vector with all bit registers,
2380           (mcs51_allBitregs): returns this bit vector,
2381           (mcs51_assignRegisters): when using stack-auto use bit registers for
2382            passing parameters and creating local variables
2383         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
2384
2385 2005-08-22 Borut Razem <borut.razem AT siol.net>
2386
2387         * device/lib/Makefile.in: replaced find option -or with -o
2388           to make it run on solaris
2389
2390 2005-08-22 Raphael Neider <rneider AT web.de>
2391
2392         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
2393           fixes #1265442 (crash on Solaris)
2394
2395 2005-08-20 Borut Razem <borut.razem AT siol.net>
2396
2397         * configure, configure.in: added tests for libsocket and libnsl libraries,
2398           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
2399           from support/regression/Makefile.in
2400         * support/regression/Makefile.in: added
2401         * device/lib/pic16/Makefile.common.in: force make to use bash shell
2402         * sim/ucsim/libtool: regenerated on sparc-solaris
2403         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2404           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
2405           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
2406           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
2407           sparc-solaris, which doesn't use GNU ld linker
2408         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
2409         * as/Makefile: find on sparc-solaris does not support -maxdepth option
2410
2411 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2412
2413         * src/mcs51/peeph.def: updated comments
2414
2415 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2416
2417         * device/lib/_gptrget.c,
2418         * device/lib/_gptrput.c: slightly shorter
2419         * doc/sdccman.lyx: incremented version
2420         * src/mcs51/peeph.def: moved peephole comments to the line of first
2421           change to better keep line correlation, reanimated 186.e
2422         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2423
2424 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2425
2426         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2427           David Saxton with quotes around file name.
2428
2429 2005-08-15 Borut Razem <borut.razem AT siol.net>
2430
2431         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2432           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2433           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2434           make tests run on x86_64 platform
2435
2436 2005-08-13 Raphael Neider <rneider AT web.de>
2437
2438         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2439           as it might be executed DURING a build (parallel make is wonderful)
2440
2441 2005-08-13 Raphael Neider <rneider AT web.de>
2442
2443         * device/lib/Makefile.in (port-specific-objects-pic16):
2444           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2445         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2446           dependency
2447         * device/lib/pic16/Makefile.rules: build subdirs before creating
2448           the library, removed builddir rule, create $(builddir) early in
2449           recurse rule, use empty recurse rule for leaf directories
2450         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2451           mkdir errors (race condition), removed duplicate suffix "hex"
2452           from clean rules
2453         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2454         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2455           prevents mkdir -p from aborting on Alpha
2456
2457 2005-08-12 Raphael Neider <rneider AT web.de>
2458
2459         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2460           db-statements in order to allow for arrays of pointers in code
2461           sections to be placed without interspersed 0-padding, fixes
2462           bug #1256215
2463         * (emitStatistics): fixed division by zero for pic18f1220
2464         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2465           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2466         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2467         * (pic16_pCodeConstString): keep track of already emitted string
2468           literals to prevent "duplicate definitions of symbol _str_NR"
2469         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2470           debug message
2471         * device/lib/Makefile.in: ignore failing PIC16 library builds
2472         * device/lib/pic16/Makefile: do not build if gputils are missing
2473         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2474
2475 2005-08-10 Raphael Neider <rneider AT web.de>
2476
2477         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2478           my last commit)
2479
2480 2005-08-10 Raphael Neider <rneider AT web.de>
2481
2482         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2483           Rokas' patch to add the new fixed point type "__fixed16x16"
2484         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2485           functions for __fixed16x16 arithmetics
2486         * device/lib/pic16: reimplemented the build system to support
2487           a separate build directory, better handling of libio (create
2488           the library in a separate subdir for each architecture) and
2489           easier configuration (centralized in Makefile.common)
2490
2491 2005-08-07 Raphael Neider <rneider AT web.de>
2492
2493         * src/pic16/gen.c (genrshTwo): fixed sign extension
2494         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2495         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2496           added T0CONbits
2497         * device/include/pic16/pic18f4220.h: NEW, header for
2498           pic18f4220 and pic18f4320
2499         * device/include/pic16/pic18fregs.h: added new devices,
2500           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2501         * device/include/pic16/signal.h: resolved name clashes
2502           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2503           to also allow testing for interrupt enable bits, added
2504           comments on how to use the macros
2505         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2506         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2507           register definitions for the devices
2508         * device/lib/pic16/pics.all: added new devices
2509         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2510           allocated memory
2511         * device/lib/pic16/libc/stdlib/memfree: do not count
2512           the block header as free memory
2513         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2514           simplified and added missing end-of-blocklist-marker
2515           (reported by Peter Onion, fixes #1252814)
2516         * (_mergeHeapBlock): fixed loop condition
2517         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2518           len==0, restructured code
2519         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2520           up a bit, reduced bitfield accesses, prevent endless loops
2521           in case of heap corruption
2522         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2523           "unreferenced arguments/must return a value" warnings
2524         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2525           replaced BAUDREG with SPBRG
2526         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2527           device/lib/pic16/debug/gstack/gstack.c: replaced
2528           _naked, _asm, _endasm with __naked, __asm, __endasm
2529
2530 2005-08-05 Raphael Neider <rneider AT web.de>
2531
2532         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2533           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2534
2535 2005-08-05 Borut Razem <borut.razem AT siol.net>
2536
2537         * device/lib/Makefile.in: added missing ';'
2538         * configure: removed ^M characters
2539
2540 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2541
2542         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2543           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2544           License
2545
2546 2005-08-04 Borut Razem <borut.razem AT siol.net>
2547
2548         * configure.in: pic16 libraries build 2nd try - enable running
2549           configure in device/lib/pic16
2550         * configure: regenerated from configure.in
2551         * device/lib/Makefile.in: create $(PORT)/bin directory
2552
2553 2005-08-03 Raphael Neider <rneider AT web.de>
2554
2555         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2556           to get/set values via pointers
2557         * (genUnpackBits,genPackBits): changed detection of
2558           ptr->bitfield vs. sym.bitfield, fixed access via generic
2559           pointers, removed dead (wrong) code for multibyte bitfields
2560         * (genNearPointerGet, genGenPointerGet): removed useless code,
2561           fixed bitfield detection, fixes #1250594
2562         * (genNearPointerSet): removed useless code
2563         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2564           and introduced macro pic16_emitpcode that conditionally emits
2565           the origin of the following pCode (useful for debugging SDCC)
2566         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2567         * (createDefmap): fixed handling of LFSR for --optimize-df
2568
2569 2005-08-02 Borut Razem <borut.razem AT siol.net>
2570
2571         * device/lib/Makefile.in: pic16 libraries build enabled since
2572           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2573
2574 2005-08-02 Raphael Neider <rneider AT web.de>
2575
2576         * src/pic16/gen.c (genPackBits): removed deprecated warning
2577         * (genGenPointerSet): fixed bitfield detection
2578
2579 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2580
2581         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2582
2583 2005-07-31 Raphael Neider <rneider AT web.de>
2584
2585         * device/lib/pic16/libdev/pic18f458.c,
2586           device/include/pic16/pic18f458.h: added missing T0CONbits
2587
2588 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2589
2590         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2591
2592 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2593
2594         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2595
2596 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2597
2598         * device/include/mcs51/at89c51ed2.h: added.
2599
2600 2005-07-23 Raphael Neider <rneider AT web.de>
2601
2602         * src/pic/gen.h: added emitpcode macro for debugging
2603         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2604           and replace by macro adding debug information on demand
2605         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2606         * (gencjne): tried to fix; replaced with correct (slower) code
2607         * (gen{Unp,P}ackBits): fixed single bit access
2608         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2609         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2610           previous instruction
2611         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2612           register has to be handled with care (forbidding movement
2613           of assignments/uses, removing assignments completely, ...)
2614         * (pCodeOptime2pCodes): make use of regIsSpecial
2615         * added lots of debugging output (commented out)
2616         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2617           from being reused as result UNLESS it is known to work
2618
2619 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2620
2621         * support/Util/dbuf.h: include <stddef.h> for size_t
2622         * .version: changed to version 2.5.2
2623
2624 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2625
2626         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2627
2628 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2629
2630         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2631           (genModOneByte): removed needless psha/pula
2632
2633 2005-07-22 Raphael Neider <rneider AT web.de>
2634
2635         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2636           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2637         * src/pic/gen.c (resolveIfx): do not "invent" labels
2638         * (genSkipc): changed to positive logic
2639         * (genSkipCond): removed as no longer needed
2640         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2641           backport from PIC16
2642         * (genLeftShift): check operands are in different registers
2643         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2644           INCF does not update CARRY...
2645         * src/pic/main.c: fixed _linkCmd
2646         * src/pic/pcode.c (unlinkpCode): added inactive code
2647         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2648           alive (do not assign result and operand overlapping registers)
2649
2650 2005-07-22 Raphael Neider <rneider AT web.de>
2651
2652         * src/pic/device.c (dump_sfr): replaced register declaration with
2653           call to emitSymbolToFile() to avoid duplicate symbols
2654         * (assignRelocatableRegisters): do not declare external symbols
2655         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2656           right (take size of type, not etype)
2657         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2658         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2659         * (packRegsForAccUse): disabled assignment of WREG as
2660           the result reg to prevent occurence of just fixed #1235003,
2661           fixes #1242954
2662         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2663           symbols (avoids duplicate symbols in .asm file)
2664         * (pic14emitRegularMap): use emitSymbolToFile()
2665         * src/pic/gen.c (aopOp): fixed spillLocation handling
2666         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2667         * (genDataPointerSet): removed unneccessary variables/output
2668
2669 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2670
2671         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2672         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2673
2674 2005-07-21 Raphael Neider <rneider AT web.de>
2675
2676         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2677           architecture cannot handle them efficiently, fixes bug #1235003
2678         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2679           check for empty sets before using them (fixes bug #1232190)
2680
2681 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2682
2683         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2684           (lnksect2): generate warnings for memory overlap
2685         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2686           constseg to set the name of these segments so you can instruct the linker
2687           to place them in banks
2688         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2689         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2690           added code_seg and const_seg to options
2691         * src/SDCCglue.c (emitMaps): use options.const_seg,
2692           (createInterruptVect): put interrupt vectors in segment HOME,
2693           (glue): put HOME before static segment and put the main glue in HOME,
2694           (glue): use options.code_seg
2695         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2696         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2697           these segments so you can instruct the linker to place them in banks
2698           (linkEdit): use code_loc for HOME segment which should be the first
2699           segment in code memory now
2700         * src/SDCCmem.c: fixed more stuff like bug 1238386
2701         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2702           (changePointer): don't change function pointers to code pointers for
2703           banked functions,
2704           (compareType): added exceptional check for banked function pointers
2705         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2706         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2707           after static in code memory
2708         * src/mcs51/gen.c: added aopLiteralLong prototype,
2709           (aopForSym): use getSize for functions,
2710           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2711           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2712           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2713           the segment,
2714           (genPcall): use call for literal function pointers and generate banked
2715           calls over the one trampoline so there's only one place for the user to
2716           modify according to his/hers hardware,
2717           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2718           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2719         * src/mcs51/main.c: added keyword banked,
2720           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2721         * support/Util/SDCCerr.c,
2722         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2723           needed for passing the bank and address to the trampoline
2724         * device/lib/mcs51/crtbank.asm: added for bankswitching
2725         * device/lib/mcs51/Makefile: added crtbank
2726
2727 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2728
2729         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2730           for fields at offset 0 of a struct or union as reported
2731           on 2005-07-07 in the developer mailing list.
2732
2733 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2734
2735         * src/SDCCmem.c: fixed bug 1238386
2736
2737 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2738
2739         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2740           (patch #1144962), added peephole 300, enabled 259.x
2741         * doc/sdccman.lyx: removed screenshot and provided link instead
2742
2743 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2744
2745         * doc/sdccman.lyx: added section about debugging with ddd
2746         * doc/figures/ddd_example.eps: screenshot of debugging session
2747
2748 2005-07-04 Raphael Neider <rneider AT web.de>
2749
2750         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2751           like CODE pointers, fixes #1115683
2752         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2753           call, fixes bugs #1232211, #1228110,
2754           fixed wrong casts to pCodeFlow from pCodeInstructions
2755
2756 2005-07-04 Raphael Neider <rneider AT web.de>
2757
2758         * src/pic/gen.c (popGet): changed assert to allow for
2759           bit operands
2760         * (popGetAddr): changed signature to provide
2761           an additional index, patched all call sites
2762         * (genCmpEq): handle literal-like operands correctly
2763         * (genAddrOf): added sanity checks on __code/__data pointers
2764         * (genAssign): added handling of symbols from __code section
2765         * (gencjne): do not generate code for comparisons whose result
2766           is neither stored nor used, fixes bug #1171114
2767         * (AccLsh, AccRsh): operate on operand instead of WREG
2768         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2769           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2770           by known count
2771         * rewrote complete shift-by-literal logic, commented unused
2772           functions out
2773         * (genConstPointerGet): get multiple bytes (if result size > 1),
2774           fixed handling of non-immediate addresses
2775         * (genPointerGet): handle CODE pointers like CONST pointers
2776         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2777         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2778           operand is to be treated as a literal or not
2779         * (mov2w,genPcall,genCmpEq),
2780           src/pic/genarith.c: use aop_isLitLike() to decide between
2781           literal/register contents
2782         * (addSign): added missing offset
2783         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2784           only emit comment in debug-mode,
2785           use {aop,op}_isLitLike throughout the file
2786         * src/pic/glue.c: fix initializers for pointers (work in progress)
2787         * src/pic/pcode.c (get_op): honor index on _const symbols
2788         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2789         * (dumppBlock): added pCode size estimation
2790         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2791           check for IS_SYMOP before OP_SYMBOL'ing
2792         * fixed indentation, compacted switch-statements
2793         * (allocReg): find free register and allocate it instead of
2794           allocating new registers all the time
2795         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2796           registers as its operands (necessary only for multibyte GETs)
2797
2798 2005-07-01 Raphael Neider <rneider AT web.de>
2799
2800         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2801           debugging .asm-output macros FENTRY + FEXIT
2802         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2803           way... I wonder...
2804         * (emitpComment): NEW, printf to pCode
2805         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2806           offset handling
2807         * (popGetAddr): NEW, variant of popGet to access an immediates
2808           high(er) bytes instead of the n'th byte of memory they reference,
2809           replaced popGet with popGetAddr where neccessary
2810         * (genDataPointerGet): reactivated and fixed implementation
2811         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2812           accesses
2813         * (genDataPointerSet): fixed multibyte assignments
2814         * (genpic14Code): fixed --i-code-in-asm handling
2815         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2816         * (genPlus): fixed index-out-of-bounds error
2817         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2818         * src/pic/ralloc.c: added debugging output macro FENTRY2
2819         * (spillThis): fixed indentation, enbraced for-body for clarity
2820         * (rematStr): commented out as now unused
2821         * (regTypeNum): commented out special spill case (overwrites
2822           arbitrary values)
2823         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2824
2825 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2826
2827         * doc/sdccman.lyx: documented sfr16/sfr32,
2828           added example for using storage class with function pointers
2829         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2830
2831 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2832
2833         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2834         * device/lib/_itoa.c,
2835         * device/lib/_ltoa.c: optimized codesize
2836         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2837           but don't know how to suppress the double warning.
2838         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2839         * support/Util/SDCCerr.c,
2840         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2841
2842 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2843
2844         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2845           fixed old K&R prototypes
2846         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2847         * device/lib/_gptrget.c,
2848         * device/lib/_gptrgetc.c,
2849         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2850           also new versions for small generic pointers and banked generic pointers
2851         * src/port.h: added const_name
2852         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2853         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2854         * src/SDCCcse.c (findPrevIc): check all associative operators
2855         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2856         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2857         * src/SDCCmem.c: updated comments,
2858           set far-space to 0 for pdata, results in optimized code
2859         * src/SDCCmem.h: added macro CONST_NAME
2860         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2861           moving the info into the highest bits, see also gptrget/gptrput
2862         * src/src.dsp: added sdcc.ico to project files
2863         * src/avr/gen.c (genCast): fixed bug 0x%d
2864         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2865         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2866           relation between ptr_type and DCL_TYPE,
2867           (genCast): fixed bug 0x%d
2868         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2869           (CODE)" for const_name
2870         * src/hc08/gen.c (genCast): fixed bug 0x%d
2871         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2872           (hc08_port): added "CONST (CODE)" for const_name
2873         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2874           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2875           between ptr_type and DCL_TYPE,
2876           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2877           operand* and took AOP() inside function so sfr-ness can be checked,
2878           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2879           new prototype,
2880           (genFunction, genEndFunction): optimized stack setup,
2881           (genMinus): optimized for literals with ending zeroes (in bytes),
2882           (genCast): fixed bug 0x%d
2883         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2884           (mcs51_port): added "CONST (CODE)" for const_name
2885         * src/mcs51/peeph.def: made rule 226 more generic
2886         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2887         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2888         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2889         * src/z80/main.c (z80_port): added NULL for const_name,
2890           (gbz80_port): added NULL for const_name
2891         * support/regression/tests/bug663539.c,
2892         * support/regression/tests/sfr16.c: new tests
2893
2894 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2895
2896         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2897
2898 2005-06-24 Raphael Neider <rneider AT web.de>
2899
2900         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2901           corrected typos...
2902         * device/include/pic16/signal.h: added USBIF
2903           and SIG_USB
2904
2905 2005-06-24 Raphael Neider <rneider AT web.de>
2906
2907         * device/lib/pic16/libdev/pic18f2455.c,
2908           device/include/pic16/pic18f2455.h: NEW
2909         * device/include/pic16/pic18fregs.h,
2910           device/lib/pic16/pics.all,
2911           src/pic16/device.c: added 18f2455
2912         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2913           device/include/pic16/{pic18f[68][567].h,usart.h}:
2914           replaced MULTIPLE_USARTS define with more relaible
2915           compatibility sfrs (for USART access)
2916
2917 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2918
2919         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2920           and the output asm file line is printed on two lines.
2921
2922 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2923
2924         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2925           BGT, BLE, BHI, and BLS instructions
2926         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2927           genCmpEq): removed
2928         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2929           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2930           fixes bug #1216342
2931         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2932
2933 2005-06-15 Raphael Neider <rneider AT web.de>
2934
2935         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2936         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2937         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2938           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2939           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2940
2941 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2942
2943         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2944           Marcel Telka in bug #1215704
2945
2946 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
2947
2948         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
2949           located in shared memory bank.
2950
2951 2005-05-31 Raphael Neider <rneider AT web.de>
2952
2953         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
2954           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
2955           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
2956
2957 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
2958
2959         * device/lib/_strncpy.c: fixed the fix
2960
2961 2005-05-26 Raphael Neider <rneider AT web.de>
2962
2963         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
2964           initializers with \0, bug #1208187
2965         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
2966           intializers with \0, bug #1208187
2967
2968 2005-05-26 Raphael Neider <rneider AT web.de>
2969
2970         * src/pic16/glue.c (pic16_printIvalChar): fixed string
2971           initializers with \0, bug #1208187
2972         * src/pic16/main.c (_process_pragma): added sanity checks
2973           for stack position and size, emit warnings when appropriate
2974
2975 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
2976
2977         * device/lib/_strncpy.c: fixed not filling with \0
2978
2979 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2980
2981         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
2982           createFunction),
2983         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
2984           compound_statement),
2985         * src/SDCCsymt.h,
2986         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
2987
2988 2005-05-24 Raphael Neider <rneider AT web.de>
2989
2990         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
2991
2992 2005-05-24 Raphael Neider <rneider AT web.de>
2993
2994         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
2995           TRISE definitions, closes bug #1162453
2996
2997 2005-05-22 Raphael Neider <rneider AT web.de>
2998
2999         * src/pic16/main.c (_process_pragma): check for missing
3000           arguments to pragmas code and udata
3001         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
3002           consistency fixes to match other headers (thanks to Jim Paris)
3003         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
3004
3005 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
3006
3007         * src/SDCCicode.c (isOperandEqual): fixed missing ;
3008
3009 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
3010
3011         * support/regression/tests/bug1198642.c: new test
3012         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
3013         * src/SDCCcse.c (findPrevIc): added comment, please have a look
3014         * support/scripts/resource.h,
3015         * support/scripts/resource.rc,
3016         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
3017         * support/scripts/sdcc.ico: added 32x32 icon
3018
3019 2005-05-18 Raphael Neider <rneider AT web.de>
3020
3021         * device/lib/pic16/libdev/pic18f*.c,
3022         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
3023           keywords to "__sfr" and "__at (X)"
3024         * device/include/pic16/pic18fregs.h: added pic18f4520
3025         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
3026           #1203088 (MPLAB compatibility)
3027
3028 2005-05-17 Raphael Neider <rneider AT web.de>
3029
3030         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
3031         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
3032         * device/lib/pic16/pics.all: added new devices
3033         * src/pic16/device.c: added support for pic18f4520
3034
3035 2005-05-16 Raphael Neider <rneider AT web.de>
3036         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
3037         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
3038         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
3039           convenience function for bit access
3040
3041 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
3042
3043         * device/lib/printf_large.c: fixed bug 1193299
3044         * support/regression/tests/bug1057979.c: added test %3.3s
3045
3046 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3047
3048         * device/include/mcs51/8051.h,
3049         * device/include/mcs51/8052.h: made parseable with lint
3050         * device/include/mcs51/lint.h: added include file for (sp)lint
3051         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
3052         * doc/cdbfileformat.lyx,
3053         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
3054
3055 2005-05-14 Raphael Neider <rneider AT web.de>
3056
3057         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
3058         * device/lib/pic16/libc/stdlib/itoa.c (new)
3059         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
3060         * device/lib/pic16/libio/Makefile: exclude subdir according to
3061           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
3062         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
3063         * src/pic16/gen.c (genFunction): prevent annoying warning
3064         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
3065           nameclashes on BeOS
3066         * support/cpp2/cppmain.c (cpp_output_string): new
3067         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
3068           fixes bug 1116802
3069
3070 2005-05-13 Borut Razem <borut.razem AT siol.net>
3071
3072         * src/SDCCmain.c (linkEdit): fixed bug 1195202
3073
3074 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3075
3076         * .version: changed to version 2.5.1; back to bleeding edge development
3077
3078 2005-05-11 Borut Razem <borut.razem AT siol.net>
3079
3080         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
3081           generate PDF version 1.3 documents
3082
3083 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3084
3085         * .version: changed to version 2.5.0
3086
3087 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3088
3089         * doc/sdccman.lyx: updated weblinks, index and smaller updates
3090
3091 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3092
3093         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
3094         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
3095         well as many smaller updates.
3096         * .version: changed to version 2.5.0-pre1
3097
3098 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3099
3100         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
3101
3102 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
3103
3104         * support/regression/tests/bug1185672.c: added
3105         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
3106           bug 1185672
3107         * src/mcs51/gen.c (genCall): added comments, made it look safer
3108         * src/mcs51/gen.c (genEndFunction): simplified
3109
3110 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
3111
3112         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
3113
3114 2005-04-14 Borut Razem <borut.razem AT siol.net>
3115
3116         * fixed bug 1045046 - SIGSEGV with really simple code?:
3117           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
3118           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
3119
3120 2005-04-14 Borut Razem <borut.razem AT siol.net>
3121
3122         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
3123           src/pic16/device.h: temporarily disabled experimental #inline pragma
3124           for 2.5.0 release
3125
3126 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
3127
3128         * device/include/z80/stdio.h,
3129         * device/include/z80/string.h: removed these highly incomplete files so
3130           SDCC can use the default ones in device/include/
3131
3132 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3133
3134         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
3135         gcc warning.
3136         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
3137         fix sdcpp warnings.
3138
3139 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3140
3141         * device/include/malloc.h: removed redundant __reentrant prototypes
3142         * device/lib/_mullong.c: added working xstack variant in asm (C version
3143           doesn't pass regression tests)
3144         * device/lib/bpx.c: used __data and made bpx char for mcs51
3145         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
3146           (createFunction): fixed bug with xstackPtr
3147         * src/SDCCcse.c: corrected comments
3148         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
3149           (killDeadCode, eBBlockFromiCode): removed unused code
3150         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
3151           corrected comments
3152         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
3153           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
3154           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
3155           (genModOneByte): fixed warning in MSVC
3156         * src/mcs51/main.c (): added comments
3157         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
3158
3159 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3160
3161         * src/SDCCmain.c (linkEdit): oops, changed one line too many
3162
3163 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
3164
3165         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
3166
3167 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
3168
3169         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
3170         characters arrays of larger size than the declared one.
3171
3172 2005-04-10 Borut Razem <borut.razem AT siol.net>
3173
3174         * src/pic/gen.c (genInline),
3175           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
3176           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
3177           (findNextInstruction), (findPrevInstruction),
3178           (findInstructionUsingLabel),
3179           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
3180         * src/pic/pcode.c (findLabel): added missing '\n'
3181         * src/src.dsp: added SDCCdwarf2.c to the project
3182
3183 2005-04-09 Borut Razem <borut.razem AT siol.net>
3184
3185         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
3186
3187 2005-04-08 Raphael Neider <rneider AT web.de>
3188
3189         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
3190           into the chain after a given one) and mergeDefmapSymbols (combine
3191           defmap entries for each symbol per pcode)
3192         * (createDefmap): have defmap entries merged in the end
3193         * (defmapReplaceSymRef): split defmap entries covering two accesses to
3194           a symbol before replacing one access type's symbol, merge symbols in
3195           the end (replacement symbol might already have an entry)
3196         * (assignValnums): keep reference to written WREG intact
3197
3198 2005-04-08 Raphael Neider <rneider AT web.de>
3199
3200         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
3201           Alpha)
3202
3203 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
3204
3205         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
3206         bytes
3207
3208 2005-04-07 Raphael Neider <rneider AT web.de>
3209
3210         * device/include/pic16/usart.h: added compatibility defines for
3211           devices with more than one USART
3212         * device/include/pic16/pic18f[68][567]20.h: activated above defines
3213
3214 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3215
3216         * device/lib/Makefile.in: updated for port specific include
3217
3218 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3219
3220         * support/regression/ports/mcs51/spec.mk: added mcs51 include
3221
3222 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3223
3224         * device/include/8051.h,
3225         * device/include/8052.h,
3226         * device/include/at89S8252.h,
3227         * device/include/at89c55.h,
3228         * device/include/at89x051.h,
3229         * device/include/at89x51.h,
3230         * device/include/at89x52.h,
3231         * device/include/mcs51reg.h,
3232         * device/include/reg51.h,
3233         * device/include/reg764.h,
3234         * device/include/regc515c.h,
3235         * device/include/sab80515.h: (re)moved these 12 files
3236         * device/include/mcs51/8051.h,
3237         * device/include/mcs51/8052.h,
3238         * device/include/mcs51/at89S8252.h,
3239         * device/include/mcs51/at89c55.h,
3240         * device/include/mcs51/at89x051.h,
3241         * device/include/mcs51/at89x51.h,
3242         * device/include/mcs51/at89x52.h,
3243         * device/include/mcs51/mcs51reg.h,
3244         * device/include/mcs51/reg51.h,
3245         * device/include/mcs51/reg764.h,
3246         * device/include/mcs51/regc515c.h,
3247         * device/include/mcs51/sab80515.h: and added them here
3248
3249 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3250
3251         * device/include/stdarg.h: changed SDCC specific keywords to double
3252           underlined form.
3253         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
3254           mcs51 and ds390.
3255         * device/include/hc08/mc68hc908gp32.h,
3256         * device/include/hc08/mc68hc908jb8.h,
3257         * device/include/hc08/mc68hc908jkjl.h,
3258         * device/include/hc08/mc68hc908qy.h: fixed comments
3259         * device/include/mcs51/README: updated
3260         * device/include/mcs51/c8051f120.h: added PINRSF
3261         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
3262         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
3263           amidst code. Also inline is not supported.
3264
3265 2005-04-06 Raphael Neider <rneider AT web.de>
3266
3267         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
3268         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
3269           callers stack/frame pointers
3270
3271 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3272
3273         * device/include/pic16/usart.h: added, missing in previous commit,
3274         * device/include/pic16/adc.h: fixed typo,
3275         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
3276         commit,
3277         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
3278         <p18fxxx.inc>
3279         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
3280         uninitialized because a bug appears with gplink
3281         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
3282         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
3283         complains for unrecognised option
3284
3285 2005-04-05 Raphael Neider <rneider AT web.de>
3286
3287         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
3288           structs as well (using memcpy)
3289         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
3290           on ISRs (GOTO has no label)
3291         * src/pic16/device.h: added OF_OPTIMIZE_DF
3292         * src/pic16/main.c: added compiler switch --optimize-df to enable the
3293           new data flow analysis/optimization
3294         * src/pic16/pcode.c: added (prototypes for and implementation of)
3295           dataflow analysis functions, fixed pCodeInstructions' inCond and
3296           outCond values, made RCALL a branch instruction
3297         * (pic16_unlinkpCode): keep C line if possible
3298         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
3299           C line moved if possible
3300         * (pic16_getRegFrompCodeOp): NEW, improved version of...
3301         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
3302           to use new pic16_getRegFrompCodeOp (works for more SFRs)
3303         * (pic16_BuildFlow): fixed skip instructions with label (did not start
3304           new flow)
3305         * (pic16_getJumptabpCode): NEW, needed in...
3306         * (LinkFlow): fixed handling of jumptables, calls and conditional
3307           branches
3308         * (pic16_InsertCommentAfter): NEW
3309         * (pic16_pCodeReplace): made verbose and flow preserving
3310         * (AnalyzeFlow): added call to data flow analysis
3311         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
3312         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
3313         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
3314
3315 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3316
3317         * src/SDCCast.c (decorateType): fixed bug #1105626
3318
3319 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
3320
3321         * device/include/asm/pic16/features.h,
3322         * pic18f*.h headers,
3323         * device/include/pic16/adc.h,
3324         * device/include/pic16/delay.h,
3325         * device/include/pic16/i2c.h,
3326         * device/include/pic16/malloc.h,
3327         * device/include/pic16/stdio.h,
3328         * device/include/pic16/stdlib.h,
3329         * device/include/pic16/string.h,
3330         * device/lib/pic16/libc/stdio/printf_tiny.c,
3331         * device/lib/pic16/libc/stdio/printf_small.c,
3332         * device/lib/pic16/libc/stdio/strmgpsim.c,
3333         * device/lib/pic16/libc/stdio/strmmssp.c,
3334         * device/lib/pic16/libc/stdio/strmusart.c,
3335         * device/lib/pic16/libc/stdio/vfprintf.c,
3336         * device/lib/pic16/libc/stdlib/ltoa.c,
3337         * device/lib/pic16/libc/stdlib/putchar.c,
3338         * device/lib/pic16/libc/stdlib/x_ftoa.c,
3339         * device/lib/pic16/libc/stdlib/memchrpgm.c,
3340         * device/lib/pic16/libc/stdlib/memchrram.c,
3341         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
3342         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
3343         * device/lib/pic16/libio/adc/adcbusy.c,
3344         * device/lib/pic16/libio/adc/adcread.c,
3345         * device/lib/pic16/libio/adc/adcsetch.c,
3346         * device/lib/pic16/libio/usart/ubaud.c,
3347         * device/lib/pic16/libio/usart/ubusy.c,
3348         * device/lib/pic16/libio/usart/udrdy.c,
3349         * device/lib/pic16/libio/usart/uopen.c,
3350         * device/lib/pic16/libio/usart/uputc.c,
3351         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
3352         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
3353         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
3354         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
3355         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
3356         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
3357         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
3358         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
3359         specific keywords to double underlined form,
3360         * device/lib/pic16/libc/Makefile.rules,
3361         * device/lib/pic16/libsdcc/Makefile.rules,
3362         * device/lib/pic16/libm/Makefile,
3363         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
3364         to compile with C standard set in Makefile.common
3365         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
3366         rand.c and crc.c in compilation process,
3367         * device/lib/pic16/libsdcc/int/divuint.c,
3368         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
3369         `c' from signed to unsigned,
3370         * device/lib/pic16/startup/crt0.c,
3371         * device/lib/pic16/startup/crt0i.c,
3372         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
3373         keywords to double underlined form, bug fixes in _do_cinit function
3374         which prevented the correct initialization of the .idata segment,
3375         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
3376         core to enter a infinite loop
3377         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
3378
3379 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3380
3381         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
3382
3383 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3384
3385         * device/include/Makefile.in: add support for hc08 subdirectory
3386         * device/include/hc08/: new subdirectory
3387         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
3388         Lucas Loizaga, thanks!
3389         * device/include/hc08/mc68hc908qy.h,
3390         * device/include/hc08/mc68hc908gp32.h,
3391         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
3392         their own directory. Changed internal macro names to use the compiler
3393         reserved namespace. Changed SDCC specific keywords to double
3394         underlined form.
3395         * device/include/math.h,
3396         * device/include/malloc.h,
3397         * device/include/stdarg.h,
3398         * device/include/stdbool.h
3399         * device/include/string.h,
3400         * device/include/tinibios.h,
3401         * device/include/ds400rom.h,
3402         * device/include/8051.h,
3403         * device/include/8052.h,
3404         * device/include/80c51xa.h,
3405         * device/include/at89c55.h,
3406         * device/include/at89S8252.h,
3407         * device/include/at89x51.h,
3408         * device/include/at89x52.h,
3409         * device/include/ds80c390.h,
3410         * device/include/reg764.h,
3411         * device/include/regc515c.h,
3412         * device/include/sab80515.h,
3413         * device/include/mcs51/c8051f000.h,
3414         * device/include/mcs51/c8051f018.h,
3415         * device/include/mcs51/c8051f020.h,
3416         * device/include/mcs51/c8051f040.h,
3417         * device/include/mcs51/c8051f060.h,
3418         * device/include/mcs51/c8051f120.h,
3419         * device/include/mcs51/c8051f300.h,
3420         * device/include/mcs51/c8051f310.h,
3421         * device/include/mcs51/c8051f320.h,
3422         * device/include/mcs51/c8051f330.h,
3423         * device/include/mcs51/c8051f350.h,
3424         * device/include/z180.h: Changed SDCC specific keywords to double
3425         underlined form.
3426
3427 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3428
3429         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3430         18F4455,
3431         * (pic16_assignConfigWordValue): disable testing of configuration
3432         register value with config mask,
3433         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3434         function with port->fun_prefix,
3435         * (genFunction): when generating a naked interrupt function never
3436         create an absolute segment placed in interrupt vector address, place
3437         the actual interrupt function at IVA instead, when an interrupt
3438         function is generated with unspecified interrupt then do not create
3439         the absolute section,
3440         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3441         code for generating a call to generic pointer get/put function with
3442         a call to function pic16_callGenericPointer(),
3443         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3444         the call to the generic pointer get/put functions with prefixing the
3445         function name with port->fun_prefix,
3446         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3447         * src/pic16/main.c (_process_pragma): prefix function with
3448         port->fun_prefix,
3449         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3450         calling assembler, old 18Fxxxx macro is deprecated,
3451         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3452         PC_ASMDIR in while condition,
3453         * (findInstruction): add PC_ASMDIR in while condition,
3454         * (buildCallTree): prefix main with port->fun_prefix,
3455         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3456         identifier for variable with banked access in instructions BTFSS,
3457         BTFSC, BCF, BSF, BTG
3458         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3459         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3460         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3461         perform optimization when enviroment variable NO_REG_OPT is set,
3462         * (insideLRBlock): NEW, return 1 if register is inside an
3463         INF_LOCALREGS block,
3464         * (RemoveRegFromLRBlock): remove a register that is completely
3465         eliminated by register optimization, but it is still left in local
3466         register store/restore in/from stack block,
3467         * (Remove2pcodes): after removing register, check to see if it
3468         should be removed from local register store/restore in/from stack
3469         block,
3470         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3471         DUMMY_READ_VOLATILE,
3472
3473         * device/include/pic16/adc.h: minor prototype modifications and
3474         update,
3475         * device/include/pic16/malloc.h: added GPL notice various
3476         modifications,
3477         * device/include/pic16/stdint.h: NEW, standard header for ints
3478         * device/include/pic16/delay.h: NEW, header for delay functions,
3479         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3480         delay1mtcy,
3481         * device/include/pic16/signal.h: NEW, header providing helper macros
3482         for implementing signal handlers,
3483         * device/include/pic16/stdio.h: added prototypes for functions,
3484         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3485         prototypes for stdin and stdout, added macro PUTCHAR to
3486         automatically implement putchar function prototype,
3487         * device/include/pic16/usart.h: modified and updated USART library,
3488         * device/lib/pic16/libio/adc/,
3489         * device/lib/pic16/libio/i2c: some modifications to improve library
3490         performance,
3491         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3492         family of functions,
3493         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3494         family of functions and other sources,
3495         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3496         of the PIC18Fxx[28] devices,
3497         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3498         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3499         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3500         _do_cinit function, because the previous failed when local variables
3501         where not placed in the same memory bank,
3502         * device/lib/pic16/libsdcc/char/: various modifications to improve
3503         library performance,
3504         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3505         information on the new functions of the c library and more...
3506
3507 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3508
3509         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3510
3511 2005-03-26 Raphael Neider <rneider AT web.de>
3512
3513         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3514           if condition == CARRY)
3515         * (genCmp): adapted to new genSkipc semantics
3516         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3517           on rIfx (genCmp was broken)
3518
3519 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3520
3521         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3522         * src/z80/main.c (_keywords[]),
3523         * src/SDCCglobal.h (struct options),
3524         * src/SDCC.y,
3525         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3526         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3527         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3528         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3529         always available in leading double underscore form. The C99 support is
3530         mostly missing, but it's a start.
3531         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3532         reserved identifier "__data".
3533
3534 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3535
3536         * src/mcs51/peeph.def: fixed bug 1170013
3537
3538 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3539
3540         * device/include/mcs51reg.h: fixed bug 842007
3541
3542 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3543
3544         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3545         last time.
3546
3547 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3548
3549         * src/port.h (struct PORT),
3550         * src/avr/ralloc.c (avr_assignRegisters),
3551         * src/avr/main.c,
3552         * src/ds390/ralloc.c (ds390_assignRegisters),
3553         * src/ds390/main.c,
3554         * src/hc08/ralloc.c (hc08_assignRegisters),
3555         * src/hc08/main.c,
3556         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3557         * src/mcs51/main.c,
3558         * src/pic/ralloc.c (pic14_assignRegisters),
3559         * src/pic/main.c,
3560         * src/pic16/ralloc.c (pic16_assignRegisters),
3561         * src/pic16/main.c,
3562         * src/xa51/ralloc.c (xa51_assignRegisters),
3563         * src/xa51/main.c,
3564         * src/z80/ralloc.c (z80_assignRegisters),
3565         * src/z80/ralloc.h,
3566         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3567         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3568         * src/SDCCcse.h,
3569         * src/SDCCdflow.c (computeDataFlow),
3570         * src/SDCCdflow.h,
3571         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3572         * src/SDCCloop.h,
3573         * src/SDCCcflow.c (*),
3574         * src/SDCCcflow.h,
3575         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3576         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3577         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3578         immedDom() returning wrong block; probably fixes bug #1160833)
3579
3580 2005-03-20 Borut Razem <borut.razem AT siol.net>
3581
3582         * support/scripts/inc2h.pl: WIN32 port
3583
3584 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3585
3586         * device/lib/makefile.in: added abs.c and labs.c
3587
3588 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3589
3590         * device/include/stdint.h: added
3591         * device/lib/abs.c: added
3592         * device/lib/labs.c: added
3593         * device/include/stdlib.h: added abs() and labs() prototypes
3594         * device/lib/libsdcc.lib: added abs and labs
3595         * device/include/float.h,
3596         * device/lib/_fsmul.c,
3597         * device/lib/printf_fast.c,
3598         * device/lib/printf_tiny.c: updated comments
3599
3600 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3601
3602         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3603         bug #1164313
3604
3605 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3606
3607         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3608         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3609
3610 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3611
3612         * device/lib/printf_large.c: removed inline assembly for portability and
3613           readability. Use printf_fast if speed or size are more important.
3614         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3615         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3616
3617 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3618
3619         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3620         prevent compiler warning
3621
3622 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3623
3624         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3625         moved to level 0 and declared as static. Also they are explicit
3626         placed in access bank. This was necessery because some times they
3627         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3628         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3629         optimizations. Currently only compare to unsigned char is implemented,
3630         * src/pic16/gen.c: added fReturnIdx array,
3631         * (struct resolvedIfx) is moved to gen.h and made public,
3632         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3633         * (aopForSym): added an optimization to directly store in stack of
3634         the operand of a SEND iCode,
3635         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3636         but as registers instead (AOP_REG) using the fReturnIdx array,
3637         * (pic16_freeAsmop): remove the freed register from the
3638         _G.sregsAlloc field,
3639         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3640         a compare of 'WREG',
3641         * (pic16_popGetTempRegCond): changed function prototype, now
3642         function takes also a bitVector argument v which holds the current
3643         set of registers that are allocated for stack access by aopForSym,
3644         registers allocated in aopForSym for accessing stack symbols are not
3645         any more part of the functions usedRegs field,
3646         * (genCall): some times aopOp is called for a stack variable to be
3647         send, aopForSym might perform the push, if this is true make sure
3648         that genCall doesn't push the variable twice by testing _G.resDirect,
3649         * (genFunction): changed testing for unspecified interrupt number
3650         from 256 to INTNO_UNSPEC,
3651         * modified selection scheme of frame pointer generation. Previously
3652         if function did use local registers a frame pointer was generated,
3653         now a frame pointer is generated only if function has arguments
3654         (that need PLUSW2 register access), or has stack arguments, or the
3655         compiler is not instructed to omit the frame pointer,
3656         * (genEndFunction): before restoring local registers that were saved
3657         in the function preamble, also restore the registers that *might*
3658         have been allocated for stack access,
3659         * (genRet): removed some old comments,
3660         * (genCmp, the active (RN's) version): added a call to the
3661         pic16_genCmp_special function to perform the compare with a more
3662         robust and optimized way,
3663         * (genInline): a feature has been added in inline code generation,
3664         which allows a wildcard variable substitution when writing inline
3665         assembly. Code is incomplete and experimental therefore undocumented,
3666         * (genCast): changed order of aopOp for result and right to allow
3667         aopForSym to directly load the result if possible,
3668         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3669         perform an optimized compare on some selected special occasions,
3670         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3671         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3672         generate an IVT any more,
3673         * src/pic16/main.c (pic16_optionsTable): added command line option
3674         --optimize-cmp,
3675         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3676         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3677         macros,
3678         * src/pic16/NOTES: Raphael Neider added in list of active developers
3679         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3680         jumptable_end to prevent bug #,
3681         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3682         inCond and outCond fields,
3683         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3684         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3685         turn off register spilling,
3686         * (packRegsForOneUse): synced with other ports' versions although it
3687         is not used currently,
3688         * (pic16_packRegisters): added an optimization while reading
3689         structure bitfields, some registers may be saved (malloc code is
3690         decreased by 80 bytes)
3691
3692 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3693
3694         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3695         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3696         this can be optimized more?
3697
3698 2005-03-10 Raphael Neider <rneider AT web.de>
3699
3700         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3701           genNearPointerGet): (hopefully) fixed access to bitfields via
3702           pointers (p->bitN = x; and x = p->bitN; failed)
3703
3704 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3705
3706         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3707
3708 2005-03-09 Raphael Neider <rneider AT web.de>
3709
3710         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3711
3712 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3713
3714         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3715         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3716           (regTypeNum): set REG_BIT type if necessary
3717         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3718         * support/regression/tests/critical.c: check bug 1144613
3719
3720 2005-03-02 Raphael Neider <rneider AT web.de>
3721
3722         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3723
3724 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3725
3726         * src/avr/ralloc.c (serialRegAssign),
3727         * src/ds390/ralloc.c (serialRegAssign),
3728         * src/hc08/ralloc.c (serialRegAssign),
3729         * src/mcs51/ralloc.c (serialRegAssign),
3730         * src/pic/ralloc.c (serialRegAssign),
3731         * src/pic16/ralloc.c (serialRegAssign),
3732         * src/xa51/ralloc.c (serialRegAssign),
3733         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3734
3735 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3736
3737         * src/SDCCast.c (decorateType): fixed bug 1124787
3738
3739 2005-02-20 Hubert Sack <sack AT digiplan.de>
3740         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3741
3742         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3743         patch #1121755
3744
3745 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3746
3747         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3748         to keep the correct label reference count when adding/removing references
3749         to labels. A peephole file using this is appended to patch #1144962.
3750
3751 2005-02-14 Raphael Neider <rneider AT web.de>
3752
3753         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3754         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3755         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3756           retrievals of result operand's value on assignment
3757
3758 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3759
3760         * device/include/pic16/string.h: modified prototype for memccpy()
3761         to memccpy(void *, void *, char, size_t)
3762         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3763         check whether to omit frame pointer or not,
3764         * (genInline): convert all occurences of "\n" to LF in inline
3765         assembler blocks, this helps formatting the inline text,
3766         * (pic16_loadFSR0): modified prototype,
3767         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3768         removed some 8051 legacy code,
3769         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3770         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3771         before allocating temporary registers in functions,
3772
3773 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3774
3775         * support/regression/tests/bitvars.c: corrected the "fix"
3776
3777 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3778
3779         * support/regression/tests/bitvars.c,
3780         * support/regression/tests/bitwise.c,
3781         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3782
3783 2005-02-10 Raphael Neider <rneider AT web.de>
3784
3785         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3786           different size for Alpha
3787         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3788
3789 2005-02-09 Raphael Neider <rneider AT web.de>
3790
3791         * src/SDCC.lex(doPragma) : save and restore warning options as well
3792           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3793         * have #pragma less_pedantic set the errorlevel to WARNING
3794           (fixes #1117001)
3795         * (cloneOptimize) : fixed wrong malloc's size
3796         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3797           facilitate correct handling of #pragma (save|restore)
3798
3799 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3800
3801         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3802
3803 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3804
3805         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3806
3807 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3808
3809         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3810
3811 2005-02-02 Raphael Neider <rneider AT web.de>
3812
3813         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3814         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3815         * (pic16_storeForReturn): fixed to allow returning function pointers
3816         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3817         * device/include/pic16/{stddef.h,stdbool.h}: added
3818
3819 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3820
3821         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3822
3823 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3824
3825         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3826         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3827          appeared to be required
3828
3829 2005-01-31 Borut Razem <borut.razem AT siol.net>
3830
3831         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3832           include/mcs51 and include/z80 directories to the package
3833
3834 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3835
3836         * src/hc08/gen.c (genFunction): fixed bug #1112752
3837
3838 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3839
3840         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3841
3842 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3843
3844         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3845
3846 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3847
3848         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3849
3850 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3851
3852         * device/include/c8051fxxx.h: removed these 6 files
3853         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3854
3855 2005-01-26 Raphael Neider <rneider AT web.de>
3856
3857         * src/pic16/gen.c (genAssign): fixed assignment from longs
3858           in codespace (were cut to three bytes)
3859         * (genDummyRead): implemented (except for CODESPACE...),
3860           fixed bug #1108575
3861         * src/pic16/glue.c (emitStatistics): beautified
3862         * device/lib/pic16/libm/Makefile: added include path
3863
3864 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3865
3866         * src/z80/gen.c (aopPut): fixed bug #1103902
3867
3868 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3869
3870         * device/lib/expf.c: fixed bug #1095792
3871
3872 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3873
3874         * device/lib/pic16/libm: added Math library sources
3875
3876 2005-01-24 Raphael Neider <rneider AT web.de>
3877
3878         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3879           to enable upcast to pCodeOpReg2 (there is no type tag to
3880           differenciate the two and pic16_popGet2p cast into PCOR2)
3881         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3882           (sizeof(sectNames) changed to sizeof(sectName))
3883           Both patches fix segfaults under MinGW.
3884
3885 2005-01-23 Raphael Neider <rneider AT web.de>
3886
3887         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3888           Safe_[mc]?alloc()'ed variables
3889         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3890           of (byte sized) temporaries (assign them to WREG for now)
3891         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3892           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3893           this might fix SIGSEGVs on MinGW...
3894         * src/SDCCopt.c (killDeadCode): restored original behaviour
3895           (volatile operands might get thrown away though)
3896
3897 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3898
3899         * src/pic16/gen.c: fixed bug #1106975,
3900         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3901         pointer update, INTCON is saved, global interrupts are disabled and
3902         restored after updateing TOS.
3903         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3904         * added function attribute 'shadowregs' to take advantage of shadow
3905         registers,
3906         * added function attribute 'wparam' as an alternative to the wparam
3907         pragma,
3908         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3909         user declares a non-ISR function as 'shadowregs',
3910         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3911
3912 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3913
3914         * .version: bumped version number to 2.4.8
3915         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3916         pic16 port,
3917         * device/lib/pic16/libio/i2c/: I2C module support library,
3918         * device/include/pic16/i2c.h: I2C support library header,
3919         * device/lib/pic16/libc/stdio/: standard IO support sources,
3920         * (printf_small.c): printf_small() source, supports float print,
3921         * (printf_tiny.c): printf_tiny() source, does not support floats,
3922         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3923         enable global optimizations for entire library source, other
3924         Makefiles in the source tree are also modified to reflect this,
3925         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3926         function,
3927         * doc/sdccman.lyx: updated to reflect new changes,
3928         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3929         sym->onStack if-case,
3930         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3931         sbit, idata, _idata, xdata, _xdata,
3932         * added pragma library, to link an external library, (see doc),
3933         * removed command line options, --pomit-config-words, --pomit-ivt,
3934         --pleave-reset-vector,
3935         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3936         when calling assembler to reflect memory model used, also define
3937         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3938         reflect stack model used,
3939         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3940         on stack return NULL,
3941
3942 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3943
3944         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
3945           of the operands is volatile. Fixes #1020220
3946
3947 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3948
3949         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
3950         * (OptimizeRegUsage): make sure that there is really no other flow where
3951           the first pCode is used
3952
3953 2005-01-22 Raphael Neider <rneider AT web.de>
3954
3955         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
3956           to fix #1106967 (pCode->seq are not set up correctly)
3957
3958 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3959
3960         * src/SDCCglue.c (glue): make sure code area is declared before the
3961         static initialization area.
3962
3963 2005-01-21 Raphael Neider <rneider AT web.de>
3964
3965         * device/lib/Makefile.in: fixed test for pic16 install dir
3966         * device/lib/pic16/*/Makefile*: modified compile flags to enable
3967           optimizations
3968         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
3969           added --optimize-goto compiler switch and pragma wparam documentation
3970         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
3971         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
3972           and PRODH closing bug #1071770 (peephole optimizer)
3973
3974 2005-01-19 Raphael Neider <rneider AT web.de>
3975
3976         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
3977           cmdLine buffers (used when calling sdcpp...) are large enough
3978           (MAX_PATH=256 truncates arguments leading to system halts when
3979           used in MinGW...)
3980         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
3981         * (genUminus): rewritten to for efficiency
3982         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
3983           used uninitialized in some cases)
3984         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
3985           copy the third byte from the int -- now assumes 0x80 (data memory)
3986         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
3987           operands (genAddLit expects the iCode's operands to swapped as
3988           well), fixed leftover bytes (crashed for short left operands)
3989         * (pic16_genMinusDec): performance improvements, removed false
3990           PIC14 emitSKPNCs
3991         * (pic16_genMinus): fixed to cope with differently sized operands
3992         * src/pic16/glue.c (pic16_glue): added new banksel optimization
3993           for --obanksel > 1
3994         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
3995         * src/pic16/graph.[ch]: implementation of directed graphs, used by
3996           new banksel optimization
3997         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
3998           analysis for temporary registers (segfaults...)
3999         * src/pic16/peeph.def: added rule
4000
4001 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
4002
4003         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
4004         which converts a float number to its ASCII representation
4005         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
4006         functions to convert the fractional and integer part of a float to ASCII,
4007         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
4008         realloc.c): added _MALLOC_SPEC to explicit place variables in data
4009         ram
4010         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
4011         _STATMEM macros,
4012         * device/include/pic16/adc.h: added GPL info,
4013         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
4014         a pCodeOp as tested operand,
4015         * (genNearPointerGet): optimized bit testing, does not use
4016         intermediate register for bit value, test directly instead with
4017         BTFSS, BTFSC, works only for single bits,
4018         * (genpic16Code): dump the name of the iCode in the asm,
4019         * src/pic16/ralloc.c (decodeOp): removed static declaration and
4020         renamed to pic16_decodeOp,
4021         * (serialRegAssign): do not allocate a temporary register for iCode
4022         sequences that test a single bit for 1/0
4023
4024 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
4025
4026         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
4027         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
4028         access stack and frame pointers. They are initially assigned to
4029         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
4030         accessing SFRs. Updated all occurences of modification of stack or
4031         frame pointer in gen.c and pcode.c,
4032         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
4033         assigning of a literal value to pointers,
4034         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
4035         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
4036         selected
4037
4038 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
4039
4040         * doc/sdccman.lyx: update documentation about stack pragma, added
4041         some info for stack memory models
4042
4043 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4044
4045         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
4046
4047 2005-01-08 Raphael Neider <rneider AT web.de>
4048
4049         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
4050           udata sections to fix bug #1097823
4051
4052 2005-01-05 Raphael Neider <rneider AT web.de>
4053
4054         * src/pic16/gen.c (genGenericShift): added handling of differently
4055           sized left operand and result
4056
4057 2005-01-04 Raphael Neider <rneider AT web.de>
4058
4059         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
4060         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
4061           to hold the condition bit)
4062         * added new version of genCmp (old code available via #define)
4063         * added new version of genShiftLeft/genShiftRight in a generic
4064           way, now supports shifting by negative values
4065         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
4066           shiftCount (expected by genGenericShift)
4067         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
4068         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
4069           dump
4070         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
4071           is an invalid literal too...)
4072
4073 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
4074
4075         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
4076         from Raphael Neider,
4077         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
4078         for 8-bit literals. This fixes some literal operands which are sign
4079         extended to 16-bits ints when instruction needs only 8-bits.
4080
4081 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
4082
4083         * device/lib/logf.c: added mcs51 assembly version
4084         * device/lib/expf.c: added mcs51 assembly version
4085         * device/lib/_logexpf.c: new shared asm code for expf and logf
4086         * device/include/math.h: add defines for assembly math library
4087         * device/lib/Makefile.in: build new _logexpf.c
4088         * device/lib/libfloat.lib: use new _logexpf.c
4089
4090 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4091
4092         * src/pic/device.c
4093         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
4094           device types which have less than 0x7f registers.
4095
4096 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4097
4098         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
4099
4100 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4101
4102         * device/lib/printf_fast.c: only build on supported arch.
4103         * device/lib/printf_tiny.c: only build on supported arch.
4104         * device/lib/printf_fast_f.c: only build if asm float lib
4105         * device/lib/_fsget1arg.c: only build if asm float lib
4106         * device/lib/_fsget2args.c: only build if asm float lib
4107         * device/lib/_fsnormalize.c: only build if asm float lib
4108         * device/lib/_fsreturnval.c: only build if asm float lib
4109         * device/lib/_fsrshift.c: only build if asm float lib
4110         * device/lib/_fsswapargs.c: only build if asm float lib
4111         * device/include/stdio.h: don't provide print_fast,
4112           print_fast_f, print_tiny prototypes if --xstack used
4113
4114 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
4115
4116         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
4117         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
4118           to the SOURCES
4119
4120 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4121
4122         * device/lib/printf_fast_f.c: same as printf_fast, but
4123           with floating point enabled
4124         * device/lib/printf_fast.c: minor tweaks
4125         * device/include/stdio.h: add printf_fast_f
4126
4127 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4128
4129         * src/SDCCmain.c: make --float-reent default for mcs51
4130         * device/lib/_fsadd.c: added mcs51 assembly version
4131         * device/lib/_fssub.c: added mcs51 assembly version
4132         * device/lib/_fsmul.c: added mcs51 assembly version
4133         * device/lib/_fsdiv.c: added mcs51 assembly version
4134         * device/lib/_fseq.c: added mcs51 assembly version
4135         * device/lib/_fsneq.c: added mcs51 assembly version
4136         * device/lib/_fsgt.c: added mcs51 assembly version
4137         * device/lib/_fslt.c: added mcs51 assembly version
4138         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
4139         * device/lib/Makefile.in: add _fscmp to build
4140         * device/lib/libfloat.lib: add _fscmp to build
4141
4142 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4143
4144         * device/lib/_fs2slong.c: added mcs51 assembly version
4145         * device/lib/_fs2sint.c: added mcs51 assembly version
4146         * device/lib/_fs2schar.c: added mcs51 assembly version
4147         * device/lib/_fs2ulong.c: added mcs51 assembly version
4148         * device/lib/_fs2uint.c: added mcs51 assembly version
4149         * device/lib/_fs2uchar.c: added mcs51 assembly version
4150         * device/lib/_slong2fs.c: added mcs51 assembly version
4151         * device/lib/_sint2fs.c: added mcs51 assembly version
4152         * device/lib/_schar2fs.c: added mcs51 assembly version
4153         * device/lib/_ulong2fs.c: added mcs51 assembly version
4154         * device/lib/_uint2fs.c: added mcs51 assembly version
4155         * device/lib/_uchar2fs.c: added mcs51 assembly version
4156         * device/include/float.h: added #define to select asm vs c
4157
4158 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
4159
4160         * device/lib/printf_fast.c: improvements to float output
4161         * device/include/float.h: add defines for assembly float library
4162         * device/lib/_fsget1arg.c: receive 1 float arg
4163         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
4164         * device/lib/_fsnormalize.c: normalize a float
4165         * device/lib/_fsreturnval.c: return float, various helper routines
4166         * device/lib/_fsrshift.c: right shift a float's mantissa
4167         * device/lib/_fsswapargs.c: swap 2 floats
4168         * device/lib/Makefile.in: build these 6 new files for mcs51
4169         * device/lib/libfloat.lib: add these 6 files to the library
4170
4171 2004-12-26 Borut Razem <borut.razem AT siol.net>
4172
4173         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
4174           built by gcc 3.4.2
4175
4176 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
4177
4178         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
4179           and fully reentrant and register bank neutral.
4180         * device/lib/printf_fast.c: added float (not enabled by default),
4181           added compact/slower integer (also not enabled by default),
4182           improved size/speed of fast integer code, other minor changes
4183         * device/include/stdio.h, device/lib/Makefile.in,
4184           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
4185
4186 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
4187
4188         * src/pic16/pcode.c: declaring variables other than at the start of a
4189           block is not supported in C by VC6.
4190
4191 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
4192
4193         * applied a previous patch from Raphael Neider that wasn't included
4194         in the previous commits, which fixes infinite loops within jumptable
4195         improvements,
4196         * made some fixes that previous patches introduced
4197
4198 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
4199
4200         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
4201         that fixes an issue with AOP_PCODE asmop's offset,
4202         * (pic16_popCopyReg): update instance field too,
4203         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
4204         function of pic port,
4205         * (genCmp, genAnd, genAssign),
4206         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
4207
4208 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
4209
4210         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
4211         variables initial values to idata section,
4212         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
4213         variables in some functions. This utilizes parmBytes field of iCode
4214         structure to hold the offset of the variable in stack. (might be
4215         able to use the stack field too?)
4216         * applied patch from Raphael Neider # ### , # ###
4217         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
4218         variable initial values in idata section,
4219         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
4220         for static variables with initial value
4221         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
4222         applied fix in while loop from Raphael Neider.
4223
4224 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
4225
4226         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
4227         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
4228         * src/ds390/ralloc.c (serialRegAssign): spill bits
4229         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
4230         * support/Util/SDCCerr.c,
4231         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
4232         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
4233         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
4234
4235 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
4236
4237         * device/include/sdcc-lib.h: inserted LGPL, added includes
4238           asm/ds390/features.h and asm/mcs51/features.h
4239         * device/include/asm/default/features.h,
4240         * device/include/asm/gbz80/features.h,
4241         * device/include/asm/z80/features.h: added empty _AUTOMEM
4242           and _STATMEM
4243         * device/include/asm/ds390/features.h,
4244         * device/include/asm/mcs51/features.h: added files with defines for
4245           _AUTOMEM and _STATMEM indicating automatic and static storage class
4246         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
4247         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
4248         * src/SDCCicode.c (geniCodeCast),
4249         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
4250         * src/SDCCloop.c (loopInduction): removed unused variable lr
4251         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
4252           to convertToFcall to include char modulo (RFE 1065037), added check
4253           if left operand is unsigned and use abs of literal value
4254         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
4255           as it doesn't work after conversion from peephole.def to peephole.rul
4256         * src/mcs51/gen.c (toBoolean): added check for size,
4257           (genModOneByte): optimized code for signed char modulo a literal
4258           power of 2 (thanks to Hubert Sack),
4259           (genRRC): removed unnecessary "clr c",
4260           (genRLC): replaced "add a,acc" with cheaper "rlc a"
4261         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
4262           jump optimization,
4263           swapped rules 256.c and 256.d,
4264           extended 256.d by using new multiple checks (thanks Erik),
4265           added rules 256.e and 256.f,
4266           updated rule 261.a and 261.b to new generated code
4267         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
4268
4269 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4270
4271         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
4272           induction related bugs, including first part of bug #1074377
4273
4274 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
4275
4276         * applied patch from bug-report #1076292,
4277         * applied patches for genAnd and Goto-optimizations for Raphael
4278         Neider,
4279         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
4280         dump a less iCode information,
4281         * src/pic16/device.h (pic16_options_t): added field debgen,
4282         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
4283         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
4284         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
4285         puclic,
4286         * (various functions): added macros FENTRY and FENTRY2 to functions,
4287         to emit function prologue,
4288         * (various functions): fixed indentation,
4289         * (genNearPointerGet): fixed loading of FSR0,
4290         * (genPackBits): applied patch from Raphael Neider to fix updating
4291         of FSR0 and touching only the modified bits,
4292         * src/pic16/genarith.c (various functions): added macros FENTRY to
4293         emit function prologue in comments,
4294         * src/pic16/pcode.h: added functions debugf2, debugf3,
4295         * src/pic16/ralloc.c: partial fix for packForPush caused
4296         segmentation fault,
4297
4298 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4299
4300         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
4301           <stsp AT users.sourceforge.net> with reversed byte order
4302         * support/regression/tests/rotate.c: added (ds390 skips some tests)
4303
4304 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4305
4306         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
4307           bug #1074377
4308         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
4309         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
4310
4311 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4312
4313         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
4314
4315 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4316
4317         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
4318           conditions,
4319           (setFromConditionArgs): friendly operand parser for peephole rules,
4320           (operandBaseName, operandsNotRelated): new peephole condition
4321           "operandsNotRelated" -- similar to "operandsNotSame", but takes
4322           architecture specific register naming into account, handles n-way
4323           comparisons, and supports quoted literals
4324         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
4325
4326 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4327
4328         * src/mcs51/peeph.def: fixed bug #1076940
4329
4330 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4331
4332         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
4333
4334 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4335
4336         Adding support for replacing ljmps with sjmps in jumptables
4337         generated for switch statements. For now you need to set the
4338         environment variable SDCC_SJMP_JUMPTABLE to enable this.
4339         Now 4 algorithms for mcs51 jumptable generation are used:
4340         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
4341         addresses loaded pc-relative for up to 112 cases and stack-pushing
4342         target addresses loaded with offset from dptr for up to 256 cases.
4343
4344         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
4345         * src/mcs51/main.c: adapted constants for switch table generation
4346         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
4347
4348 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
4349
4350         * device/lib/printf_large.c (_print_format): fixed bug 1073386
4351         * support/regression/tests/bug1057979.c: added test for bug 1073386
4352
4353 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4354
4355         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
4356         compilers
4357
4358 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4359
4360         * src/pic16/device.h,
4361         * src/pic16/genarith.c,
4362         * src/pic16/glue.c,
4363         * src/pic16/main.c,
4364         * src/pic16/pcode.c: applied patches #1068154 and #1070213
4365
4366 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
4367
4368         Large cummulative patch for pic16 port.
4369         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
4370         to call when a stack overflow occurs,
4371         * (malloc.h): added CVS Id tag,
4372         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
4373         variable,
4374         * added libc directory. The current version of LibC contains string
4375         functions, ctype functions and macros and some functions of the
4376         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
4377         be extensively tested in the future. Standard disclaimer here.
4378         Library is not automatically build yet. But one can build it by
4379         invoking 'make' inside the libc directory.
4380         * added ADC library under libio. Preliminary version yet.
4381
4382         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
4383         * src/pic16/gen.c (aopForRemat): asmop size is filled by
4384         aopForRemat() now and not by pic16_aopOp(),
4385         * (pic16_popGetTempReg): removed warning messgae when allocating
4386         temporary registers, its a buggy feature and will be removed,
4387         * (pic16_popGet): set register instance field in AOP_CRY,
4388         * (pic16_outBitC): fixed for results in size greater than 1,
4389         * (genUminusFloat): fixed for pic16, ported code from mcs51,
4390         * (pic16_storeForReturn): optimized return of 0,
4391         * (genCmp): experimental code for new genCmp which uses PIC18's
4392         special compare&skip instructions. Initial tests fail some times
4393         with variables grater than 1 byte in size, so new code is disabled,
4394         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
4395         a single bit,
4396         * (genCast): began a fix to optimize the casting of a bit to another
4397         bit, now assigning a bitfield to another bitfield will fail, sorry,
4398         * src/pic16/main.c: disabled the use of lr-support feature,
4399         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
4400         * added some function prototypes, added function _debugf prototype,
4401         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
4402         bits with offset (case PO_GPR_BIT),
4403         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
4404         command line,
4405         * (isBankInstruction): modified to return 0 for no banking instruction,
4406         and 1 for banking instruction,
4407         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
4408         caused stop processing pCodes after a inline assembly block,
4409         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
4410         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4411         registers when it shouldn't,
4412         * src/pic16/ralloc.c (allocReg): add preliminary support for
4413         supporting a limited set of temporary registers,
4414
4415 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4416
4417         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4418           genDataPointerSet): ensure assignments always copy in MSB to LSB
4419           order,
4420           (loadRegFromAop): recognize CLRH optimization,
4421           (genFunction): optimize RECEIVE iCodes in reentrant functions
4422
4423 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4424
4425         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4426           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4427           selected.
4428         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4429         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4430           contiguous with data
4431
4432 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4433
4434         * device/lib/_gptrget.c (_gptrget),
4435         * device/lib/_gptrgetc.c (_gptrgetc),
4436         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4437           instead of sjmp to ret
4438         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4439           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4440
4441 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4442
4443         * .version: bumped version to 2.4.7
4444         * device/lib/_gptrget.c (_gptrget): is now _naked
4445         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4446         * device/lib/_gptrput.c (_gptrput): is now _naked
4447         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4448           (createFunction): fixed xstack
4449         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4450         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4451           or bit either,
4452           (geniCodeCritical): store original interrupt state in an iTemp bit
4453           var unless stack-auto
4454         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4455         * src/SDCCmain.c (setIncludePath): added include/target to search path
4456         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4457         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4458           prototype,
4459           (processFuncArgs): put bit vars in bit area
4460         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4461           unsaveRBank): fixed xstack,
4462           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4463           (genFunction, genEndFunction): fixed xstack,
4464           (genAssign): optimization don't walk backwards through mem
4465         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4466         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4467         * support/regression/Makefile: also make library (for stack-auto) when
4468           making "all" and added "test-mcs51-xstack-auto"
4469         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4470         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4471         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4472         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4473         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4474           make-library by MAKE_LIBRARY
4475         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4476           regression tests for xstack
4477         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4478         * support/regression/tests/critical.c: test for critical on mcs51
4479
4480 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4481
4482         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4483           built version of sdcc instead of installed version
4484
4485 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4486
4487         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4488         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4489           vprintf.c now
4490         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4491         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4492           WARNING: remove device/lib/build/z80/printf.o by hand when
4493           updating from previous build!
4494         * device/lib/z80/printf.c: updated comment
4495         * support/regression/tests/bug1057979.c: test all ports now
4496         * support/regression/tests/bug1065458.c: file added
4497
4498 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4499
4500         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4501           *_start and *_end symbols for static functions
4502
4503 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4504
4505         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4506           and search crt0.o in all library paths,
4507           (setIncludePath): proper handling of --nostdinc,
4508           (setLibPath): proper handling of --nostdlib
4509         * support/regression/Makefile,
4510         * support/regression/ports/ds390/spec.mk,
4511         * support/regression/ports/gbz80/spec.mk,
4512         * support/regression/ports/hc08/spec.mk,
4513         * support/regression/ports/mcs51/spec.mk,
4514         * support/regression/ports/mcs51-large/spec.mk,
4515         * support/regression/ports/mcs51-stack-auto/spec.mk,
4516         * support/regression/ports/z80/spec.mk: use include and lib files from
4517           built version of sdcc instead of installed version
4518         * doc/sdccman.lyx: fixed typo in --nostdinc
4519
4520 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4521
4522         * src/pic/pcode.c,
4523         * src/pic/device.c,
4524         * src/pic/ralloc.c,
4525         * src/pic/gen.c : added support to generate code for struct bit fields.
4526
4527 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4528
4529         * as/xa51/xa_version.h,
4530         * device/include/errno.h,
4531         * device/include/regc515c.h,
4532         * device/lib/_itoa.c,
4533         * device/lib/_ltoa.c,
4534         * device/lib/ser_ir_cts_rts.c,
4535         * sim/ucsim/xa.src/glob.cc,
4536         * sim/ucsim/xa.src/inst_gen.cc,
4537         * sim/ucsim/xa.src/xa_bit.cc,
4538         * sim/ucsim/xa.src/xa_sfr.cc,
4539         * sim/ucsim/z80.src/inst_dd.cc,
4540         * sim/ucsim/z80.src/inst_fdcb.cc,
4541         * support/scripts/keil2sdcc.pl,
4542         * src/pic16/pic16.dsp,
4543         * src/pic16/pic16a.dsp: corrected cvs line endings
4544         * device/lib/printf_large.c: fixed bug 1057979
4545         * src/pic16/gen.c: fixed non-C standard code
4546         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4547         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4548         * support/regression/ports/mcs51/support.c: reload T1 asap
4549         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4550           pdata use and clear idata startup behaviour
4551         * support/regression/tests/bug1057979.c: added
4552
4553 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4554
4555         * device/examples/ds390/ow390/ad26.h,
4556         * device/examples/ds390/ow390/cnt1d.h,
4557         * device/examples/ds390/ow390/crcutil.c,
4558         * device/examples/ds390/ow390/ownet.h,
4559         * device/examples/ds390/ow390/owsesu.c,
4560         * device/examples/ds390/ow390/swt12.h,
4561         * device/examples/ds390/ow390/swtoper.c,
4562         * device/examples/ds390/ow390/temp10.h,
4563         * device/examples/ds390/ow390/thermodl.c,
4564         * device/examples/ds390/tinitalk/tinitalk.dsp,
4565         * device/examples/ds390/tinitalk/tinitalk.dsw,
4566         * device/examples/mcs51/clock/hw.h,
4567         * device/examples/mcs51/simple2/go.bat,
4568         * device/examples/serialcomm/windows/serial.h,
4569         * device/examples/xa51/dummy.c,
4570         * device/examples/xa51/hello.c,
4571         * device/include/80c51xa.h,
4572         * device/include/at89x051.h: corrected cvs line endings
4573
4574 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4575
4576         * src/pic16/main.c (options): added command line --gstack, to trace
4577         stack over/under flows,
4578         * added pragma 'wparam' to allow passing first byte of function
4579         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4580         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4581         call to __gstack_test function and sets up the symbol as extern,
4582         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4583         * popaop): added call to pic16_testStackOverflow,
4584         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4585         wparamList list,
4586         * (genCall, genPcall): now all parameters are passed via stack
4587         except in functions that are pass to wparam pragma in which WREG is
4588         used too,
4589         * (genPcall): REENTRANT flag is checked to see if variable prototype
4590         contains reentrant keyword, don't call a non-reentrant function, via
4591         a reentrant function pointer or vice versa, functions are never
4592         passed via WREG,
4593         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4594         D.Winkler,
4595         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4596         SIGSEGV when accessing a NULL register stucture,
4597         * (pic16_printGPointerType): modified to handle UPPER modifier for
4598         function initializers, changed prototype of function to simpler one,
4599         * (pic16_printIvalFuncPtr): check to see if function is already
4600         added in externs list,
4601         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4602         optimized a move from W to SFR with a move to the same register
4603         later after a CALL,
4604         * device/lib/pic16/debug: NEW directory, contains debug features
4605         which are enabled when linking with libdebug.lib, currently command
4606         line option --gstack enables stack pointer tracing for over/under
4607         flow, corresponding sources are in debug/gstack
4608
4609 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4610
4611         * doc/sdccman.lyx: updated SDCC version,
4612         * (PIC16 port): update list of command line options,
4613         * src/pic16/device.h (structure pic16_options_t): added field gstack
4614         to enable stack overflow tracing on push/pops,
4615         * src/pic16/device.c (statistics structure): added statistics
4616         structure,
4617         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4618         pic16_dump_int_registers): increase statistics counters for each
4619         * variable which is encountered
4620         * (pic16_dump_usection): emit each .udata variable to its own udata
4621         section,
4622         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4623         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4624         parameters via stack, otherwise use old scheme,
4625         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4626         assembler output file,
4627         * src/pic16/main.c: added command line options --gstack to enable
4628         push/pop tracing for stack overflow,
4629         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4630         instructions): added size of each instruction,
4631         * (pic16_countInstruction): estimate size of instructions in
4632         the_pFile list, inline assembly blocks are not counted,
4633         * (pic16_FixRegisterBanking): trace previous register usage, when
4634         banksel optimizations is greater than 0, don't emit a redudant
4635         banksel directive,
4636
4637 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4638
4639         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4640         * src/pic16/ralloc.c : applied same fix for pic16.
4641         * src/pic/gen.c : tidied it up a little.
4642
4643 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4644
4645         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4646         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4647
4648 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4649
4650         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4651
4652 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4653
4654         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4655         non-reentrant function __modsint in the interrupt function (thus
4656         corrupting math operations during serial I/O)
4657         * device/lib/ser_ir.c: as above, changed buffersize
4658         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4659         256.c,d for zeroing
4660         * doc/Makefile: added option -t for rsync
4661
4662 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4663
4664         * src/SDCCast.h (struct ast),
4665         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4666
4667 2004-10-20 Borut Razem <borut.razem AT siol.net>
4668
4669         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4670         package
4671
4672 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4673
4674         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4675         makefile targets,
4676         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4677         support functions to replace long sequences of MOVFF's from access
4678         bank registers to stack and vice versa,
4679         * src/pic16/device.h: added new field opt_flags, where optimization
4680         flags can be set to enable certain features,
4681         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4682         * pBlock, (genFunction, genEndFunction): surroung loop for
4683         saving/loading used registers in stack with PC_INFO pCodes,
4684         INF_LREGS. Code in between can then be optimized by pCode optimizer
4685         to support function calls,
4686         * (genDataPointerSet): fixed bug which loaded float fields in
4687         structures with corrupt data,
4688         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4689         in a standard way debug info on stderr. Feature used for developing
4690         and debugging only,
4691         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4692         obsolete chunks of code,
4693         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4694         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4695         * pic16/src/pcode.c (pic16_newpCodeInfo,
4696         * (pic16_newpCodeOpLocalRegs),
4697         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4698         feature,
4699         * (pic16_pCodeConstString): printing of the initial value of a
4700         symbol as a comment is inhibited since parsing was already done by
4701         copyStr and output is corrupt,
4702         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4703
4704 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4705
4706         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4707
4708 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4709
4710         * as/mcs51/lkarea.c: removed old K&R style,
4711           (lnksect): changed check on boundary error,
4712           (lnksect2): changed check on boundary error,
4713           (lnksect2): extend XSTK to end of page if size = 1
4714         * as/mcs51/lkmain.c: removed old K&R style,
4715           (Areas51): create l_IRAM symbol
4716         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4717         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4718           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4719         * device/lib/_mullong.c: added version to be compiled with xstack
4720         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4721         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4722         * device/lib/mcs51/crtxstack.asm: fixed comment
4723         * src/SDCCglue.c: maxInterrupts defaults to 0,
4724           (emitMaps): added pdata,
4725           (createInterruptVect): (re)moved default,
4726           (glue): added pdata,
4727           (glue): moved __start__xstack to XSTK with default size 1
4728         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4729           and options.float_rent when options.stackAuto is set,
4730           (linkEdit): only write XDATA_NAME if provided on command line
4731         * src/SDCCmem.h,
4732         * src/SDCCmem.c: added pdata
4733         * src/port.h: added pdata_name to PORT
4734         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4735           (saveRegisters, unsaveRegisters): removed usage of B,
4736           (genMinus): fixed accumulator clash,
4737           (genJumpTab): added comment, this needs another look
4738         * src/mcs51/gen.c: added check for "B in use" paranoia,
4739           added pushB() and popB()
4740         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4741           chance
4742         * src/avr/main.c,
4743         * src/ds390/main.c,
4744         * src/hc08/main.c,
4745         * src/mcs51/main.c,
4746         * src/pic/main.c,
4747         * src/pic16/main.c,
4748         * src/xa51/main.c,
4749         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4750           added PSEG (PAG,XDATA) or NULL to port specifier
4751         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4752         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4753           (_mcs51_genInitStartup): removed __start__xstack equ,
4754           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4755         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4756         * src/z80/gen.c (_rleAppend): fixed warnings
4757         * support/regression/tests/zeropad.c: added pdata test
4758         * .version: bumped to 2.4.6
4759
4760 2004-10-17 Borut Razem <borut.razem AT siol.net>
4761
4762         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4763         as a part of nightly build
4764
4765 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4766
4767         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4768         WREG holds the first byte function parameters,
4769         * (aopForSym): take special case for symbols which are in FARSPACE
4770         but in CODESPACE too,
4771         * (assignResultValue): modified to take into account _G.useWreg,
4772         * (genCall): don't use wreg for parameter passing when function is
4773         declared as reentrant, too, added optimization INCF to stack
4774         pointer when stack parameter count is 1,
4775         * (genFunction, genEndFunction): refurnished and fixed to not using
4776         wreg for passing parameters when function has varargs or is
4777         reentrant, fixed bug with symbol name compare for generating
4778         functions in absolute address,
4779         * (pic16_storeForReturn): refurnished,
4780         * (genCmp): began writing a new version of the function, not ready
4781         yet, therefore it is disabled,
4782         * (genAssign): do not read code memory when assigning a function to
4783         a pointer function,
4784         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4785         array of characters, not pointer,
4786         * (pic16initialComments): in debug mode emit an .ident directive for
4787         the assembler,
4788         * (_process_pragma): emit a new warning type (internal to pic16)
4789         when setting stack to default length, emit a similar warning when
4790         placing a function at absolute address and address is not word aligned
4791         * (_pic16_parseOptions): added 'return TRUE' statement,
4792         * (_pic16_linkEdit): if compiling a source, then add the source's
4793         file object, first in the list of objects to link,
4794
4795 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4796
4797         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4798         * src/pic/main.c : removed VC warning.
4799         * src/pic/gen.c : changed comment.
4800
4801 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4802
4803         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4804         reference to a deprecated symbol _GPTRREG was causing failure to
4805         link. Thanks G. M. Gallant for the info.
4806
4807 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4808
4809         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4810         comments for Bugs item #954788.
4811
4812 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4813
4814         * src/pic16/device.c (pic16_dump_gsection,
4815         * pic16_groupRegistersInSection): handle symbols declared to be in
4816         access bank differently,
4817         * src/pic16/gen.c (struct _G): added field resDirect,
4818         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4819         send values read from stack directly to result and don't allocate
4820         temporary values,
4821         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4822         same registers,
4823         * (pic16_sameRegsOfs): NEW,
4824         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4825         free because they were not allocated from temporary pool,
4826         * pic16_popRegFromString): workaround to fix a problem with
4827         allocating variables twice or never,
4828         * (genGenPointerGet): using PRODL instead of FSR0H,
4829         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4830         instead of FSR0H,
4831         * (genAssign): take advantage of the _G.resDirect flag,
4832         * (genCast): around line 11844, use mov2f instead of directly
4833         MOVFF'ing between operands to account for literal values,
4834         * src/pic16/genutils.c: some new debug functions for gpsim have been
4835         added,
4836         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4837         float with integer part only,
4838         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4839         place variables in access bank
4840         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4841         updated sources to reflect recent changes in gen.c
4842
4843 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4844
4845         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4846         sources that searched for headers in installation path, now the
4847         device/include/pic16 is used,
4848         * src/pic16/glue.c (pic16glue),
4849         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4850         .line directives if not in debug mode, this suppresses assembler's
4851         warnings for ignored directives
4852
4853 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4854
4855         * src/port.h: made reset_regparms prototype void parameter explicit.
4856         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4857         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4858         * doc/sdccman.lyx: documented warning disabling and how to use
4859           printf_large to make it print floats.
4860         * device/include/stdbool.h: NEW
4861         * device/lib/_atof.c,
4862         * device/lib/_divuint.c,
4863         * device/lib/_divulong.c,
4864         * device/lib/expf.c,
4865         * device/lib/printf_large.c,
4866         * device/lib/sincosf.c,
4867         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4868         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4869           a completely reentrant lib.
4870
4871 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4872
4873         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4874         * device/include/pic16/stdio.h: fixed bug with colon
4875
4876 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4877
4878         * device/include/pic16/stdio.h,
4879         * device/include/pic16/stdlib.h,
4880         * device/include/pic16/math.h: NEW
4881         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4882         declared as _naked to reduce overhead
4883         * device/lib/Makefile.in (target port-specific-objects-pic16):
4884         changed * to *.* so to ignore the CVS directory,
4885         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4886         stacked variables back in stack,
4887         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4888         corruption
4889
4890 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4891
4892         * .version: bumped version number to 2.4.5
4893         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4894         * support/Util/SDCCerr.c (messages structure): added entry for
4895         W_POSSBUG2
4896
4897         Large cumulative patch for pic16 port and libraries.
4898         * device/include/pic16/sdcc-lib.h,
4899         * device/include/pic16/stdarg.h,
4900         * device/include/asm/pic16/features.h,
4901         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4902         * device/include/pic16/float.h: changes reentrant keyword with
4903         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4904         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4905         updated target build-libraries to include objects from gptr,
4906         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4907         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4908         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4909         all function headings,
4910         * src/SDCCmain.c: added global parameter userIncDirsSet,
4911         * (parseCmdLine): when option -I is encountered add directory to
4912         userIncDirsSet too,
4913         * src/version.awk: added space between control and long,
4914         * src/pic16/NOTES: added some notes for the port,
4915         * src/pic16/gen.c: added prototype for mov2fp function,
4916         * (fReturnpic16[]): properly named return value registers,
4917         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4918         * (aopForSym): added code to handle symbols with onStack flag set,
4919         symbols onStack are allocated PTRSIZE bytes,
4920         * (aopFreeAsmop): handles special case where asmops are stack objects,
4921         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4922         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4923         added argument lock to trace flaws in allocating temporary registers
4924         when developing port,
4925         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4926         * (pic16_popRegFromString): reenabled allocating a direct register
4927         from string,
4928         * (assignResultValue): various beautifications,
4929         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4930         referenced function argument,
4931         * (genIpush): reenabled to allow stacked arguments, handles only
4932         ic->parmPush iCodes,
4933         * (genCall, genPcall): major changes to allow for variable argument
4934         functions, fixed a bug with falsely restoring stack pointer after
4935         returning from call,
4936         * (genFunction): pending code for critical function,
4937         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4938         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4939         * (genNearPointerGet): fixed bug with indirect reading, was always
4940         reading from INDF0
4941         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4942         pointers,
4943         * (genAddrOf): rewrote code to take address of a stacked function parameter
4944         * (genCast): fixed casting to generic pointer type,
4945         * src/pic16/gen.h: added AOP_STA,
4946         * (struct asmop): added field stk,
4947         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
4948         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
4949         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
4950         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
4951         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
4952         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
4953         generic pointers,
4954         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
4955         and library paths,
4956         * (pic16_port structure): generic pointer size is set to 3,
4957         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
4958         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
4959         compiler warning,
4960         * src/pic16/ralloc.c (allocReg): prevent allocating register when
4961         operand is an iTemp,
4962
4963 2004-09-24 Martin Helmling <mh AT octo-soft.de>
4964
4965         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
4966         * debugger/mcs51/simi.c: addapt new syntax of s51
4967
4968 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
4969
4970         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
4971         * src/pic16/pcode.c: commented out some calls to free() in order to
4972         fix bug #989576,
4973
4974 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4975
4976         * src/SDCCicode.h,
4977         * src/SDCCicode.c (isiCodeInFunctionCall),
4978         * src/avr/ralloc.c (selectSpil),
4979         * src/pic/ralloc.c (selectSpil),
4980         * src/pic16/ralloc.c (selectSpil),
4981         * src/ds390/ralloc.c (selectSpil),
4982         * src/hc08/ralloc.c (selectSpil),
4983         * src/xa51/ralloc.c (selectSpil),
4984         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
4985         stack in the middle of a function call sequence (fixes bug #1020268)
4986         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
4987         costs associated with the minimum switch case.
4988
4989 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4990
4991         * src/SDCC.lex: fixed bug #1030549
4992
4993 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4994
4995         * src/SDCCcse.h (struct cseDef),
4996         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
4997         over a function call if the CSE is derived from a symbol whose
4998         address has been taken (fixes bug #1029883)
4999         * support/regression/tests/bug-1029883: a new regression test for
5000         this bug
5001
5002 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5003
5004         * src/hc08/gen.c (emitinline): fixed bug #1029778
5005         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
5006         to a cast object is no longer a syntax error ("fixes" bug #1030006,
5007         and starts toward RFE #905167)
5008
5009 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
5010
5011         * src/pic16/gen.c (mov2f): New function to move an operand to
5012         another without considering if it is a literal or a register,
5013         * (pic16_sameRegs): don't check if they are both AOP_REG,
5014         * (AccRsh): removed andmask=0 lines,
5015         * (genLeftShift): duplicated to be improved in future versions,
5016         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
5017         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
5018         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
5019         * (pic16initMnemonics): added initialization for POC_INFSNZW,
5020         * (insertBankSwitch): fixed inserting banksel directives algorithm
5021         for instructions that follow a skip instruction, this fixes a report
5022         for broken subtraction code generation,
5023         * src/pic16/ralloc.c (deassignLRs): do not free register if current
5024         iCode is a left op, just in case result and right share the same
5025         registers
5026
5027 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5028
5029         * src/hc08/main.c,
5030         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
5031         preservation of HX
5032         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
5033         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
5034         on 2004-09-12; it was buggy
5035
5036 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
5037
5038         * src/SDCCsymt.h: removed RESULT_CHECK
5039         * src/SDCCast.c,
5040         * src/SDCCglue.c,
5041         * src/SDCCval.c,
5042         * src/pic/glue.c,
5043         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
5044
5045 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
5046
5047         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
5048         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
5049         configuration values no more rejected by compiler, they are assigned
5050         to configuration registers with a warning message instead,
5051         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
5052         the for-loop so last conf register is emitted too,
5053         * (_pic16_initPaths): link library libsdcc.lib by default,
5054         * (_hasNativeMulFor): modified test for multiplication according to
5055         Raphael Neider's remarks. Integer multiplication is also done with
5056         support functions,
5057         * device/include/pic16/pic18fregs.h: corrected type error in while
5058         testing and including 18f6720 header file
5059
5060 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
5061
5062         * src/pic16/device.h (pic16_options): removed field use_crt,
5063         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
5064         until an optimization to handle single bits is added,
5065         * (pic16_loadFSR0): moved before genUnpackBits,
5066         * (genAnd): some white lines removed,
5067         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
5068         leave_reset flags in pic16_options when using crt modules,
5069
5070 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
5071
5072         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
5073           for bugs 898889 & 979599. Also used some safer print instructions.
5074
5075 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
5076
5077         * src/pic16/device.h (pic16_options_t): added field use_crt,
5078         crt_name, no_crt,
5079         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
5080         catch a probable future bug,
5081         * src/pic16/gen.c: aopIdx function commented out,
5082         * (genAssign): commented out old code which used aopIdx,
5083         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
5084         code, added if conditionals to take into account the --use-crt
5085         command line options,
5086         * src/pic16/main.c (pic16_optionsTable): added new command line
5087         options, --use-crt= and --no-crt,
5088         * (_pic16_linkEdit): now the proper crt object is added in the
5089         linker command line except than when --no-crt is specified,
5090         * src/pic16/pcode.c,
5091         * src/pic16/pcode.h: added some structures and functions for a new
5092         optimization scheme to compansate for instruction overhead between
5093         same iCodes, this scheme is currently under development and is not
5094         working in any way,
5095         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
5096         to && operator,
5097         * device/lib/pic16/startup/crt0i.c,
5098         * device/lib/pic16/startup/crt0iz.c: added global char variable
5099         __uflags to force the generation of an idata section
5100
5101 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
5102
5103         * doc/Makefile,
5104         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
5105         * doc/sdccman.lyx: updated sdcc version to 2.4.4
5106
5107 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5108
5109         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
5110         Frieder) and clarified the default code optimization mode
5111
5112 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5113
5114         * src/SDCC.lex (doPragma, process_pragma),
5115         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
5116         "opt_code_size", and "opt_code_balanced"
5117         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
5118         regrouped options by category, added support for category headers
5119         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
5120         and "--opt-code-size"
5121         * doc/sdccman.lyx: documented these new options and pragmas
5122         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
5123         preference into account
5124
5125 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5126
5127         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
5128           geniCodePreDec): Fixed bug 904237 by generating a warning
5129         * src/SDCCerr.h,
5130         * src/SDCCerr.c: added warning W_SIZEOF_VOID
5131
5132 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
5133
5134         * src/pic/device.c : When no max ram set validate full memory range.
5135         * src/pic/pcode.c,
5136         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
5137
5138 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5139
5140         * device/lib/_gptrget.c,
5141         * device/lib/_gptrput.c: updated comment
5142         * device/lib/calloc.c,
5143         * device/lib/free.c,
5144         * device/lib/malloc.c,
5145         * device/lib/realloc.c: added LGPL, made them reentrant-safe
5146         * src/SDCCcse.c (cseBBlock),
5147         * src/SDCCicode.c (printOperand, geniCodeArray),
5148         * src/SDCCicode.h (struct operand): fixed bug 868103
5149         * support/regression/tests/bug-868103.c: added
5150         * src/SDCCast.c (searchLitOp),
5151         * src/SDCCcse.h (struct cseDef),
5152         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
5153         * src/SDCCicode.h (struct operand),
5154         * src/SDCCsymt.h (struct sym_link),
5155         * src/avr/gen.c (hasInc),
5156         * src/ds390/gen.c (hasInc),
5157         * src/hc08/gen.c (genPlusIncr, hasInc),
5158         * src/mcs51/gen.c (hasInc),
5159         * src/pic16/glue.c (pic16_printIvalChar),
5160         * src/pic16/ralloc.c (regWithIdx),
5161         * src/xa51/gen.c (hasInc) : removed warnings
5162         * src/SDCCast.c (createBlock): added comment ???
5163         * src/hc08/ralloc.c: updated comments
5164
5165 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5166
5167         * doc/sdccman.lyx: updated section on switch statements, added
5168         section about semaphore locking
5169         * doc/Makefile: added option -info for latex2html
5170         * device/lib/_gptrget.c,
5171         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
5172
5173 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5174
5175         * src/pic/device.h,
5176         * src/pic/device.c,
5177         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
5178          maxram is less than 0x100.
5179
5180 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5181
5182         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
5183
5184 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5185
5186         * src/port.h,
5187         * src/mcs51/main.c,
5188         * src/ds390/main.c,
5189         * src/z80/main.c,
5190         * src/hc08/main.c,
5191         * src/pic/main.c,
5192         * src/pic16/main.c,
5193         * src/avr/main.c,
5194         * src/xa51/main.c
5195         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
5196         a jump table is the best form for a switch statement, including
5197         automatic insertion of missing cases to make the case range
5198         continuous. Developed in collaboration with Frieder Ferlemann.
5199
5200 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5201
5202         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
5203         accumulator result if it needs sign extension
5204
5205 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5206
5207         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
5208
5209 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5210
5211         * device/lib/gbz80/printf.c,
5212         * device/lib/z80/printf.c: removed define for NULL
5213
5214 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5215
5216         * as/xa51/xa_link.c,
5217         * device/examples/ds390/ow390/ad26.c,
5218         * device/examples/ds390/ow390/cnt1d.c,
5219         * device/examples/ds390/ow390/counter.c,
5220         * device/examples/ds390/ow390/ds2480.h,
5221         * device/examples/ds390/ow390/ds2480ut.c,
5222         * device/examples/ds390/ow390/findtype.c,
5223         * device/examples/ds390/ow390/gethumd.c,
5224         * device/examples/ds390/ow390/owllu.c,
5225         * device/examples/ds390/ow390/ownetu.c,
5226         * device/examples/ds390/ow390/swt12.c,
5227         * device/examples/ds390/ow390/swtloop.c,
5228         * device/examples/ds390/ow390/temp.c,
5229         * device/examples/ds390/ow390/temp10.c,
5230         * device/examples/ds390/ow390/thermo21.c,
5231         * device/examples/ds390/ow390/tinilnk.c,
5232         * device/examples/ds390/ow390/tstfind.c,
5233         * device/examples/serialcomm/windows/serial.cpp,
5234         * device/examples/serialcomm/windows/test_serialcomm.cpp,
5235         * device/include/reg51.h: fixed line endings for cvs
5236
5237 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5238
5239         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
5240         packRegsForAccUse, packRegisters): new accumulator register
5241         packing algorithm
5242         * support/regression/ports/hc08/support.c (_putchar): suppress
5243         warning of unused variable
5244         * src/SDCCicode.c: added SWAP entry to codeTable
5245
5246 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
5247
5248         * device/lib/sprintf.c: forgot to add this file before previous commit
5249
5250 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
5251
5252         * src/pic16/gen.c (genPackBits): added operand right in function
5253         parameters, load result directly if p_type is POINTER (that is
5254         called by genNearPointerSet)
5255         * (genUnPackBits): added operand left in function parameters,
5256         * (genNearPointerGet, genNearPointerSet): prevent the loading of
5257         FSR0 if accessing bitfields,
5258
5259 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
5260
5261         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
5262           _print_format; updated printf, sprintf, vsprintf
5263         * device/include/asm/default/features.h: corrected comment/define
5264         * device/lib/Makefile.in: added sprintf.c
5265         * device/lib/libsdcc.lib: added sprintf module
5266         * device/lib/printf_large.c,
5267         * device/lib/vprintf.c,
5268         * device/lib/sprintf.c: totally refactored printf_large and vprintf
5269           into these 3 files
5270         * support/regression/Makefile: changed ALL_PORTS into a usefull default
5271         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
5272         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
5273           hc08 test
5274         * support/regression/tests/zeropad.c: define idata as data for hc08
5275
5276 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5277
5278         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
5279         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
5280         labels are referenced at least once (even if a reference is not found)
5281         * src/hc08/gen.c (emitcode): set isComment flag for comments
5282         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
5283         loads), rules 6a..6b (optimize jumps to return)
5284
5285 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5286
5287         * device/lib/acosf.c (acosf),
5288         * device/lib/asinf.c (asinf),
5289         * device/lib/atanf.c (atanf),
5290         * device/lib/ceilf.c (ceilf),
5291         * device/lib/cosf.c (cosf),
5292         * device/lib/coshf.c (coshf),
5293         * device/lib/cotf.c (cotf),
5294         * device/lib/fabsf.c (fabsf),
5295         * device/lib/floorf.c (floorf),
5296         * device/lib/log10f.c (log10f),
5297         * device/lib/logf.c (logf),
5298         * device/lib/sinf.c (sinf),
5299         * device/lib/sinhf.c (sinhf),
5300         * device/lib/sqrtf.c (sqrtf),
5301         * device/lib/tanf.c (tanf),
5302         * device/lib/tanhf.c (tanhf),
5303         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
5304         replaced all instances of "reentrant" in the library functions
5305         defined in math.h with this macro.
5306         * support/regression/tests/float_trans.c: reenabled test for hc08
5307
5308 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
5309
5310         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
5311         erroneously deleted
5312
5313 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5314
5315         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
5316         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
5317         multi-byte volatile operands are used
5318         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
5319         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
5320         initialization to area GSINIT0 so that it would always precede
5321         any static initializers in GSINIT
5322         * support/regression/tests/zeropad.c: fixed idata define for hc08
5323         * support/regression/tests/bug-927659.c,
5324         * support/regression/tests/float_trans.c: disabled tests for hc08
5325         pending missing library routines
5326         * .version: increased version number to 2.4.4 - hc08 port now passes
5327         regression tests
5328
5329
5330 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
5331
5332         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
5333         * Makefile.common.in,
5334         * as/Makefile,
5335         * as/hc08/Makefile.in,
5336         * as/mcs51/Makefile.in,
5337         * as/z80/Makefile.in,
5338         * debugger/mcs51/Makefile.in,
5339         * device/include/Makefile.in,
5340         * device/lib/Makefile.in,
5341         * doc/Makefile,
5342         * link/Makefile,
5343         * link/z80/Makefile.in,
5344         * packihx/Makefile.in,
5345         * sim/ucsim/main_in.mk,
5346         * sim/ucsim/avr.src/Makefile.in,
5347         * sim/ucsim/doc/Makefile.in,
5348         * sim/ucsim/gui.src/serio.src/Makefile.in,
5349         * sim/ucsim/hc08.src/Makefile.in,
5350         * sim/ucsim/s51.src/Makefile.in,
5351         * sim/ucsim/xa.src/Makefile.in,
5352         * sim/ucsim/z80.src/Makefile.in,
5353         * src/Makefile.in,
5354         * support/cpp2/Makefile.in,
5355         * support/librarian/Makefile,
5356         * support/makebin/Makefile: added DESTDIR to the install path proposed
5357         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
5358         * doc/sdccman.lyx: added DESTDIR documentation
5359
5360 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
5361
5362         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
5363         instruction for interrupt handlers, use fast returns when returning
5364         from high priority interrupts
5365
5366 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5367
5368         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
5369         code generation
5370         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
5371         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
5372         bugs, ported much of Bernhard's code from mcs51
5373         * src/mcs51/gen.c (genSend),
5374         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
5375         than one when calling a reentrant function
5376         * device/lib/_mullong.c: defined an alternate struct layout for big
5377         endian ports (hc08)
5378
5379 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5380
5381         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
5382         test
5383
5384 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5385
5386         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
5387         are sane and complete before asking the port its prefered parameter
5388         passing method (fixes bug #1017633)
5389         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
5390         and _ret3
5391
5392 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5393
5394         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
5395         problem in bitfields >= 8 bits.
5396
5397 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5398
5399         * src/SDCCsymt.c: undid changes that were not meant to be committed
5400
5401 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5402
5403         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
5404
5405 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5406
5407         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
5408           copied and wrong bit got inverted
5409
5410 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5411
5412         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5413         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5414         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5415         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5416         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5417         assignments to bitfields at known addresses
5418         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5419         reads from bitfields at known addresses
5420         * src/hc08/ralloc.c (packRegisters),
5421         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5422         genhc08Code): optimize pointer get values used as conditionals
5423         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5424         and branch
5425
5426 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5427
5428         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5429         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5430         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5431         as conditionals
5432
5433 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5434
5435         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5436
5437 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5438
5439         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5440         related problems
5441
5442 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5443
5444         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5445
5446 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5447
5448         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5449         mcs51 port
5450
5451 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5452
5453         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5454
5455 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5456
5457         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5458         cases use more compact code.
5459
5460 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5461
5462         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5463
5464 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5465
5466         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5467
5468 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5469
5470         * src/SDCCsymt.h,
5471         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5472         parameter of changePointer() from symbol* to sym_link*
5473         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5474         * src/SDCCsymt.c (compareType): void* type is castable to other
5475         pointers, but not necesarily an exact match.
5476         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5477         is no longer blindly treated as an exact match.
5478         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5479
5480 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5481
5482         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5483
5484 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5485
5486         * src/pic/gen.c,
5487         * src/pic/pcode.c,
5488         * src/pic/ralloc.h,
5489         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5490
5491 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5492
5493         * src/pic/device.c,
5494         * src/pic/device.h,
5495         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5496
5497 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5498
5499         * src/mcs51/gen.c (emitcode): fixed bug #992819
5500
5501 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5502
5503         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5504           there's no need to make it worse
5505
5506 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5507
5508         * src/mcs51/ralloc.c (deassignLR),
5509         * src/ds390/ralloc.c (deassignLR),
5510         * src/hc08/ralloc.c (deassignLR),
5511         * src/z80/ralloc.c (deassignLR),
5512         * src/pic/ralloc.c (deassignLR),
5513         * src/pic16/ralloc.c (deassignLR),
5514         * src/avr/ralloc.c (deassignLR),
5515         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5516         rlivePoint): fixed another part of bug #971834
5517
5518 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5519
5520         * src/z80/main.c: enabled "critical" keyword
5521         * src/z80/mappings.i,
5522         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5523         functions (fixes bug #979646)
5524         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5525
5526 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5527
5528         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5529           such as c:\mydir.
5530
5531 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5532
5533         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5534           doesn't disable too much optimizations
5535
5536 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5537
5538         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5539
5540 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5541
5542         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5543
5544 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5545
5546         * src/pic/gen.c tidied up tabs
5547         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5548         * src/pic/main.c tidied up tabs
5549         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5550         * src/pic/pcoderegs.c tidied up tabs
5551         * src/pic/ralloc.c tidied up tabs
5552
5553 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5554
5555         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5556         to S_FIXED for pic16 port and when symbol is not in level 0,
5557         allocate for S_REGISTER storage class and pic16 port, too,
5558         * src/pic16/device.h: prototype for checkSym,
5559         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5560         * (pic16_assignConfigWordValue): test the value and the mask to
5561         validate that the value is suitable for the configuration word,
5562         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5563         collect extern declared symbols, don't emit symbol twice, check
5564         first if symbol is in publics set first,
5565         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5566         * added command line '--fstack' which enables an experimental
5567         feature for stack access, too buggy to be used yet...
5568         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5569         * (pic16_allocDirReg): when register has storage class S_REGISTER
5570         allocate in pic16_dynAccessRegs,
5571         * device/include/pic16/pic18f????.h: modified configuration word
5572         naming convention, words started as CONFIG0H but should be CONFIG1H
5573
5574 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5575
5576         * device/include/mcs51reg.h: fixed bug 970993
5577
5578 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5579
5580         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5581         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5582         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5583         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5584         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5585         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5586           error/warning numbers,
5587           added function setWarningDisabled()
5588         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5589         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5590           _memcmp.c _memmove.c calloc.c realloc.c free.c
5591         * support/regression/tests/malloc.c: added tests for new functionality
5592         * support/regression/tests/zeropad.c: added tests for truncated initializers
5593           and initialized char arrays starting with '\x0'
5594         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5595
5596 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5597
5598         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5599
5600 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5601
5602         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5603         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5604         peephole 177.e. Thanks to anonymous
5605
5606 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5607
5608         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5609         function isn't used in the source but referenced as a
5610         variable initializer then declare it as extern in .asm file
5611
5612 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5613
5614         * .version: increased version number to 2.4.3
5615
5616         Adding version extension according to ChangeLog CVS revision
5617         * src/Makefile.in (target all): added dependency 'version.h'
5618         * (rule version.h): added rule to create version.h from ChangeLog,
5619         * (rule dep): added dependency version.h,
5620         * src/version.awk: AWK script to create version.h
5621         * src/SDCCdwarf2.c (dwWriteModule),
5622         * src/SDCCglue.c (initialComments),
5623         * src/SDCCmain.c (printVersionInfo): modified to write after
5624         version string the version extension number,
5625         * src/SDCCutil.c: included "version.h"
5626         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5627         number,
5628         * src/SDCCutil.h: added prototype for getBuildNumber
5629
5630         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5631         includeDirsSet, too,
5632         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5633         const char [] is found in function prototype...
5634
5635         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5636         moving to WREG with source is already in WREG,
5637         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5638         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5639         * (aopForSym): stack'ed symbols are partially supported, added
5640         if-clause to support symbols in FARSPACE,
5641         * (sameRegs): added test for AOP_ACC to see if registers are same,
5642         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5643         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5644         * (pic16_popRegFromString): will not allocate a new register if it
5645         doesn't find one by name, bug may have introduced...
5646         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5647         * (genIpush): revived to use pic16 port's stack,
5648         * (genAddrOf): added incomplete case for stack'ed operand,
5649         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5650         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5651         can handle multibyte operands,
5652         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5653         * (pic16initialComments): added message for MPLAB compatibility
5654         mode enabled,
5655         * src/pic16/main.h: prototype for pic16_mplab_comp,
5656         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5657         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5658         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5659         because of increased complexity of procedure,
5660         * (_process_pragma): stack pragma changed to format 'stack pos len',
5661         emit symbol '_stack_end' to conform with gplink,
5662         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5663         to search for register,
5664         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5665         PO_GPR_REGISTER,
5666         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5667         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5668         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5669         case for PO_GPR_REGISTER,
5670         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5671         dies, the new era is ahead !...
5672         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5673         pic16_dynInternalRegs,
5674         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5675         * (pic16_allocDirReg): minor optimizations and bug fixes,
5676         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5677
5678         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5679         load stack and frame pointer with address of 'stack_end' symbol
5680
5681 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5682
5683         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5684         without source code but only variable initializers
5685
5686 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5687
5688         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5689         external are not declared as extern to reduce overhead while linking
5690
5691 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5692
5693         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5694
5695 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5696
5697         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5698           Yee Keat for the patch
5699         * src/SDCCast.c (decorateType): fixed bug #979599
5700         * src/ds390/gen.h: removed local fReturnSizeDS390
5701         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5702         * src/ds390/gen.c (genAnd, genOr, genXor),
5703         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5704
5705 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5706
5707         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5708         add relFilesSet to $3, manipulate $2 to handle linking of object
5709         files without source files in command line,
5710         * device/include/pic16 (all headers): added ID location macros,
5711         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5712         entries for ID location bytes,
5713         * (pic16_assignIdByteValue): NEW,
5714         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5715         added field dumpcalltree to pic16_options_t,
5716         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5717         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5718         emitting rFalseIfx label after check_carry label,
5719         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5720         pic16_emitDIRegs), NEW
5721         * (pic16glue): dump .calltree file when option --calltree found,
5722         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5723         * (_pic16_genAssemblerPreamble): emit ID locations after
5724         configuration registers,
5725         * (pic16_linkCmd): modifications of the link command,
5726         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5727         * (pic16_pCodeInitRegisters): don't init stack registers,
5728         * (pic16_findPrevInstruction): fixed bug,
5729         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5730         bug with immediate registers,
5731         * (buildCallTree): traces stack push and pop,
5732         * (pct2): dump also stack usage for each function,
5733         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5734         * (pic16_allocDirReg): various modifications,
5735         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5736         fixed to 1,
5737
5738 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5739
5740         * src/pic16/pcode.c: removed buggy double colon
5741
5742 2004-07-01 Borut Razem <borut.razem AT siol.net>
5743
5744         * support/scripts/sdcc.nsi: added include/pic16 to setup
5745
5746 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5747
5748         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5749         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5750         target 'clean',
5751         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5752         specific command line arguments. Also added sample lkr script
5753         for placing a variable at a specific memory bank.
5754         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5755         at a specific memory bank,
5756         * (pic16_dump_isection): fixed bug which caused string literals to
5757         be omitted when dumping idata section,
5758         * (pic16_groupRegistersInSection): added code to handle registers
5759         in specific memory banks,
5760         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5761         public, all references are renamed too,
5762         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5763         AOP_DPTR2,
5764         * (pic16_storeForReturn): added case to handle when dest is WREG,
5765         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5766         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5767         pic16_rel_udata, check to see if that register is marked as being
5768         a member of a specific memory bank,
5769         * (pic16_printIvalCharPtr): added code to add string literals either
5770         to code or the idata sections,
5771         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5772         also accept the 'udata' pragma,
5773         * src/pic16/main.h: new structure types sectName and sectSym
5774         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5775         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5776         * (pic16_findPrevInstruction): fixed, it returned nothing,
5777         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5778         instruction combinations,
5779         * (pic16_FixRegisterBanking): heavily reorganised,
5780         * (pic16_AnalyzeBanking): if generating banksel directives is
5781         disabled, then don't call FixRegisterBanking at all,
5782         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5783         completely removed,
5784         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5785
5786 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5787
5788         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5789         Phuah Yee Keat <yk.phuah AT nestac.com>
5790
5791 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5792
5793         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5794         correctly the IVT even if it is relocated to some other location
5795
5796 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5797
5798         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5799         * device/include/pic16/pic18f2220.h: NEW,
5800         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5801         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5802         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5803         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5804         nodefaultlibs, ivt_loc is the location of the interrupt vector
5805         table, and nodefaultlibs signs that default libraries should not be
5806         linked in link stage,
5807         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5808         according to --ivt-loc argument,
5809         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5810         when pragma stack is found,
5811
5812 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5813
5814         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5815         256 (range check), 257 (do while), 258.a-f (bit banging
5816         f.e. on 3-wire SPI bus)
5817
5818 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5819
5820         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5821         variables used exclusively within a loop
5822
5823 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5824
5825         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5826
5827 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5828
5829         * src/SDCClrange.c (computeClash): fixed bug #971834
5830
5831 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5832
5833         * src/mcs51/gen.c (genCmp): fixed bug #975903
5834         * src/hc08/gen.c (operandsEqu),
5835         * src/ds390/gen.c (operandsEqu),
5836         * src/z80/gen.c (operandsEqu),
5837         * src/pic/gen.c (operandsEqu),
5838         * src/pic16/gen.c (operandsEqu),
5839         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5840         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5841
5842 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5843
5844         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5845
5846 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5847
5848         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5849         default case in switch statement,
5850         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5851         to eliminate problem with initialisation of pointers, but problem
5852         still exists,
5853         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5854         * (emitStaticSegment): removed various lines emitting debug info,
5855         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5856         added processor registers for utilizing EEPROM,
5857         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5858         configurable and set 8
5859
5860 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5861
5862         * .version: increased version number to 2.4.2,
5863
5864         Cumulative patch for pic16 port
5865         * src/pic16/device.c: changed scheme to dump initial values for
5866         variables in idata segment, all print_idata* functions were removed,
5867         now the pic16_printIval* will be called,
5868         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5869         * _pic16_printPointerType, pic16_printPointerType,
5870         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5871         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5872         NEW, similar to the respective functions in SDCCglue.c,
5873         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5874         way, emitting hex bytes,
5875         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5876
5877 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5878
5879         * src/avr/ralloc.c (serialRegAssign),
5880         * src/xa51/ralloc.c (serialRegAssign),
5881         * src/pic/ralloc.c (serialRegAssign),
5882         * src/pic16/ralloc.c (serialRegAssign),
5883         * src/hc08/ralloc.c (serialRegAssign),
5884         * src/z80/ralloc.c (serialRegAssign),
5885         * src/ds390/ralloc.c (serialRegAssign),
5886         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5887
5888 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5889
5890         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5891         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5892
5893 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5894
5895         Cumulative patch for pic16 port:
5896         * src/pic16/device.h (typedef PIC16_device) modified fields for
5897         defining microcontrollers,
5898         * src/pic16/device.c: added new info for all devices in Pics16 array,
5899         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5900         to be optimised out by the pCode optimiser,
5901         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5902         specially, bug reported by G.M. Gallant,
5903         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5904         as force'd so that cannot be optimised out by pCode optimiser,
5905         * src/pic16/pcode.c,
5906         * src/pic16/pcodepeeph.c,
5907         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5908         they are disabled by default, but can be enabled explicit with
5909         command argument --denable-peeps, for testing,
5910         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5911         --pomit-ivt in COMPILE_FLAGS
5912
5913 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5914
5915         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5916           compilation on MSVC
5917
5918 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5919
5920         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5921
5922 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5923
5924         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5925         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5926
5927 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5928
5929         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5930         would only assign 0x300001 register.
5931
5932 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5933
5934         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5935         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5936
5937 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5938
5939         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5940         for ds80c400
5941         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5942         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5943         added peephole 254 (left shift), 255 (jump table)
5944
5945 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
5946
5947         * device/lib/Makefile.in: removed comment line with model-pic16,
5948         * (target port-specific-objects-pic16): the libraries and objects
5949         are copied to the build directory form the device/lib/pic16/bin
5950         directory
5951
5952         Cumulative patch concerning pic16 port:
5953         * library directory has been re-organized,
5954         * added support for PIC18F1220,
5955         * added headers and library sources for chips 18f1220,18f6520,
5956         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
5957
5958         * configuration registers setting has changed, now each supported
5959         device has a complete description of the registers it uses,
5960         * all initialisations are moved to idata sections, these section
5961         can be absolute or relocatable,
5962         * fixed initialisation of codespace variables,
5963         * fixed warning about PCLATU and gpsim,
5964         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
5965         * (genAssign): use table reads when assigning from variables in codespace,
5966         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
5967         char/int variables placed in codespace,
5968         * (pic16_emitConfigRegs): NEW, emits a list with configuration
5969         registers set in .asm file, no need for --pomit-config-words anymore,
5970         * (pic16glue): some 8051 legacy segments are commented out
5971         (to be removed completely),
5972         * added support for alternative assembler and linker with --asm=
5973         and --link= command line arguments,
5974         * peepholes are disabled automatically in the port, no need to
5975         specify on command line,
5976         * port supports natively char/int/long multiplication, but converts
5977         all divisions to support functions,
5978         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
5979         to the file set in variable $2,
5980         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
5981         strings in ASCII format and not in hex,
5982         * ralloc.c (serialRegAssign): added a triplet of conditional calls
5983         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
5984         allocate proper register if iCodes aren't temporary,
5985
5986 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
5987
5988         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
5989
5990 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
5991
5992         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
5993         is commented out
5994
5995 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5996
5997         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
5998         computed address is reused
5999         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
6000         multi-byte bitfields
6001
6002 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6003
6004         * src/z80/gen.c: (genArrayInit): must check for pointers too
6005
6006 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6007
6008         * support/regression/tests/zeropad.c: never meant to commit the
6009           nestedstruct test: removed, added check for GCC version
6010
6011 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
6012
6013         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
6014         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
6015         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
6016           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
6017           bugs 928906 and 954082 half-empty initializers
6018         * src/SDCCsymt.h,
6019         * src/SDCCsymt.c (getAllocSize): added for above fix
6020         * src/z80/gen.c (genArrayInit): fixed bug 741044
6021         * support/regression/tests/zeropad.c: added tests
6022
6023 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
6024
6025         * src/pic16/device.c (pic16_dump_section): corrected bug which
6026         caused some symbols of the libraries to be misplaced
6027
6028 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6029
6030         * src/pic16/glue.c,
6031         * src/pic16/ralloc.h,
6032         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
6033         to fix conflict with pic port
6034
6035 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6036
6037         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
6038         externs configuration variables,
6039         * src/pic16/ralloc.h,
6040         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
6041         prototype in header, commented out some debug messages
6042
6043 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
6044
6045         * src/pic16/glue.c,
6046         * src/pic16/main.c,
6047         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
6048         for gpasm COFF object generation. Thanks to D. Hawkins for
6049         his patch info
6050
6051 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6052
6053         * src/ds390/main.c,
6054         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
6055         Brock for spotting this)
6056         * src/ds390/gen.c (genEndFunction),
6057         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
6058         interrupt handler and critical. Disable push/pop optimizations when
6059         peephole optimizations disabled.
6060
6061 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6062
6063         Updated pic16 library sources and headers.
6064         * device/lib/pic16/pic18f*/ ,
6065         * device/include/pic16/*.h: modified to handle structured SFR
6066         definitions
6067
6068 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6069
6070         * src/port.h (PORT structure): added hook initPaths, now each
6071         port can declare its own default search paths,
6072         which can been seen with the --print-search-dirs option,
6073         see pic16 port for example,
6074         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
6075         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
6076         * (doPrintSearchDirs): NEW, replaces in a central manner the
6077         printing of search dirs which was split in set*Paths functions,
6078         * (main): added call to port->initPaths and doPrintSearchDirs,
6079         * src/avr/main.c,
6080         * src/ds390/main.c,
6081         * src/hc08/main.c,
6082         * src/izt/i186.c,
6083         * src/izt/tlcs900h.c,
6084         * src/mcs51/main.c,
6085         * src/pic/main.c,
6086         * src/pic16/main.c: modified port structures to reflect addition of
6087         initPaths hook,
6088
6089         * src/pic16/device.c (regCompare): registers are finally sorted by name,
6090         * (pic16_dump_section): for registers in same address reserve memory once,
6091         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
6092         to no_banksel,
6093         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
6094         result is greater in size than right or left,
6095         * (pic16_genUMult8X8_8): there are some cases where the result can
6096         be 16 bits size, so handle these,
6097         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
6098         * (pic16_outBitC): modified to emit pcodes,
6099         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
6100         or not,
6101         * (genDivOneByte): implemented algorithm to divide 8-bits,
6102         * (genCmp): uncommented goto, but issues still exist,
6103         * (genAnd): fixed a bug with variables >8bits,
6104         * (genPackBits): optimization added that uses BCF/BSF to change a
6105         single bit,
6106         * (genAssign): fixed bug when assigning floating point literals,
6107         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
6108         __sdcc_gsinit_startup label,
6109         * src/pic16/main.c (_pic16_init): removed search directory
6110         initialisations,
6111         * (_pic16_initPaths): NEW, used to initialise search directories,
6112         * (_hasNativeMulFor): support functions for all except char/int
6113         multiplication, and char division,
6114         * (PIC16_port struct): modified entry for native mul support,
6115         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
6116         no_banksel option,
6117         * (buildCallTree): call to register_usage is ifdef'ed out,
6118
6119 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6120
6121         * device/include/string.h: applied Stas Sergeev's patch to make this
6122         header file compatible with the preprocessor -Wundef option
6123         * src/SDCCmain.c (main): abort compilation if preprocessor reports
6124         failure (fixes bug #941458)
6125
6126 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6127
6128         * src/SDCCopt.c (killDeadCode): fixed bug #907733
6129         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
6130         that the variable, not the function, should be static
6131         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
6132         to be consistent with non-literal case
6133
6134 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6135
6136         * src/SDCCast.c (isConformingBody): fixed bug #949967
6137         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
6138         convilong): fixed bug #952086
6139
6140 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6141
6142         * src/SDCCmem.c (allocVariables): fixed bug #955321
6143
6144 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6145
6146         * src/hc08/main.c (_hc08_genAssemblerEnd),
6147         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
6148         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
6149         completely eliminated the use of a temporary file
6150         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
6151         when more than one file linked
6152         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
6153
6154 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6155
6156         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
6157         which fixes bug #543481
6158         * support/regression/tests/bug-751703.c: fixed comments left from a
6159         cut and paste error
6160         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
6161         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
6162         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
6163         scopes
6164         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
6165         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
6166         are now changed to underscores in moduleName
6167
6168 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6169
6170         * as/mcs51/lkmem.c: better fix for bug #954173
6171
6172 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
6173         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6174
6175         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
6176         * device/include/c8051f000.h,
6177         * device/include/c8051f120.h,
6178         * device/include/c8051f300.h,
6179         * device/include/c8051f310.h,
6180         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
6181         PWM16) and detab'ed
6182
6183 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6184
6185         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
6186         and mailing lists, doc'ed --no-peep-comments, removed reference
6187         to knoppix (newest version has no LyX/LaTeX), other minor changes
6188         * src/SDCCglue.c (glue): save 2 bytes stack space with
6189         option --main-return. The ljmp could probably be avoided too
6190
6191 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6192
6193         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
6194
6195 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6196
6197         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
6198         * src/SDCCopt.c (isLocalWithoutDef),
6199         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
6200         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
6201         (credit to Maarten Brock for patch #949363, on which this is based)
6202         * support/regression/tests/bug-751703.c: some test cases of extern used
6203         within inner scopes.
6204
6205 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6206
6207         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
6208         SPEC_STRUCT
6209         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
6210         struct definitions
6211         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
6212         dwWriteLabel): fix to create valid debugger symbols even when
6213         the module name has non-alphanumeric symbols in it
6214         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
6215         when a variable's allocation has been optimized away
6216
6217
6218 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6219
6220         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
6221         * src/hc08/main.c,
6222         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
6223         * src/mcs51/main.c,
6224         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
6225         * src/ds390/main.c,
6226         * src/z80/gen.c (z80_emitDebuggerSymbol),
6227         * src/z80/main.c,
6228         * src/pic/gen.c (pic14_emitDebuggerSymbol),
6229         * src/pic/main.c,
6230         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
6231         * src/pic16/main.c,
6232         * src/avr/gen.c (avr_emitDebuggerSymbol),
6233         * src/avr/main.c,
6234         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
6235         * src/xa51/main.c,
6236         * src/SDCCdebug.c (emitDebuggerSymbol),
6237         * src/SDCCdebug.h,
6238         * src/port.h: added a debugger struct to the port struct. Added a
6239         callback for defining debugger symbols
6240
6241         * src/SDCCast.c (createLabel),
6242         * src/SDCC.y (labeled_statement): mark all compiler generated labels
6243         with isitmp = 1
6244         * src/SDCCicode.h,
6245         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
6246         iCode back to the ast for the function
6247
6248         * src/hc08/ralloc.c (hc08_assignRegisters),
6249         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
6250         unneeded fields from the regs struct.
6251         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
6252         pushReg() & pullReg() functions instead of emitcode()
6253
6254         * src/hc08/gen.c (genLabel, genhc08Code),
6255         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
6256
6257         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
6258         debugger hooks
6259
6260         * src/hc08/gen.c (genEndFunction, genhc08Code),
6261         * src/hc08/gen.h,
6262         * src/mcs51/gen.c (genEndFunction, gen51Code),
6263         * src/mcs51/gen.h,
6264         * src/ds390/gen.c (genEndFunction, gen390Code),
6265         * src/ds390/gen.h,
6266         * src/z80/gen.c (genEndFunction, genZ80Code),
6267         * src/z80/gen.h,
6268         * src/z80/z80.h,
6269         * src/pic/gen.c (genEndFunction, genpic14Code),
6270         * src/pic/gen.h,
6271         * src/pic16/gen.c (genEndFunction, genpic16Code),
6272         * src/pic16/gen.h,
6273         * src/avr/gen.c (genEndFunction, genAVRCode),
6274         * src/avr/gen.h,
6275         * src/xa51/gen.c (genEndFunction, genXA51Code),
6276         * src/xa51/gen.h,
6277         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
6278         specific code to cdbFile.c and out of the backend code generators
6279
6280         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
6281         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
6282         starting address is now 0
6283
6284         * as/hc08/asm.h,
6285         * as/hc08/m08pst.c,
6286         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
6287         assembler directive for DWARF support
6288         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
6289
6290         * src/src.dsp,
6291         * src/Makefile.in,
6292         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
6293
6294 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6295
6296         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
6297         and inappropriate peephole optimization in jump tables
6298
6299 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6300
6301         * as/hc08/m08pst.c,
6302         * src/SDCCglue.c: sdccopt works for the hc08 port now
6303
6304 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
6305
6306         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
6307
6308 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6309
6310         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
6311
6312 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6313
6314         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
6315         rules
6316         * src/SDCCmain.c,
6317         * src/SDCCglobl.h,
6318         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
6319         comments from the peephole optimizer replacement rules
6320         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
6321         symbols
6322         * src/SDCCcse.c (updateSpillLocation),
6323         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
6324         equivalents
6325         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
6326         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
6327         objects far pointers
6328
6329 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6330
6331         * src/SDCCsymt.h: a missing part of my last change
6332         * src/pic/ralloc.c (regTypeNum),
6333         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
6334
6335 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6336
6337         * src/SDCCicode.h,
6338         * src/SDCCicode.c (aggrToPtrDclType),
6339         * src/SDCCptropt.h,
6340         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
6341         ptrPseudoSymConvert),
6342         * src/pic/ralloc.c (regTypeNum),
6343         * src/pic16/ralloc.c (regTypeNum),
6344         * src/hc08/ralloc.c (regTypeNum),
6345         * src/ds390/ralloc.c (regTypeNum),
6346         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
6347         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
6348
6349 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6350
6351         * link/z80/lkmain.c (afile),
6352         * as/hc08/lkmain.c (afile),
6353         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
6354         prevent a pointer problem when a filename has no directory and
6355         no extension specified.
6356
6357 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6358
6359         * link/z80/lkmain.c (afile): allow periods in directory names
6360         * link/z80/lkmain.c (afile),
6361         * as/mcs51/lkmain.c (afile),
6362         * as/hc08/lkmain.c (afile): allow linker script file to have an
6363         extension other than ".lnk"
6364         * link/z80/lklex.c (getfid),
6365         * link/z80/lkmain.c (parse),
6366         * as/mcs51/lklex.c (getfid),
6367         * as/mcs51/lkmain.c (parse),
6368         * as/hc08/lklex.c (getfid),
6369         * as/hc08/lkmain.c (parse): Support comments in the linker script
6370         file on lines by themselves and after filenames
6371
6372 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6373
6374         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
6375
6376 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6377
6378         * src/z80/peeph-z80.def: removed some peephole rules that don't
6379         work with multibyte arithmetic (fixed bug #937126)
6380         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
6381         to registers and not global variables
6382         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
6383         geniCodePreInc, geniCodePostDec, geniCodePreDec,
6384         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
6385         checking for assignments not internally generated (fixed bug #931895)
6386         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
6387         structure member (fixed bug #930072)
6388
6389 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6390
6391         * src/SDCCmain.c (linkEdit),
6392         * src/hc08/main.c (_hc08_parseOptions),
6393         * as/hc08/Makefile.in,
6394         * as/hc08/aslink.h,
6395         * as/hc08/asm.h,
6396         * as/hc08/m08pst.c,
6397         * as/hc08/lkrloc.c (relr, rele),
6398         * as/hc08/lkarea.c (lnkarea)
6399         * as/hc08/lkmain.c (afile, parse),
6400         * as/hc08/lkelf.c: support for ELF output
6401         * as/hc08/lks19.c (s19),
6402         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
6403
6404 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6405
6406         * as/mcs51/lkihx.c: Fixed bug #899105.
6407
6408 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6409
6410         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6411         .dsp files from Unix to DOS.
6412
6413 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6414
6415         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6416         function pointers; we have been compliant for several months now.
6417         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6418         change that was accidently commented out
6419         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6420         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6421         bug #922319
6422
6423 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6424
6425         * src/hc08/gen.c: output of all of the internal debugging information
6426         is now controlled by the D() macro; it is disabled by default
6427
6428 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6429
6430         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6431         harder to keep the same registers during a CAST iCode
6432         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6433         long via int can be done in a single cast, if the signedness is
6434         correct.
6435         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6436         putchar() in tinibios.c in ds390's library
6437
6438 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6439
6440         * src/SDCCast.c (decorateType): fixed bug #898889,
6441         cast result of a literal complement too
6442         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6443         fixed check for bitfields
6444
6445 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6446
6447         * src/SDCCicode.c (geniCodeLogic): made it static,
6448         (geniCodeLogicAndOr): added in order to fix bug #905492,
6449         (ast2iCode): fixed bug #905492
6450         * support/regression/tests/bug-905492.c: added
6451         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6452         (processParms): fixed bug #927659: don't copy parms, this will clear
6453         decorated flag
6454         * support/regression/tests/bug-927659.c: added
6455
6456 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6457
6458         * src/SDCCast.c (addCast): don't cast float to char
6459         * device/lib/libsdcc.lib: added _memmove
6460
6461 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6462
6463         * device/lib/large/Makefile: fixed parallel execution by
6464         replacing `make` by `$(MAKE)`
6465
6466 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6467
6468         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6469         offsets (fixes bug #923936)
6470
6471 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6472
6473         * device/lib/small/Makefile: fixed parallel execution by
6474         replacing `make` by `$(MAKE)`
6475
6476 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6477
6478         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6479
6480 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6481
6482         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6483         * src/regression/Makefile: Regression test was not running.
6484
6485 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6486
6487         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6488         complement if possible
6489         * src/SDCCval.c (valComplement),
6490         * src/SDCCicode.c (operandOperation): fixed complement of literal
6491         * support/regression/tests/onebyte.c (testComplement): added
6492
6493 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6494
6495         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6496         return an optimized tree; actually replace actParm with the new tree
6497         * src/SDCCast.h: added some parantheses to remove side effects
6498         * support/regression/tests/bug-920866.c
6499
6500 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6501         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6502         Bit operands were not being handled properly in the pic14 port.
6503         (now src/regression/add.c passes again).
6504
6505 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6506
6507         * src/SDCC.y (labeled_statement): case and default no longer require
6508         a following statement (RFE #893037)
6509
6510 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6511
6512         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6513         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6514         disabled (fixes bug #916294)
6515         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6516         "mov a,acc"; patch provided by Lenny Story
6517         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6518
6519 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6520
6521         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6522         functions
6523         * src/ds390/gen.c (genFunction, genEndFunction),
6524         * src/ds390/ralloc.c (ds390_assignRegisters),
6525         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6526         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6527         pushed if there are parameters passed on the stack. Also, a cleaner
6528         way to decide if r0/r1 should be pushed/popped. (Together they fix
6529         bug #918693)
6530
6531 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6532
6533         * doc/sdccman.lyx,
6534         * device/lib/mcs51/crtpagesfr.asm,
6535         * device/lib/mcs51/crtxinit.asm,
6536         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6537         to avoid confusion with Si Lab's SFRPAGE register.
6538
6539 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6540
6541         * src/SDCCglue.c (emitMaps): allow public sfr variables
6542         * src/SDCCglue.c (initialComments): include compiler build date
6543         with compiler version and put the timestamp of the generated
6544         assembly file on a serperate line to be less confusing.
6545         * src/port.h: added genInitStartup hook
6546         * src/avr/main.c,
6547         * src/ds390/main.c,
6548         * src/hc08/main.c,
6549         * src/pic/main.c,
6550         * src/pic16/main.c,
6551         * src/xa51/main.c,
6552         * src/z80/main.c: genInitStartup initialize as NULL (default to
6553         historical behaviour)
6554         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6555         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6556         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6557         library instead of hard coding it into the compiler.
6558         * support/regression/ports/mcs51-stack-auto/spec.mk,
6559         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6560         * device/lib/mcs51/Makefile,
6561         * device/lib/small/Makefile,
6562         * device/lib/large/Makefile,
6563         * device/lib/mcs51/crtpagesfr.asm,
6564         * device/lib/mcs51/crtstart.asm,
6565         * device/lib/mcs51/crtxclear.asm,
6566         * device/lib/mcs51/crtxinit.asm,
6567         * device/lib/mcs51/crtclear.asm,
6568         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6569         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6570         and into user configurable files.
6571         * device/lib/clean.mk: clean mcs51 directory too
6572         * support/regression/tests/longlit.c: added static to T1 declaration
6573         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6574         accesses in the initialization code
6575
6576 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6577
6578         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6579         OSCTRIMVAL as noted in bug #916008
6580
6581 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6582
6583         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6584         in loops with multiple exits (reported as incorrect registers
6585         used by Martin Helmling in Sdcc-user list)
6586
6587 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6588
6589         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6590         made ds390 register extensions look less like error messages
6591
6592 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6593
6594         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6595         reported by Adam Wozniak in Sdcc-user list
6596
6597 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6598
6599         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6600         arithmetic optimizations, added debug output
6601
6602 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6603
6604         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6605         * sdcc.spec: updated and split sdcc into 3 rpms
6606         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6607         needed for literals of LEFT_OP and '+'
6608         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6609         introduced RESULT_TYPE_NOPROM
6610         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6611         left shift
6612         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6613         limited promotion to int only for '*'
6614         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6615
6616 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6617
6618         * src/pic16/gen.c (genSkip),
6619         (genc16bit2lit), (gencjneshort): commented out
6620         (is_LitOp): new helper function, checks operand type
6621         (genCmpEq): rewritten
6622
6623 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6624
6625         * support/regression/tests/bug-908454.c: added
6626
6627 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6628
6629         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6630         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6631         (geniCodeCast): cosmetic, don't preserve bit storage class
6632         (geniCodeLeftShift): added promotion
6633         (geniCodeLogic): fixed regression
6634         * src/SDCCsymt.c (computeTypeOr): accept bits too
6635         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6636
6637 2004-03-07  Borut Razem <borut.razem AT siol.net>
6638
6639         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6640
6641 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6642
6643         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6644         version of pic16_genPackRegisters which does not check if ic is a
6645         CAST operator,
6646         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6647         function cause string1.c regression test fails
6648
6649 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6650
6651         * sim/ucsim/configure.in,
6652         * sim/ucsim/configure,
6653         * sim/ucsim/doc/Makefile.in: use docdir
6654         * src/SDCC.y: fixed sbit atrributes
6655         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6656         * src/SDCCast.c (decorateType): |^& need special promotion handling
6657         * src/SDCCast.h,
6658         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6659         * src/SDCCsymt.h (computeType),
6660         * src/SDCCicode.c: computeType() needs op
6661         * src/SDCCsymt.c (checkTypeSanity),
6662         * doc/sddman.lyx: "plain" bitfields are unsigned
6663         * src/SDCCsymt.c (computeTypeOr): added
6664         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6665         |^& ops
6666         * src/SDCCval.c (val*): computeType() needs op
6667         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6668         * support/regression/tests/onebyte.c: added tests for |^&
6669
6670 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6671
6672         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6673         for writing icode into asm output.
6674
6675 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6676
6677         * src/pic16/device.c: added some debug lines enabled
6678         with macro DEBUG_CHECK,
6679         * src/pic16/genarith.c: more debug in genPlus,
6680         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6681         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6682         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6683         * (aopForSym): onStack symbols are re-placed in data memspace,
6684         and onStack flag is cleared,
6685         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6686         copy temporary pcodeop,
6687         * (genPcall): added warning for not updating PCLATU,
6688         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6689         always true for pic16 port,
6690         * (genMultOneWord): NEW, supports integer multiplication,
6691         * (genMult): modified to call genMultOneWord,
6692         * (ifxForOp): added warning when return NULL,
6693         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6694         flag is set before call to operandFromSymbol for implicit
6695         added structures,
6696         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6697         options.intlong_rent are set by default,
6698         * (_hasNativeMulFor): modified to allow port generation of integer
6699         multiplication,
6700         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6701         set regtype to REG_SFR for all registers, restricting seting the
6702         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6703
6704 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6705
6706         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6707         more than 500 times in the regression tests
6708
6709 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6710
6711         * support/Util/SDCCerr.h,
6712         * support/Util/SDCCerr.c,
6713         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6714         enumerator_list),
6715         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6716         for symbol conflicts.
6717         * support/valdiags/tests/enum.c,
6718         * support/valdiags/tests/tentdecl.c,
6719         * support/valdiags/tests/struct.c: expect possible error messages
6720         referring to original symbol definitions.
6721         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6722         * src/SDCCsymt.h,
6723         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6724
6725 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6726
6727         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6728
6729 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6730
6731         * src/pic16/ralloc.c (newReg): fixed bug #908929
6732
6733 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6734
6735         * src/ds390/gen.c: added missing #include "main.h"
6736
6737 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6738
6739         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6740         checking if symbol is already in set,
6741         * src/pic16/device.h: prototype for checkAddSym,
6742         * src/pic16/gen.c: (_G): added entry interruptvector,
6743         * (assignResultValue): removed some commented out lines,
6744         * (genFunction): check for ISR via sym->type, absolute section for
6745         interrupt code is created via a new pBlock, the goto instruction is
6746         placed now correctly at the interrupt vector position, changed all
6747         references from ivec to _G.interruptvector,
6748         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6749         is the interrupt is a high priority one, same for return from ISR,
6750         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6751         externs to calls of checkAddSym,
6752         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6753         pic16_pcode_verbose flag is set,
6754         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6755         * src/pic16/pcoderegs.c: message about how many registers are saved
6756         will only be emitted if pic16_pcode_verbose flag is set,
6757
6758 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6759
6760         * src/ds390/ralloc.h,
6761         * src/ds390/ralloc.c (ds390_regWithIdx),
6762         * src/ds390/gen.c (emitcode),
6763         * src/ds390/main.h,
6764         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6765         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6766         ds390operandCompare, getRegsRead, getRegsWritten,
6767         initializeAsmLineNode): customized instruction size calculation for
6768         ds390, started basis for some register optimizations
6769         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6770         corresponding assembly output
6771         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6772         missing push/pop of r0/r1. Optimized push/pops
6773
6774 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6775
6776         * src/mcs51/main.c (instructionSize): fixed ACALL size
6777         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6778
6779 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6780
6781         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6782         the sorting of rlist with NULL elements
6783         * (print_idataType, print_idata): NEW to create idata sections
6784         * src/pic16/device.h: idataSymSet new variable
6785         * src/pic16/gen.c (genFunction): fixed some bugs in string
6786         comparing, improved the absolute section creation for ISRs,
6787         added FSR0L/FSR0H in registers that are saved in an ISR,
6788         * (genInline): fixed the processing of inline snippets,
6789         now they undergo no process by the peephole optimizer
6790         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6791         are placed in idataSymSet,
6792         * (pic16emitStaticSeg): extern symbols are added in externs,
6793         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6794         switching when aboslute variables are placed in access bank memory
6795         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6796         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6797         commented out with #if,
6798         * (pic16_packRegisters): reintroduce the check for CAST because some
6799         symbols are not correctly handled,
6800         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6801         pCodeInstruction instead of pCode,
6802         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6803         pCodeAsmDir definition,
6804         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6805         directive, then the argument directive is emitted without the leading
6806         tab, hack for inline labels which must be in the first column,
6807         * (compareLabel,pic16_findNextInstruction),
6808         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6809         * (insertBankSwitch): modified for the new pCodeAsmDir,
6810
6811 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6812         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6813
6814         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6815         instance,
6816         * (pushSide): commented out with #if,
6817         * (assignResultValue): fixed some typos in saving
6818         registers,
6819         * (genPcall): FIXED and sync'ed with genCall,
6820         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6821         * (genNearPointerGet): fixed to handle some more cases,
6822         implementation scheme via table reads,
6823         * (genConstPointerGet): modified to access code memory correct,
6824         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6825         and improved to handle some cases
6826         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6827         instead of "RETLW" for init data
6828         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6829         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6830         variables are placed in access bank memory (<0x80 and >=0xf80),
6831         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6832         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6833         TBLWT_POSTDEC,TBLWT_PREINC
6834         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6835         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6836         directives
6837         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6838         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6839         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6840         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6841
6842 2004-02-29  Borut Razem <borut.razem AT siol.net>
6843
6844         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6845         support/Util/findme.h, support/Util/system.h: enhance binary relative
6846         search for lib and include by using findProgramPath()
6847
6848 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6849
6850         * src/SDCCpeeph.h,
6851         * src/SDCCpeeph.c (pcDistance),
6852         * src/port.h,
6853         * src/mcs51/ralloc.h,
6854         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6855         * src/mcs51/main.h,
6856         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6857         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6858         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6859         size calculation port specific, started basis for some register
6860         optimizations
6861         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6862         missing push/pop of r0/r1. Optimized push/pops
6863         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6864         * device/lib/_modsint.c (_modsint),
6865         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6866         and stack version so regression tests pass
6867
6868 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6869
6870         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6871         * src/SDCCast.c (decorateType): catch another small optimization
6872         with '?' operator
6873         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6874         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6875         modified to finally use computeType() all over SDCC,
6876         see Feature Request #877103
6877         * src/SDCCval.h: cosmetic
6878         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6879         valCompare(); regression tested in muldiv.c
6880         * support/regression/tests/muldiv.c (testMod): mod sign follows
6881         dividend only
6882
6883 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6884
6885         * src/SDCCast.c (decorateType): fixed bug #902362
6886         * doc/INSTALL.txt: fixed install instructions for win32
6887
6888 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6889
6890         * device/include/Makefile.in (install): fixed by replacing spaces
6891         by tabs
6892         * doc/README.txt,
6893         * doc/INSTALL.txt: updated for release
6894         * doc/sdccman.lyx: added warning for --xstack being buggy
6895
6896 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6897
6898         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6899         to eliminate build warnings.
6900         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6901
6902 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6903            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6904
6905         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6906         removed -penable-stack, added comment for stack pragma, added
6907         warning for not initializing the stack/frame registers, removed
6908         comment at interrupts section
6909
6910         Stack is made permanent, there is no ability to disable stack usage.
6911         * src/pic16/device.h,
6912         * src/pic16/device.c: removed all references to USE_STACK macro,
6913         * src/pic16/device.c (pic16_dump_section): when no elements in
6914         rlist, free rlist before return,
6915         * (pic16_dump_int_registers): NEW, internal registers are a new set
6916         of general purpose registers reused by each function,
6917         * (checkAddReg): returns 1 if registers is added to set,
6918         * (pic16_groupRegistersInSection): when a registers is of type
6919         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6920         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6921         SRCASECMP macro is moved here from device.c
6922         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6923         PO_PCLATU, PO_PRODL, PO_PRODH,
6924         * (pic16_pCodeOpType, genMinus,
6925         changed compares to "a" register, with AOP_ACC,
6926         * (pic16_genPlus): fixed some bugs and indented properly,
6927         * (pic16_addSign): changed size to size+offset in the MOVWF
6928         instruction,
6929         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6930         multiply 8-bit operand by literal, result is 8-bit,
6931         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6932         multiply 2 8-bit operand, result is 8-bit,
6933         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6934         genUMult8X*_16,
6935         * src/pic16/gen.c: changed accUse to contain WREG only,
6936         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6937         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6938         true, do not use immediate addressing any more unless sym is a
6939         pointer in codespace,
6940         * (aopForRemat): do not use immediate addressing when symbol not in
6941         codespace and when symbol's address is requested,
6942         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6943         accUse size (= 1),
6944         * (aopGet): added case for AOP_ACC and don't return "accumulator
6945         bug" but WREG instead,
6946         * (popGetTempReg): pushes contents of temporary register in stack,
6947         * (popReleaseTempReg): pops contents of temporary register from
6948         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
6949         * (pic16_popGet): separated case AOP_ACC to return register WREG
6950         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
6951         or PO_IMMEDIATE and initializes their instance/offset appropriately,
6952         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
6953         the use of immediate pointers to certain cases only.
6954
6955         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
6956         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
6957         * (assignResultValue, genCall, genRet): modified to use the new
6958         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
6959         genPcall is still broken,
6960         * (genFunction): added code to create 'A' type pBlocks when
6961         interrupt functions are generated, code not extensively tested yet,
6962         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
6963         * (genEndFunction): modified so ISRs pop stored registers from stack,
6964         * (genMultOneByte): cleanup,
6965         * (AccRsh): added flag andmask, to and result with appropriate mask,
6966         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
6967         * (genDataPointerGet): fixed and reenabled its use,
6968         * (genNearDataPointerGet): bugs fixed,
6969         * (genDataPointerSet): bugs fixed,
6970         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
6971         pic16_DumpSymbol, pic16_DumpOp,
6972         * src/pic16/genutils.h: function prototypes for the above functions,
6973         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
6974         pointers,
6975         * (pic16emitRegularMap): many many many improvements, but needs a
6976         major cleanup,
6977         * src/pic16/main.c: enable_stack in pic16_options is removed,
6978         * (_pic16_parseOptions): removed command line options -penable-stack,
6979         * (_process_pragma): emit stack symbol only when stack pragma is
6980         processed,
6981         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
6982         redirected to FSR0L/FSR0H pair,
6983         * (pic16_get_op, pic16_get_op2): modifications and improvements,
6984         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
6985         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
6986         for immediates,
6987         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
6988         * (dumpPicOptype): NEW,
6989         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
6990         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
6991         with movff instruction,
6992         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
6993         added pic16_int_regs, some packRegsFor* functions are commented out,
6994         because produce errors,
6995         * src/pic16/NOTES: minor modifications
6996
6997 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6998
6999         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
7000         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
7001         --pack-iram.
7002         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
7003         * as/mcs51/lkaomf51.c: fixed bug #895763
7004
7005 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
7006
7007         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
7008
7009 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7010
7011         * doc/sdccman.lyx: added details about the HC08 storage classes and
7012         interrupts, fixed the register usage info for z80 & gbz80
7013
7014 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
7015
7016         * doc/sdccman.lyx: added more pic16 port documentation
7017         * device/include/pic16/: added header pic18fregs.h
7018
7019 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
7020
7021         * doc/sdccman.lyx: added Vangelis' contribution
7022
7023 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7024
7025         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
7026         extend to the next CALL or PCALL, not just to the next CALL.
7027
7028 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
7029
7030         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
7031
7032 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7033
7034         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
7035         bug #895752 and a better fix for bug #716790
7036
7037 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7038
7039         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
7040
7041 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7042
7043         * doc/sdccman.lyx: minor changes, minor changed
7044
7045 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
7046
7047         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
7048         which can't handle SDCC_NEWONEBYTEOPS,
7049         (geniCodeMultiply): removed conversion from mult to shift for pic14
7050         and pic16
7051
7052 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7053
7054         * src/hc08/gen.h,
7055         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
7056         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
7057         thus fixing bug #895406
7058
7059 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
7060
7061         * device/lib/_modsint.c,
7062         * device/lib/_modslong.c: sign follows divisor only
7063         * src/hc08/gen.c (genMultOneByte): if result size is 1,
7064         signs or signedness can be ignored
7065         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
7066         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
7067         added optimization for IFX,
7068         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
7069         arguments;
7070         reenabled optimization for IFX, which was removed on 2004-01-11
7071         * src/SDCCast.h: added return type IFX
7072         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
7073         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
7074         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
7075         SDCC_OLDONEBYTEOPS selects the old behaviour
7076         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
7077         changed again and commented promotion rule
7078         * src/SDCCval.c (valDiv): promotion no longer necessary
7079         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
7080         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
7081         rewritten
7082         * support/regression/tests/onebyte.c: added
7083
7084 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
7085
7086         * gen.c (genInline): reverted to old code for assemnling inline
7087         code because of bug reported James Chadd
7088
7089 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
7090
7091         * ralloc.h: missing declarations from previous patch,
7092         seems that patch for ralloc.h was never applied, fixed
7093
7094 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7095            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7096
7097         * pcode.c,
7098         * pcode.h,
7099         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
7100         indirect addressing. Marked FSR0 as deprecated
7101         * gen.c (pointerCode): commented out, not needed now
7102         (pic16_popGet2p): new MOVFF helper function
7103         (genGenPointerGet),
7104         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
7105         (shiftRLong): removed duplicate debugging info
7106
7107 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7108
7109         * src/ds390/gen.c (genNearPointerGet),
7110         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
7111         optimization with bits, but not bitfields.
7112         * src/ds390/ralloc.c (packRegisters),
7113         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
7114
7115 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
7116
7117         * src/SDCCcse.c (algebraicOpts): copy operands before modification
7118
7119 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7120
7121         * src/SDCCsymt.h,
7122         * src/SDCCicode.c (operandFromSymbol),
7123         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
7124         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
7125         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
7126         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
7127         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
7128         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
7129         bug #892038
7130         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
7131         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
7132         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
7133         * src/SDCCsymt.c (newSymbol),
7134         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
7135         enumerator_list),
7136         * src/SDCCval.h,
7137         * src/SDCCval.c (newiList): fixed bug #885705
7138
7139 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7140
7141         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
7142         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
7143
7144 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7145
7146         * device/include/c8051f120.h,
7147         * device/include/c8051f300.h,
7148         * device/include/c8051f310.h: added/updated header files for Silicon
7149         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7150         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
7151         in new section Submitting patches
7152
7153 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7154
7155         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
7156         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7157         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7158         genGenPointerSet),
7159         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
7160         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7161         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7162         genGenPointerSet),
7163         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
7164         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7165         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7166         genGenPointerSet),
7167         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
7168         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7169         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7170         genGenPointerSet): fixed bug #892400
7171         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
7172         to eliminate build warnings.
7173         * src/SDCCast.c (processParms),
7174         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
7175         fixed bug 751859
7176         * support/valdiag/valdiag.py: added GCC to the list of defines active
7177         when compiling with gcc
7178
7179 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7180
7181         * support/Util/SDCCerr.h,
7182         * support/Util/SDCCerr.c,
7183         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
7184         with an incomplete type (fixed bug #883734)
7185         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
7186
7187 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7188
7189         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
7190
7191 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7192
7193         * src/SDCCast.c (decorateType),
7194         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
7195         function pointer implementation
7196         * support/regression/tests/funptrs.c: added tests to verify both forms
7197         of function pointers work correctly. Added tests to verify parameters
7198         are passed in the correct order.
7199
7200 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
7201
7202         * device.c (regCompare): registers are sorted by ascending
7203         address and increasing size,
7204         * main.c (_pic16_finaliseOptions): removed the declaration
7205         of compiler macro MCU. Now a macro of the format pic18fxxxx
7206         will be defined from the command line
7207
7208 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7209             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7210
7211         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
7212         PCOP_RLCF was overwritten!
7213         * gen.c (genSkip): commented out calls to pic16_emitcode,
7214         * (genCmpEQ): fixed "long" compares, only high word did get compared,
7215         * (genlshTwo),
7216         * (genRRC): added debugging info,
7217         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
7218         overwritten while shifting,
7219         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
7220         overwritten while shifting,
7221         * (AccLsh),
7222         * (AccRsh),
7223         * (shiftLLeftOrResult),
7224         * (shiftRLeftOrResult),
7225         * (shiftRLong),
7226         * (shiftLLong): Implemented with pic16_emitpcode
7227         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
7228         * (genLeftShift): Fixed bug, operand for shift by variable always
7229         was "and"ed with 0x0f,
7230         * (genLeftShiftLiteral),
7231         * (genrshTwo),
7232         * (genRightShiftLiteral): added debugging info,
7233         * (genrshFour): added comment,
7234         * (genRightShift): determined signedness from operand "left"
7235         instead of "result"
7236
7237 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7238
7239         * src/SDCCicode.c (geniCodeParms),
7240         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
7241         function pointers, fixed function pointer bugs #861242 and #861896
7242
7243 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7244
7245         * device/include/c8051f000.h,
7246         * device/include/c8051f120.h,
7247         * device/include/c8051f300.h: added header files for Silicon
7248         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7249
7250 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
7251
7252         * src/SDCCast.c (processParams): added new type flow and restructured
7253         (gatherAutoInit): added new type flow
7254         (addCast): cosmetic changes
7255         (getLeftResultType): added new type flow for array indices, patch
7256         provided by Stas, see FR #877103
7257         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
7258         array index patch by Stas
7259         * src/SDCCast.h: added prototype getResultTypeFromType()
7260         * src/SDCCval.h,
7261         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
7262         * src/pic/glue.c (pic14emitStaticSeg),
7263         * src/pic16/glue.c (pic16emitStaticSeg),
7264         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
7265         for initialization of symbols
7266         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
7267         * support/Util/SDCCerr.h:
7268         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
7269         * .version: bumped version number to 2.3.8
7270         * device/include/Makefile.in (install),
7271         * doc/Makefile (install): changed to 'rm `find ...`' construct to
7272         avoid warnings
7273
7274 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
7275
7276         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
7277         Slade Rich fixed an optimization bug
7278         * src/pic/pcodepeep.c,
7279         * src/pic/pcoderegs.c
7280         * doc/Makefile (install): added test for directory
7281
7282 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7283
7284         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
7285         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
7286         * src/pic/ralloc.c (getRegPtr, getRegGpr),
7287         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
7288         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
7289         * as/mcs51/asexpr.c (term),
7290         * as/hc08/asexpr.c (term): fixed bug #887146
7291
7292 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7293
7294         * src/z80/gen.c (genMult): handle single byte result product
7295         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
7296         DUMMY_READ_VOLATILE (fixed bug #886367)
7297
7298 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7299
7300         * support/regression/tests/libmullong.c: fixed logic, on little endian
7301         hosts we ended without a mullong_wrapper()
7302
7303 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7304
7305         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
7306         virus/worm forged address usage.
7307
7308 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7309
7310         Fixed promotion, it should be done on AST level:
7311         * src/SDCCast.c (addCast): added promotion to int
7312         (decorateType): updated call to upCast()
7313         * src/SDCCicode.c (geniCodeLeftShift): removed call to
7314         usualUnaryConversions()
7315
7316 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
7317
7318         * support/regression/tests/literalop.c (mulWrapper): Added a
7319         wrapper to remove integer overflow warnings.
7320
7321         * support/regression/tests/float_trans.c: Made work on host.
7322
7323         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
7324         location of sz80.
7325
7326         * support/regression/generate-cases.py (main): Changed from inline
7327         to a main method.
7328
7329         * doc/Makefile (install): Changed to depth first to get rid of
7330         missing directory install warning.
7331
7332         * as/Makefile (install-doc): Made work on Mac.
7333
7334 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
7335
7336         * src/SDCCast.c: added an additional type flow in decorateType() of
7337         opposite direction, see feature request #860006; it's enabled at runtime
7338         by setting the environment variable SDCC_NEWTYPEFLOW
7339         * src/SDCCast.h: changed prototype of decorateType()
7340         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
7341         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
7342         'char' to 'int' can be omitted, if both operands are 'unsigned char';
7343         see feature request #877103
7344         * src/SDCCval.c: updated call of decorateType()
7345         (valBitwise): fixed bug #882876
7346         (valMinus): added promotion
7347         (valLogicAndOr): result is unsigned
7348         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
7349         * src/SDCCsymt.c (computeType),
7350         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
7351         must not cause an unsigned operation
7352         * src/pic/glue (pic14emitRegularMap),
7353         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
7354
7355 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
7356
7357         * src/pic/pcode.c (PCodeID): commented out left over debug code
7358
7359 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
7360
7361         * support/valdiag/tests/overflow.c: added shift tests
7362         * src/pic/device.c,
7363         * src/pic/gen.c,
7364         * src/pic/gen.h,
7365         * src/pic/glue.c,
7366         * src/pic/main.c,
7367         * src/pic/pcode.c,
7368         * src/pic/pcode.h,
7369         * src/pic/pcodepeep.c,
7370         * src/pic/pcoderegs.c,
7371         * src/pic/ralloc.c,
7372         * src/pic/ralloc.h: applied patch from Slade Rich;
7373         added support for multiple code pages and multiple RAM banks on the
7374         PIC 14 port. The ASM files now no longer simply assume all the
7375         code / RAM are in the same page / bank. This means the linker can
7376         safely allocate code/RAM of separate ASM files to different pages/banks.
7377         * doc/sdccman.lyx: added Slade's tips
7378         * src/mcs51/peeph.def: fixed bug #880768
7379
7380 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7381
7382         * src/hc08/ralloc.c (rematStr): fixed bug #879282
7383         * src/SDCCast.c (decorateType): fixed bug #880197
7384
7385 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
7386
7387         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
7388         getopt.h.
7389
7390         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
7391         strtof is not part of C89 and isn't included with Mac OS X.
7392
7393 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7394
7395         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
7396         shiftL2Left2Result): fixed bug #879326
7397         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
7398         (genMultOneByte): fixed bug in signed vs unsigned multiplication
7399         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
7400         address fetch for clr instruction
7401         * device/lib/hc08/_mulint.c: created optimized assembly version
7402         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
7403
7404 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
7405
7406         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
7407         proposed in FR #877103
7408
7409 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
7410
7411         * src/SDCCval.c (cheapestVal): added missing checks
7412         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7413         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7414
7415 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7416
7417         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7418         equal operands
7419
7420 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7421
7422         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7423         loaded with the linker search paths (-L arguments) and the libraries
7424         to be linked with the current source (-l arguments). Changes
7425         currently will affect only the pic16 port.
7426         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7427         include path the port specific paths and port specific libraries,
7428         * gplink command now contains the $3 argument,
7429         * src/pic16/device.h,
7430         * src/pic16/device.c,: structure PIC_device is made public and
7431         renamed to PIC16_device, the same for variable Pics which is renamed
7432         to Pics16. Updated all references to them.
7433         * src/pic16/glue.c (pic16glue): corrected bug with code
7434         initialization which bypassed the variable initializations block.
7435
7436         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7437         COMPILE_FLAGS and added the --nostdinc option
7438
7439 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7440
7441         * device/include/mc68hc908jb8.h: Register defs for another member
7442         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7443
7444 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7445
7446         Documenting changes from previous commits.
7447         * configure.in (version 1.56),
7448         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7449         when generating output files to configure the pic16 library,
7450         but now I've commented it out, since gputils aren't installed in the
7451         SF compile farm, so library won't compile
7452
7453         * device/lib/Makefile.in (version 1.56): initially I've added in
7454         target 'all' the prerequestive 'model-pic16' so it compiled the
7455         pic16 library, but now I've commented it out for the same reasons
7456         above,
7457         * added targets 'model-pic16' and 'objects-pic16' to compile the
7458         library
7459         * added target 'port-specific-objects-pic16' to handle the
7460         generated libraries and copy them into the build/ directory
7461         * added target 'clean-intermediate-pic16' to clean intermediate
7462         files into pic16 directory
7463         * in target 'installdirs' added line to create directory pic16 in
7464         the installation path
7465
7466         * device/include/Makefile.in (version 1.11): in target 'install'
7467         added lines to copy all header files to installation path,
7468         * in target 'installdirs' added line create directory for pic16
7469         headers in the installation path
7470
7471 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7472
7473         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7474          a function call
7475
7476 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7477
7478         * configure,
7479         * device/lib/configure.in,
7480         * device/lib/configure: fixed for autoconf 2.57
7481
7482 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7483
7484         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7485         option so that it actually works. Made it specific to the z80, since
7486         the gbz80 doesn't have these kinds of I/O ports.
7487
7488 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7489
7490         * device/include/z180.h,
7491         * device/lib/_memcpy.c,
7492         * device/lib/_memmove.c,
7493         * device/lib/_mulint.c,
7494         * device/lib/ser_ir.c,
7495         * device/lib/ser_ir_cts_rts.c,
7496         * device/lib/_strcmp.c,
7497         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7498         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7499         portmode; added deprecation warning for bank= and protmode= forms.
7500         Also, guard against buffer overflow.
7501         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7502
7503 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7504
7505         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7506         changed interrupt vector table generation to only emit declared vectors.
7507         * device/include/Makefile.in: added missing backslash
7508         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7509
7510 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7511
7512         Mainly changes to support compilation of the device libraries
7513         * src/pic16/device.c: stack is allocated via symbol and not
7514         via literal number. The symbol is placed in the corresponding
7515         position of the data ram
7516         * (pic16_dump_section): relocatable and absolute uninitialized
7517         data are now emitted in sorted order to reduce section naming,
7518         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7519         weren't marked as being in the access bank,
7520
7521 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7522
7523         Added portion of GNU PIC Library under the directory
7524         device/include/pic16 and device/lib/pic16. These files
7525         contain the declarations of SFRs for the PIC18Fxx2 devices.
7526         The directory is initialized via configure from toplevel.
7527
7528 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7529
7530         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7531         the spilllocations to be compared correctly
7532
7533 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7534
7535         * src/SDCCast.c (decorateType): fixed bug introduced today
7536
7537 2004-01-12  Borut Razem <borut.razem AT siol.net>
7538
7539         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7540         doc/sdccman.lyx: upper case pragmas are deprecated
7541
7542 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7543
7544         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7545         in simpler and even better code
7546
7547 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7548
7549         * src/SDCCicode.c (operandOperation): fixed bug #874819
7550         * src/SDCCast.c (decorateType): fixed
7551         char foo (unsigned long ul) { return ul > 0; }
7552
7553 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7554
7555         * doc/sdccman.lyx: Moved and added some sections, small changes
7556         all over. Telling LaTeX to be less strict with word spacing
7557         to better keep the right margin. Changed some notes about
7558         maintainance of the ports in section 3.2.1 - is it OK like this?
7559
7560 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7561
7562         SDCC source changes:
7563         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7564         convilong): modified to inform the pic16 port that builtin functions
7565         are external
7566
7567         PIC16 PORT specific changes:
7568         * src/pic16/device.c pic16_dump_equates() added,
7569         processor registers declared internally by the port are emitted in
7570         the translation as equates,
7571         * src/pic16/gen.c: inline code is passed unprocessed to the
7572         translation,
7573         * (pic16_popGetLit2): fnuction modified to take second operand as
7574         pCodeOp pointer and not as literal,
7575         * (popRegFromIdx): prefixed with pic16_,
7576         * (pic16_popCombine2): modified to receive already allocated pCode
7577         operands,
7578         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7579         * (genFunction): initializes local stack frame and pushes on stack
7580         all the registers used by this function,
7581         * (genEndFunction): restores all registers from stack and restores
7582         stack frame,
7583         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7584         improvements,
7585         * (pic16glue): changed the program startup sequence,
7586         * added new dbName code 'A' for functions placed in absolute section
7587         * src/pic16/main.c: added function attribute _naked,
7588         * added pragma 'code' to place a fnuction at an absolute address,
7589         * added command line arguments --debug-ralloc and --pcode-verbose,
7590         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7591         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7592         * (pic16_newpCodeOpLit2): modified to take the second operand as
7593         pCodeOp pointer,
7594         * (pic16_printpBlock): modified to emit each function in a separate
7595         section,
7596         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7597         UPPER for immediate operands,
7598         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7599         instruction,
7600         * src/pic16/peeph.def: all peepholes with movff are commented out,
7601         because there is a problem in the pcode peep optimizer,
7602         * src/pic16/ralloc.c: the register allocator can now reuse local
7603         function symbols for another function. This saves register usage.
7604         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7605
7606         Added file src/pic16/NOTES with information about program writing on
7607         the current port version.
7608
7609 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7610
7611         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7612         and peephole 252 (array access)
7613
7614 2004-01-09  Borut Razem <borut.razem AT siol.net>
7615
7616         * src/SDCCmain.c : fixed #872250: -l command line defined library
7617           files are scanned before standard library files
7618
7619 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7620
7621         * src/SDCCast.c (decorateType): fixed bug #874046
7622
7623 2004-01-09  Borut Razem <borut.razem AT siol.net>
7624
7625         * support/scripts/sdcc.nsi: remove previous installation
7626
7627 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7628
7629         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7630         bytes for last interrupt vector (mcs51)
7631         * sdcc.spec: fixed typo
7632
7633 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7634
7635         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7636         gen51Code): more efficient parameter receive for --model-large
7637         ("bug" #845294)
7638
7639 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7640
7641         * src/ds390/main.c,
7642         * src/z80/main.c: added missed needLinkerScript flags (more than
7643         one port structure defined in these file)
7644         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7645         bug #795325
7646
7647 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7648
7649         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7650         * src/port.h: added flag needLinkerScript in port->linker
7651         structure to inform whether to create a .lnk file or not,
7652         * src/avr/main.c,
7653         * src/ds390/main.c,
7654         * src/hc08/main.c,
7655         * src/mcs51/main.c,
7656         * src/pic/main.c,
7657         * src/pic16/main.c,
7658         * src/xa51/main.c,
7659         * src/z80/main.c: changed appropriately to configure
7660         needLinkerScript flag
7661         * src/pic/gen.c,
7662         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7663         * src/pic/glue.c: added variable udata_section_name to
7664         override default uninitialized data segment definition for
7665         devices only with SHAREBANK memory (reported from Erik Epetrich)
7666         * (pic14emitOverlay): modified to emit a commented overlay segment
7667         directive when no overlay data exist
7668         * (picglue): modified to emit uninitialized data segment
7669         according to udata_section_name
7670         * src/pic/main.c (_pic14_parseOptions): added command line
7671         options --udata-section-name=[name] to override default
7672         udata definition name
7673         * modified _linkCmd and _asmCmd to include compiler passed
7674         arguments via -W option
7675         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7676         object file from '.rel' to '.o' in port->linker structure,
7677         changed size of fptr from 2 to 3 in port structure
7678
7679 2004-01-07  Borut Razem <borut.razem AT siol.net>
7680
7681         * support/scripts/sdcc.nsi: update PATH
7682         * support/scripts/sdcc.ico: craeted
7683
7684 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7685
7686         * device/include/Makefile.in: fix install
7687         * doc/Makefile: fix install
7688
7689 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7690
7691         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7692         in bug #860505
7693         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7694         how the function variable allocation summary is displayed; also
7695         include information about variables allocated to the overlay
7696         segment
7697
7698 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7699
7700         * as/mcs51/lkmain.c: Help about -Y option
7701         * as/mcs51/lkarea.c: Fixed gcc warnings
7702
7703 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7704
7705         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7706         fixed warning
7707         * support/valdiag/tests/overflow.c: added
7708         * src/SDCCast.c (decorateType),
7709         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7710         LEFT_OP (left shift)
7711
7712 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7713
7714         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7715         (default behaviour).
7716
7717 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7718
7719         A python script to validate compiler diagnostic messages. It can be
7720         used to verify that sdcc complains about bad c source code and
7721         gives a good location of the error.
7722         * support/valdiag/Makefile,
7723         * support/valdiag/valdiag.py,
7724         * support/valdiag/tests/*
7725
7726 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7727
7728         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7729         * src/SDCCsymt.c (newEnumType),
7730         * src/SDCCsymt.h
7731         * support/Util/SDCCerr.c,
7732         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7733         enum related bugs.
7734         * support/regression/tests/enum.c: added test for enum values that
7735         require at least 2 bytes of storage.
7736
7737 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7738
7739         * src/common.h: added ifndef/define/endif macros
7740         around the header file.
7741         Bug reported from Jesus Calvino-Fraga
7742
7743 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7744
7745         * sdcc.spec: updated
7746         * device/include/Makefile.in: don't install CVS directories
7747         * device/lib/Makefile.in: added removal of CVS directories after install
7748         * doc/Makefile: fixed install, added local_icons
7749         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7750         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7751         * src/ds390/gen.c (genRightShift): fixed bug #870788
7752         * src/SDCCast.c (decorateType): fixed bug #870781
7753
7754 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7755
7756         PIC16 port related changes:
7757         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7758         added variable stackPos,
7759
7760         * gen.c: genCall, assignResultValue: added support for
7761         pushing/retrieving function parameters to/from stack,
7762         genFunction,genEndFunction: setup stack frame for the
7763         generated function,
7764         genAddrOf: will be changed according to bug 863624
7765
7766         * added files genutils.c and genutils.h which contain gen*
7767         debugged and optimised functions extracted from gen.c
7768
7769         * glue.c: added variable 'externs' which holds extern symbols,
7770         pic16emitRegularMap: is modified to properly handle relocatable
7771          symbols under the new scheme,
7772         pic16createInterruptVect: is modified
7773         pic16printPublics: is modified to emit 'global' assembler directives,
7774         added pic16_printExterns to print extern symbols,
7775         pic16glue: initializes stack/frame pointer in the beginning of
7776         the assembly output. Temporary hack, will be corrected later,
7777         because gplink yet does not support stack and SDCC does not
7778         yet support a type of crt0.o object to create the final binary.
7779
7780         * Removed many lines that contain 8051 legacy code.
7781         * The code is finally placed under a 'code' directive.
7782         * Added port specific options.
7783
7784         * _process_pragma: simplified since now we do not need *special*
7785         include file to define SFR registers. But a separate header
7786         will be needed. This will be developed later.
7787         * _pic16_parseOptions: added, parses port specific options:
7788         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7789         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7790         --preplace-udata-with=
7791
7792         * _pic16_setDefaultOptions: modified to initialize section names,
7793         but hack is temporarly out of order since it needs improvement.
7794         * _pic16_genAssemblerPreamble: configuration words are emitted by
7795         their address instead of their name. This part is incomplete and
7796         supports only the 18Fxx2 devices. Other devices will emit an error
7797         during assembly since they do not contain the same set of config
7798         registers
7799         * _pic16_genIVT: is modified,
7800
7801         * pcode.c: added definitions for some hardware registers that are needed
7802         for stack support
7803         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7804         All PCI entries are updated. Now LFSR is supported.
7805         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7806         * added pic16_newpCodeOpLit2 to support instructions with
7807         two literal arguments
7808         * pic16_pCode2str: corrected code that emits assembler instructions
7809         with two literal operands and those that have an access bit modifier
7810         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7811         this fixes a bug which caused some labels to be lost, when an
7812         assembler directive was added, i.e. banksel,
7813         * pic16_FixRegisterBanking: improved logic that causes the insertion
7814         of bank switching,
7815         * InlineFunction: functions that are called once, are not any more
7816         inlined. This can be a port option in the future,
7817
7818         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7819
7820         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7821         hold the corresponding uninitialized symbols,
7822         * pic16_allocProcessorRegister: registers have explicit marked the
7823         accessBank field,
7824         * pic16_allocInternalRegister: registers are explicit marked as
7825         not used,
7826         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7827         processing list, so bit registers were lost,
7828         *
7829
7830         * ralloc.h: added field 'accessBank' and original symbol operand
7831         in register definition,
7832         * removed the field isMapped from register definition,
7833
7834         ** Several functions have been removed from various sources:
7835         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7836         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7837         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7838         pic16_assignRelocatableRegisters
7839
7840         ** others have been introduced:
7841         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7842         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7843
7844 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7845
7846         * support/scripts/inc2h.pl: changed definition of BIT_AT
7847         to emit 'sbit at' instead of 'bit at'. This was a request.
7848
7849         PIC16 port related preliminary changes:
7850         * gen.c: prefixed function popRegFromString with
7851         pic16_ and all references to it corrected
7852         * pcode.c: all pic16_pc_* hardware registers prefixed
7853         with underscore (_),
7854         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7855         * ralloc.c: newReg(): when register is REG_SFR then
7856         set address to rIdx,
7857         pic16_allocProcessorRegister(): marks register wasUsed=0
7858         pic16_writeUsedRegs(): added a call to assign processor
7859         registers via pic16_assignFixedRegisters
7860
7861 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7862
7863         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7864         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7865         variables in unused register banks.  Also the SSEG is placed
7866         wherever there is enough space for it, and IDATA can be anywhere
7867         in internal RAM.  For now compile using -Wl-Y[stack_size].
7868         The mem file is different for this option as well, since it
7869         makes no sense of talking about DSEG lenght.
7870
7871 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7872
7873         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7874         in certain cases, e.g. when ROM assignment, patch provided
7875         from Albert den Haan.
7876
7877 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7878
7879         Many signedness and type propagation fixes:
7880         * src/SDCCicode.c: made geniCodeCast() static
7881         replaced SPEC_ by IS_ (cosmetic)
7882         (operandOperation): fixed div and mod operation
7883         (usualBinaryConversions): added support for promotion of char
7884         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7885         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7886         (geniCodeAdd): an array index will stay unsigned, even if promoted
7887         from char to int
7888         (geniCodeArray): ditto
7889         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7890         * src/SDCCsymt.c (computeType): added more support for char;
7891         promotion of char is selectable by promoteCharToInt, fixed signedness
7892         for all cases
7893         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7894         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7895         * src/SDCCval (val*): replaced signedness calculation by
7896         computeType()
7897         rearranged if-branches (cosmetic)
7898         (valShift): added warning W_SHIFT_CHANGED
7899         (valCompare): fixed problem with different types
7900         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7901         * support/regression/tests/literalop.c: added many cases
7902         * support/regression/tests/ast_constant_folding.c: changed finally to
7903         'unsigned int'
7904         * .version: new year, new version: 2.3.7
7905         * src/SDCCmain.c (main): applied patch #866468
7906         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7907         provided by Scott Bronson
7908         * doc/sdccman.lyx: updated documentation for sdcdb
7909         updated and added chapter tips
7910
7911 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7912
7913         * src/SDCCsymt.h: missing from yesterday's commits
7914
7915 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7916
7917         * src/SDCC.y (struct_or_union_specifier),
7918         * support/Util/SDCCerr.c,
7919         * support/Util/SDCCerr.h: verify that struct & union tags are used
7920         as declared.
7921
7922 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7923
7924         * src/SDCCglobl.h: missing from yesterday's commits
7925
7926 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7927
7928         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7929         sft_attributes, struct_declaration, parameter_declaration,
7930         type_name, start_block, declaration_list),
7931         * src/SDCC.lex (check_type): support redefinition of typedef names
7932
7933 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7934
7935         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7936         aligned xdata arrays. Erik helped me with the if clause.
7937
7938 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7939
7940         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7941         warning
7942
7943 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7944
7945         * src/SDCCast.h,
7946         * src/SDCCast.c (newAst_),
7947         * src/SDCCicode.h,
7948         * src/SDCCicode.c (ast2iCode, newiCode),
7949         * src/SDCCglobl.h,
7950         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
7951         expr, statement, expression_statement, selection_statement,
7952         iteration_statement, expr_opt, jump_statement): foundation for tracking
7953         sequence points
7954         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
7955         point code too)
7956
7957 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7958
7959         * support/Util/SDCCerr.c,
7960         * src/SDCCast.h,
7961         * src/SDCCast.c (createCase, createDefault, decorateType),
7962         * src/SDCClabel.c (labelUnreach),
7963         * src/SDCC.y (labeled_statement, jump_statement): More improvements
7964         to error messages.
7965         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
7966         (with thanks to Stas Sergeev)
7967         * device/include/time.h,
7968         * device/lib/time.c (CheckTime): suppress unreachable code warning
7969
7970 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7971
7972         * src/SDCCast.c (createIvalCharPtr),
7973         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
7974         bug #753752)
7975         * support/regression/tests/nullstring.c: tests for these two bugs
7976
7977 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7978
7979         * support/Util/SDCCerr.h,
7980         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
7981         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
7982         about storage class and 'at' used inside struct or union
7983         * src/SDCCBBlock.c (iCodeFromeBBlock),
7984         * src/SDCCcse.c (ifxOptimize),
7985         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
7986         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
7987         printIval, emitStaticSeg, emitOverlay),
7988         * src/SDCClabel.c (deleteIfx),
7989         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
7990         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
7991         gatherAutoInit, processParms),
7992         * support/Util/SDCCerr.h,
7993         * support/Util/SDCCerr.c (werrorfl): Support for better error location
7994         reporting for post-parse errors.
7995
7996 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7997
7998         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
7999         implicit casts via union; they don't work on big endian systems
8000         (possible fix for bug #861138)
8001
8002 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8003
8004         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
8005         * src/mcs51/main.c: fixed the fix for bug #737001
8006
8007 2003-12-15  Borut Razem <borut.razem AT siol.net>
8008
8009         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
8010
8011 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8012
8013         * support/makebin/makebin.c: put output in binary mode
8014
8015 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8016
8017         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
8018         xdata and data memory on startup. Set the environment variable
8019         SDCC_NOGENRAMCLEAR to disable this.
8020         * src/mcs51/peephole.def,
8021         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
8022         (allows non-interrupt and interrupt code to safely compete for a resource
8023         without the non-interrupt code having to disable interrupts)
8024
8025 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8026
8027         * src/SDCCicode.c (geniCodeAdd),
8028         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
8029         with valFromType if type might be a pointer and host is big endian).
8030         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
8031         types, not just integer types.
8032         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
8033         multiply defined with mismatching "at" address.
8034
8035 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8036
8037         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
8038         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
8039         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
8040         with embedded nulls (fixed bug #753752)
8041
8042 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8043
8044         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
8045         Apparently this did not see much testing (endless loop)
8046
8047 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8048
8049         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
8050
8051 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8052
8053         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
8054         gracefully handle NULL memmap pointers
8055
8056 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8057
8058         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
8059         instead of deleting the iCode when an operand is volatile
8060         * src/z80/gen.c (genDummyRead),
8061         * src/mcs51/gen.c (genDummyRead),
8062         * src/ds390/gen.c (genDummyRead),
8063         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
8064         not just IC_RIGHT
8065         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
8066         * src/SDCC.y: fixed bug #850420
8067
8068 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8069
8070         Applied z80 i/o port patch from Peter Townson and fixed some operators
8071         to better handle operands in A register.
8072         * device/include/z180.h
8073         * src/SDCC.y
8074         * src/SDCCglue.c
8075         * src/z80/gen.c
8076         * src/z80/gen.h
8077         * src/z80/main.c
8078         * src/z80/peeph-z80.def
8079         * src/z80/peeph.def
8080         * src/z80/z80.h
8081
8082 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8083
8084         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
8085
8086 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8087
8088         * device/lib/hc08/_mullong.c: Removed extra #endif
8089
8090 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8091
8092         * sim/ucsim/hc08.src/inst.cc,
8093         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
8094         carries from x to h
8095         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
8096         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
8097         * device/include/stdarg.h: fixed varargs for hc08
8098         * device/lib/Makefile.in,
8099         * device/lib/hc08/Makefile,
8100         * device/lib/hc08/_mulint.c,
8101         * device/lib/hc08/_mullong.c: fixed some endian problems
8102
8103 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8104
8105         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
8106         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
8107         * device/lib/_gptrget.c,
8108         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
8109
8110 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8111
8112         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
8113         * src/SDCCast.c (astErrors): fixed bug #846007
8114         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
8115
8116 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8117
8118         * src/SDCCast.c (decorateType): disabled a transformation I added in
8119         revision 1.188 (access to fields of a structure at an absolute address);
8120         it breaks with bitfields, extern declarations, and gcse analysis.
8121         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
8122         could be assigned through a pointer, so don't complain.
8123         * src/SDCCast.c (astErrors),
8124         * src/SDCCast.h,
8125         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
8126
8127 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
8128
8129         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
8130         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
8131         output of __config directives, since gpasm now supports them
8132         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
8133         pre-processor macro, i.e. -DMCU=p18f452
8134         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
8135         and modified to handle 'cast' icode similarly to '=' icode
8136         * src/pic16/device.h (typedef struct PIC_device): added field
8137         'extMIface' to indicate that chip has external memory interface
8138         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
8139         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
8140         18F8720
8141
8142 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8143
8144         * src/SDCC.y (pointer): fixed bug #846006
8145         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
8146         * src/SDCCast.c (decorateType): fixed bug #846009
8147         * src/ds390/peeph.def,
8148         * src/ds390/gen.c (genAnd, genOr),
8149         * src/mcs51/peeph.def,
8150         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
8151
8152 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8153
8154         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
8155         * src/SDCCdflow.c
8156         * src/SDCCcse.c
8157         * src/SDCCcse.h
8158         * src/SDCCBBlock.h
8159         * src/SDCCBBlock.c
8160
8161 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
8162
8163         fixed bug #845089
8164         * src/SDCCbitv.h,
8165         * src/SDCCbitv.c: added function to free a bitvector
8166         * src/SDCClrange.h,
8167         * src/SDCClrange.c: added function to recompute the liveranges
8168         * src/avr/ralloc.c,
8169         * src/ds390/ralloc.c,
8170         * src/hc08/ralloc.c,
8171         * src/mcs51/ralloc.c,
8172         * src/pic/ralloc.c,
8173         * src/pic16/ralloc.c,
8174         * src/xa51/ralloc.c,
8175         * src/z80/ralloc.c: recompute the liveranges after register packing
8176
8177 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
8178
8179         * src/SDCCloop.c (newInduction): fixed bug #845630
8180
8181 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8182
8183         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
8184         inadvertantly left behind from my 2003-11-12 change
8185
8186 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8187
8188         Updated headers I neglected to commit yesterday.
8189         * src/SDCClrange.h,
8190         * src/SDCCicode.h
8191
8192 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8193
8194         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
8195         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
8196         * src/SDCCopt.c (eBBlockFromiCode),
8197         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
8198         the creation of the key hash table from the sequencing so it can be used
8199         earlier (for some GCSE bug fixes still pending)
8200
8201 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8202
8203         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
8204         * support/regression/tests/addsub.c: testing genPlus shortcut
8205
8206 2003-11-15  Borut Razem <borut.razem AT siol.net>
8207
8208         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
8209
8210 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8211
8212         * src/SDCCcse.c (cseBBlock): fixed bug #527779
8213         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
8214         ordering is immaterial.
8215         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
8216
8217 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8218
8219         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
8220         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
8221         (SIGSEV) of bug #840381
8222         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
8223         unlink new file before rename if new and old filenames are the same)
8224
8225 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8226
8227         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
8228         uninitialized variables) for the mcs51. Set environment variable
8229         SDCC_GENRAMCLEAR to test.
8230         xdata initialization slightly shorter
8231
8232 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8233
8234         * src/SDCCsymt.h,
8235         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
8236         #838241 & 780691 (basicly the same bug)
8237         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
8238         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
8239
8240 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
8241
8242         * src/SDCCmain.c (linkEdit): "fix" #834252
8243
8244 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8245
8246         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
8247         * src/SDCCast.h,
8248         * src/SDCC.y: fixed bug #819403
8249
8250 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8251
8252         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
8253         the reentrant attribute.
8254         * src/hc08/gen.c (genPackBits): added missing stack readjustment
8255         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
8256         simulation
8257         * src/SDCCast.c (decorateType): fixed bug with storage class not being
8258         updated during pointer dereference; f.e. ~(((char *)1)*) was being
8259         erroneously reduced to a literal.
8260         * src/hc08/ralloc.c (packRegisters, rematStr),
8261         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
8262         some cases
8263
8264 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8265
8266         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
8267         * doc/sdccman.lyx: changed from 'article' to 'book'
8268         * doc/Makefile: readded test_suite_spec and cdbfileformat
8269
8270 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
8271
8272         * device/include/stdlib.h: include malloc.h to comply with ANSI
8273         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
8274
8275 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8276
8277         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
8278         * doc/clean.mk: also remove *.out files
8279         * doc/sdccman.lyx: some additions, larger top/bottom margins
8280
8281 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8282
8283         * src/SDCC.y: fixed bug #837365
8284         * support/regression/tests/bitopcse.c
8285         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
8286         a symbol (might be valop instead)
8287         * device/lib/Makefile.in: added errno.c to HC08SOURCES
8288         * device/lib/clean.mk: added hc08 to the cleaning list
8289
8290 2003-11-04  Borut Razem <borut.razem AT siol.net>
8291
8292         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
8293           made 2003-11-04
8294         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8295           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
8296           malloc is declared in standard stdlib.h
8297
8298 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8299
8300         * device/lib/hc08/Makefile: need to clean .rel not .o files
8301         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
8302
8303 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8304
8305         * src/port.h,
8306         * src/hc08/main.c,
8307         * src/mcs51/main.c,
8308         * src/ds390/main.c,
8309         * src/z80/main.c,
8310         * src/avr/main.c,
8311         * src/pic/main.c,
8312         * src/pic16/main.c,
8313         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
8314         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
8315         tests (which uses the port's oclsExpense function)
8316         * src/SDCC.y,
8317         * src/SDCCast.c,
8318         * src/SDCCicode.c,
8319         * src/hc08/gen.c,
8320         * src/ds390/gen.c,
8321         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
8322
8323 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8324
8325         * src/SDCCcse.c (ifxOptimize),
8326         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
8327         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
8328         deleting the IFX iCode.
8329         * src/hc08/ralloc.c: reduced unneeded slocs
8330         * src/hc08/gen.c: fixed bug in asmopToBoolean
8331
8332 2003-11-04  Borut Razem <borut.razem AT siol.net>
8333
8334         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
8335           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8336           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
8337           transferred to configure
8338
8339 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
8340
8341         Use headers defined in the C[++] standards:
8342         * sim/ucsim/gui.src/serio.src/fileio.cc
8343         * sim/ucsim/gui.src/serio.src/frontend.cc
8344         * sim/ucsim/gui.src/serio.src/main.cc
8345         * sim/ucsim/gui.src/serio.src/posix_signal.cc
8346         * support/Util/NewAlloc.c
8347         * as/hc08/lklibr.c
8348         * as/mcs51/lklibr.c
8349         * as/z80/aslist.c
8350         * as/z80/assym.c
8351
8352 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8353
8354         * Added MSVC projects for hc08 assembler and linker:
8355         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
8356         /as/hc08/link_hc08.dsp
8357
8358 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
8359
8360         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
8361
8362 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
8363
8364         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
8365
8366 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8367
8368         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
8369
8370 2003-10-31  Borut Razem <borut.razem AT siol.net>
8371
8372         * support/cpp2/cpplib.h,
8373           support/cpp2/cpplib.c,
8374           support/cpp2/cpplex.c,
8375           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
8376           to switch _asm block preprocessing on / off. Default is
8377           #pragma preproc_asm +
8378
8379 2003-10-31  Borut Razem <borut.razem AT siol.net>
8380
8381         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
8382           when outputting comment blocks (when executed with -C option) and
8383           _asm (SDCPP specific) blocks
8384
8385 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8386
8387         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
8388
8389 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
8390
8391         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
8392
8393 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
8394
8395         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
8396         * src/SDCCast.c (decorateType): fixed bug #832664
8397
8398 2003-10-31  Borut Razem <borut.razem AT siol.net>
8399
8400         * support\cpp2\cpplex.c: fixed for SDCPP:
8401           comments(when executed with -C option) and _asm blocks
8402           were included even if they where in skipped #if block.
8403           Applied solution from GCC cpp 3.3.2
8404
8405 2003-10-31  Borut Razem <borut.razem AT siol.net>
8406
8407         * src/SDCC.lex: sdcc now understands both formats:
8408           '# <line_number> <file_name>' and
8409           '#line <line_number> <file_name>'
8410         * support/cpp2/cppmain.c: sdcpp now generates the standard
8411           '# <line_number> <file_name>' instead of former
8412           '#line <line_number> <file_name>'
8413
8414 2003-10-30  Borut Razem <borut.razem AT siol.net>
8415
8416         * support/cpp2/cpphash.h,
8417         * support/cpp2/cpplib.h
8418         * support/cpp2/cpplex.c,
8419         * support/cpp2/cppmain.c,
8420         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8421
8422 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8423
8424         Fixed a number of problems revealed by bug #827883.
8425         * src/SDCCloop.c (loopInvariants): Spill location of the
8426         result operand should be recomputed if extracted from
8427         a loop. Also, don't extract assignments of an iTemp
8428         from a literal.
8429         * src/SDCCast.c (isConformingBody): loop reversal should
8430         not occur if the control variable is involved with a
8431         relational operator.
8432
8433 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8434
8435         * .version: bumped to 2.3.6 to reflect the big improvements
8436         made by Erik and Klaus. Thanks!
8437
8438 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8439
8440         Replaced the livrange code.
8441         * src/SDCClrange.c: added new LR code
8442         * src/SDCCloop.c,
8443         * src/SDCCBBlock.h: removed remainig parts from old LR code
8444         * src/ds390/ralloc.c,
8445         * src/ds390/gen.c: minor fixes to make it work with new code
8446
8447 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8448
8449         * as/hc08/asm.h,
8450         * as/hc08/lkrloc.c,
8451         * src/hc08/gen.c,
8452         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8453         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8454         (tweaked fix for bug #818696)
8455
8456 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8457
8458         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8459
8460 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8461
8462         * src/SDCCmain.c,
8463         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8464         * src/mcs51/gen.c (gencjneshort),
8465         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8466         more efficient (per Scott Bronson's suggestion)
8467
8468 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8469
8470         Extended the semantics of the critical keyword to include
8471         individual statements. See RFE #827755 and #799831
8472         * src/SDCC.y
8473         * src/SDCCicode.c
8474         * src/SDCCopt.c
8475         * src/SDCCast.c
8476         * support/Util/SDCCerr.c
8477         * support/Util/SDCCerr.h
8478         * src/mcs51/gen.c
8479         * src/ds390/gen.c
8480         * src/hc08/gen.c
8481
8482 2003-10-19  Borut Razem <borut.razem AT siol.net>
8483
8484         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8485
8486 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8487
8488         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8489         Fixed bug #818696
8490         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8491         and predecrement operand is displayed
8492
8493 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8494
8495         * src/SDCCval.c (valMinus): fixed bug #826041
8496
8497 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8498
8499         Some hc08 related updates that I missed earlier
8500         * sim/ucsim/stypes.h
8501         * support/regression/ports/hc08/spec.mk
8502
8503 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8504
8505         New target "hc08" for the Motorola 68hc08 family of micros
8506
8507         * configure
8508         * configure.in
8509         * Makefile
8510         * src/hc08/*
8511         * src/SDCCmain.c
8512         * src/port.h
8513         * sim/ucsim/hc08.src/*
8514         * sim/ucsim/configure.in
8515         * src/ucsim/configure
8516         * sim/ucsim/packages_in.mk
8517         * as/hc08/*
8518         * as/Makefile
8519         * device/include/mc68hc908qy.h
8520         * device/lib/hc08/*
8521         * device/lib/Makefile.in
8522         * support/regression/ports/hc08/*
8523         * support/regression/Makefile
8524
8525 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8526
8527         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8528         regression test
8529         * src/ds390/gen.c (genCast): fixed bug #821957
8530
8531 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8532
8533         * device/lib/logf.c: "fixed" overlay bug
8534         * support/regression/ports/host/spec.mk: added m library
8535         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8536         * support/regression/tests/float_trans: added (for Eric)
8537
8538 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8539
8540         * src/mcs51/gen.c (genCpl): fixed bug
8541         http://sf.net/mailarchive/message.php?msg_id=6263915
8542
8543 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8544
8545         * src/SDCCast.c (decorateType): added extended constant folding
8546         * src/SDCCsymt.c (computeType): cleanup
8547         * src/SDCCval.c (valShift): minor optimization
8548         * support/regression/tests/ast_constant_folding.c: added
8549
8550 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8551
8552         * src/SDCCmain.c: removed some unintended changes
8553
8554 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8555
8556         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8557         * src/z80/gen.c: fixed part of bug #817589
8558         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8559
8560 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8561
8562         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8563         * src/SDCCcflow.c
8564         * src/SDCCcse.c
8565         * src/SDCCdflow.c
8566         * src/SDCClabel.c
8567         * src/SDCClrange.c
8568         * src/SDCCmem.c
8569         * src/SDCCopt.c
8570         * src/SDCCpeeph.c
8571         * src/SDCCset.c
8572         * src/avr/ralloc.c
8573         * src/ds390/ralloc.c
8574         * src/izt/ralloc.c
8575         * src/mcs51/ralloc.c
8576         * src/pic/ralloc.c
8577         * src/pic16/ralloc.c
8578         * src/xa51/ralloc.c
8579         * src/z80/ralloc.c
8580         * src/z80/gen.c: removed unused label "release:"
8581
8582 2003-10-06  Borut Razem <borut.razem AT siol.net>
8583
8584         * src/SDCC.lex: removed definition of unused variables
8585           save_optimize and save_options
8586
8587 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8588
8589         * clean.mk: removed '=' in "-maxdepth=1"
8590         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8591         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8592
8593 2003-10-06  Borut Razem <borut.razem AT siol.net>
8594
8595         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8596           my_unput() replaced by unput()
8597
8598 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8599
8600         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8601         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8602         type-punned pointer will break strict-aliasing rules"
8603         Old LR behaviour is again default; Klaus' LR can be choosen by
8604         defining the environment variable LRKLAUS
8605         * src/SDCCBBlock.h
8606         * src/SDCCloop.c
8607         * src/SDCClrange.c
8608         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8609         * clean.mk: fixed removal of files in bin/CVS/
8610         * device/lib/clean.mk: fixed removal of directories small and large
8611         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8612         * src/SDCCicode.c,
8613         * src/SDCCval.c: removed superflous test for pedantic
8614
8615 2003-10-05  Borut Razem <borut.razem AT siol.net>
8616
8617         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8618           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8619           message "unmatched #pragma SAVE and #pragma RESTORE"
8620
8621 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8622
8623         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8624           assembly, critical functions, atomic, nojtbound)
8625
8626 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8627
8628         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8629         * src/SDCCBBlock.h
8630         * src/SDCCloop.c
8631         * src/SDCCloop.h
8632         * src/SDCClrange.c
8633
8634 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8635
8636         * src/z80/gen.h,
8637         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8638         * src/mcs51/gen.h
8639         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8640         * src/ds390/gen.h
8641         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8642         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8643         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8644
8645 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8646
8647         * src/z80/gen.c (genRet): fixed bug #524753
8648         * src/z80/gen.c (genCast): fixed internal error on cast from
8649         pointer to long
8650         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8651         fix for bug #477835 to the z80
8652         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8653         for tracking iCodes in the peephole optimizer for z80
8654
8655 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8656
8657         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8658         the other part of bug #814548
8659         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8660
8661 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8662
8663         * src/SDCCcse.c: fixed part of bug #814548
8664
8665 2003-09-28  Borut Razem <borut.razem AT siol.net>
8666
8667         * src/asm.c: rewrite of printILine() to use temporary file instead
8668           a pipe
8669         * src/xa51/main.c: commented out declaration of int rewinds
8670
8671 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8672
8673         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8674
8675 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8676
8677         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8678         * src/asm.c (printILine): Fixed bug #811015
8679
8680 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8681
8682         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8683         freeing.
8684
8685 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8686
8687         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8688         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8689         to correctly handle general case of AOP_PAIRPTR
8690         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8691
8692 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8693
8694         * src/mcs51/ralloc.c (fillGaps),
8695         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8696         register positioning bug)
8697
8698 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8699
8700         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8701
8702 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8703
8704         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8705         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8706         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8707         (ralloc doesn't intentionally do this now, but perhaps later)
8708         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8709         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8710         register positioning bugs (Fixed bug #762602 and #795325)
8711         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8712         (Fixed bug #808779)
8713         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8714         lines that --i-code-in-asm generates
8715
8716 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8717
8718         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8719         trying to fclose a FILE* that was already closed.
8720
8721 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8722
8723         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8724         of const struct should be treated as if const themselves)
8725
8726 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8727
8728         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8729
8730 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8731
8732         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8733         Unix (/n) and DOS (/r/n) line terminations.
8734
8735 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8736
8737         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8738         bug #613775
8739
8740 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8741
8742         * src/mcs51/gen.c (genFunction, genEndFunction),
8743         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8744         and restore of EA so that stack offsets to parameters are
8745         correct when using both critical and reentrant/stack-auto.
8746         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8747         size (can be triggered in error if sloc is shared between
8748         different sized objects)
8749         * device/include/float.h: fixed macros to explicitly use
8750         unsigned long where needed
8751
8752 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8753
8754         Feature req. 799831: added code to allow nesting of critical functions
8755         * src/mcs51/gen.c (genFunction, genEndFunction)
8756         * src/ds390/gen.c (genFunction, genEndFunction)
8757
8758 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8759
8760         * src/SDCCsymt.c (sclsFromPtr),
8761         * src/SDCCsymt.h,
8762         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8763         support for standard C idiom of memory mapped variables; for
8764         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8765         to xdata int at 0x1234 tempvar = 1.
8766         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8767         provided by Akiya ISHIDA
8768
8769 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8770
8771         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8772         * src/SDCCval.c (constVal): added reduction from int to char
8773         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8774         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8775         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8776         to ignore the sign
8777         * support/regression/tests/shifts.c: fixed
8778
8779 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8780
8781         * src/z80/gen.c (genXor): Fixed bug #805445
8782
8783 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8784
8785         Fixed bug #621531 (const & volatile confusion in the type chain).
8786         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8787         refer to the const or volatile state of the pointer itself.
8788
8789         * src/SDCCast.c
8790         * src/SDCCglue.c
8791         * src/SDCCicode.c
8792         * src/SDCCsymt.c
8793         * src/SDCCval.c
8794         * src/SDCC.y
8795         * src/SDCCsymt.h
8796         * src/pic/gen.c
8797         * src/pic/ralloc.c
8798         * src/pic16/gen.c
8799         * src/pic16/ralloc.c
8800         * support/regression/tests/const.c
8801
8802 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8803
8804         When checking for duplicated modules, use absolute paths
8805         instead of relative paths.  Files changed:
8806
8807         * as/mcs51/lklib.c
8808         * link/z80/lklib.c
8809
8810 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8811
8812         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8813
8814 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8815
8816         * device/include/string.h: added size_t typedef, changed
8817         prototypes to use size_t, eliminated separate reentrant and
8818         non-reentrant declarations, added _memmove declaration
8819         * device/lib/_memcpy.c: changed to use size_t instead of int,
8820         changed /4 to >>2 to avoid division library call
8821         * device/lib/_memcmp.c,
8822         * device/lib/_memset.c,
8823         * device/lib/_strncat.c,
8824         * device/lib/_strncpy.c,
8825         * device/lib/_strncmp.c: changed to use size_t instead of int
8826         * device/lib/_memmove.c: new file (fixed bug #772294)
8827         * device/lib/Makefile.in: added _memmove.c
8828         * device/lib/z80/asm_strings.s: fixed bug #772290
8829         * support/regression/tests/bitfields.c: attempt to fix host assertion
8830         failure on amd64-unknown-linux2.2
8831
8832 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8833
8834         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8835         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8836         * as/z80/asmain.c (main): fixed bug #801766
8837
8838 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8839
8840         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8841         compilers
8842
8843 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8844
8845         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8846         reported in bug #800609
8847
8848 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8849
8850         * Top header beautifications in src/pic16 directory:
8851           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8852           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8853           pcoderegs.h, ralloc.c, ralloc.h
8854         * main.c: added top header and GPL license notice
8855         * pcode.c: fixed the if-conditional warning
8856
8857 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8858
8859         * device/lib/_mullong.c: replaced int by short for gcc
8860
8861 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8862
8863         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8864         and JUMPTABLE iCodes properly now (worked by accident before)
8865         * src/mcs51/gen.c (leftRightUseAcc),
8866         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8867         iCode properly now. Use getSize instead of nRegs since a & b
8868         aren't part of the nRegs tally.
8869
8870 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8871
8872         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8873         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8874           before instructions that use the _STATUS register
8875
8876 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8877
8878         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8879         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8880         fetching of the pointer
8881         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8882         copied from genNearPointerSet()
8883         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8884         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8885         If they pop r0/r1 they must be called in the opposite order than aopOp().
8886         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8887         (resp. --stack-auto), prepared for --xstack
8888
8889 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8890
8891         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8892
8893 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8894
8895         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8896         these ports have their own __sdcc_external_start()
8897
8898 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8899
8900         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8901         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8902         type for bits was changed. It resulted in bit variables becoming
8903         global, which is not permitted in PIC 14 assembly output.
8904
8905 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8906
8907         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8908
8909 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8910
8911         Z80 and MCS51 linkers complaint if a public symbol is defined
8912         in more than one library module:
8913
8914         * as/mcs51/lklib.c
8915         * link/z80/lklib.c
8916         * as/mcs51/Makefile.in
8917
8918 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8919
8920         A few small changes that speed up the peephole optimizer.
8921
8922         * src/SDCCpeeph.c
8923
8924 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8925
8926         Try to make the peephole optimizer smarter by maintaining
8927         an association between the assembly source code and the
8928         iCodes that originated them. Put this information to use
8929         with a new peephole rule condition "notVolatile" so that
8930         the rules can be aggressive yet still safe.
8931
8932         * src/SDCCpeeph.c
8933         * src/SDCCpeeph.h
8934         * src/mcs51/gen.c
8935         * src/mcs51/peeph.def
8936
8937 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8938
8939         Fixed bug #741761
8940
8941         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8942         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8943         if the left or right operand symbols have the accuse flag set.
8944
8945 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8946
8947         Changed the type of the result of the ! (NOT) operator to char;
8948         previously it returned the same type as the source. This allows
8949         us to eliminate all the genFloatNot functions (all of its target
8950         implementations were very buggy) since !float can use the same
8951         code as !long now.
8952
8953         * src/SDCCicode.c (ast2iCode): ! returns char
8954         * src/mcs51/gen.c (genNot, genNotFloat),
8955         * src/ds390/gen.c (genNot, genNotFloat),
8956         * src/z80/gen.c (genNot, genNotFloat),
8957         * src/pic/gen.c (genNot, genNotFloat),
8958         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
8959
8960 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
8961
8962         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8963         1. Interrupt would not compile properly. Ensure PCLATH register is saved
8964            during interrupts. Ensure WSAVE is located at a shared bank address.
8965         2. Fixed page selection in some places
8966         3. Fixed BTFSS/C to where necessary use registers directly and not simply
8967            the registers name strings.
8968         4. Fixed "signed / unsigned compare" compiler warnings.
8969         5. The PIC port manages its own allocation of the general purpose
8970            registers, but makes no attempt to reuse them. As a result when
8971            compiling it soon runs out of general purpose registers. Some
8972            additional code was added to the files pcode.c and device.c to walk
8973            through the function call tree and rename the registers so that they
8974            get reused.
8975
8976         * src/pic/device.c
8977         * src/pic/gen.c
8978         * src/pic/glue.c
8979         * src/pic/pcode.c
8980         * src/pic/pcode.h
8981         * src/pic/ralloc.c
8982         * src/pic/ralloc.h
8983         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
8984         genPlus() & genMinus() when the result is the same as left or right
8985
8986 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8987
8988         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
8989
8990 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8991
8992         Made bitfield a distinct type from bit so that bitfields
8993         convert as per ANSI C and bits retain their traditional
8994         boolean style behaviour. Implemented bitfield support in
8995         the z80 port.
8996
8997         * src/SDCCsymt.h,
8998         * src/SDCCsymt.c,
8999         * src/SDCCast.c,
9000         * src/cdbFile.c,
9001         * src/mcs51/gen.c,
9002         * src/ds390/gen.c: bit v bitfield split
9003         * src/z80/gen.c: New support for bitfields
9004         * support/regression/tests/bitfields.c: reenabled z80,
9005         added more tests
9006
9007 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9008
9009         Rules 246.x, 247.x relate to bitfields, the others speed up
9010         access to xdata mapped I/O devices.
9011
9012         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
9013
9014 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9015
9016         Cleaned up genPackBits and genUnpackBits and added two helper
9017         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
9018         for literal assignments in genPackBits (thanks to Frieder for
9019         reminding me).
9020
9021         * src/mcs51/gen.c
9022         * src/ds390/gen.c
9023
9024 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9025
9026         Fixed bug #748310 (pointer to function type mishandled when the
9027         function name is omitted). Also fixed a SIGSEGV when a function
9028         attribute (reentrant, etc) is used on a non-function or on a
9029         function but misplaced before the parameter list.
9030
9031         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
9032         bug #748310
9033         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
9034         * support/Util/SDCCerr.h,
9035         * support/Util/SDCCerr.c: Added func attr misuse error msg
9036
9037 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9038
9039         Fixed bug #787649 by anonymous
9040         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
9041         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
9042
9043 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9044
9045         Fixed numerous bitfield problems.
9046
9047         * src/SDCC.y: More bitfield related error checking
9048         * src/SDCCsymt.h,
9049         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
9050         * support/Util/SDCCerr.h,
9051         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
9052         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9053         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9054         * support/regression/tests/bitfields.c: tests added
9055
9056 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9057
9058         Made the constant following the "interrupt" keyword optional. If
9059         omitted, the function will not automatically be given an entry
9060         in the interrupt vector table (similar to #pragma NOIV, but
9061         less syntacticly kludgy). The interrupt number is also now
9062         range checked. Also fixed a bug in the high order bit example
9063         in the manual.
9064
9065         * src/SDCC.y
9066         * src/SDCCmem.c
9067         * src/SDCCglue.c
9068         * src/SDCCsymt.h
9069         * support/Util/SDCCerr.c
9070         * support/Util/SDCCerr.h
9071         * doc/sdccman.lyx
9072
9073 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9074
9075         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
9076         * src/SDCCicode.c (operandOperation): rewritten some ops
9077         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
9078         * src/SDCCsymt.c (computeType): literals are handled the same way as any
9079         other type
9080         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
9081         be re-activated by defining REDUCE_LITERALS)
9082         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
9083         unsigned, but are signed by default
9084         * src/SDCCval.c (constVal): rearranged
9085         * src/SDCCval.c (valMod): preliminary fix
9086         * src/SDCCval.c (valCastLiteral): use TYPE_* types
9087         * support/regression/literalop.c: added, work in progress
9088
9089 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9090
9091         Generate warnings for useless declarations like "char data;"
9092         that don't do what new users expect.
9093
9094         * src/SDCC.y
9095         * support/Util/SDCCerr.h
9096         * support/Util/SDCCerr.c
9097
9098 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
9099
9100         * src/SDCCval.c (valMult): fix overflow detection of negative int
9101
9102 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9103
9104         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
9105
9106         Changes to support big endian targets:
9107
9108         * src/ports.h
9109         * src/SDCCglue.c
9110         * src/avr/main.c
9111         * src/ds390/main.c
9112         * src/izt/i186.c
9113         * src/mcs51/main.c
9114         * src/pic/main.c
9115         * src/pic16/main.c
9116         * src/xa51/main.c
9117         * src/z80/main.c
9118
9119 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
9120
9121         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
9122         * device/lib/time.c: fixed warning "integer overflow in expression"
9123
9124 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
9125
9126         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
9127         * src/SDCCval.c (constVal): changed default to signed; hex and octal
9128         constants are unsigned; added recognition of "u" flag for unsigned
9129         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
9130         * src/SDCCval.c (valDiv, valMod): fixed signdness
9131         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
9132         signedness of modulo, left and right shift
9133         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
9134         * support/Util/SDCCerr.h: added warning W_INT_OVL
9135         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
9136         * src/SDCCast.c (ast_print): improved output of constants
9137
9138 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9139
9140         Fixed some warnings when building with MSVC:
9141
9142         * as\mcs51\asdata.c
9143         * as\z80\asdata.c
9144         * as\mcs51\asm.h
9145         * as\z80\asm.h
9146         * link\z80\aslink.h
9147         * link\z80\lkdata.c
9148         * link\z80\lkeval.c
9149         * link\z80\lkgb.c
9150         * link\z80\lkihx.c
9151         * link\z80\lks19.c
9152         * link\z80\lksym.c
9153         * support\cpp2\cpplib.c
9154         * src\ds390\gen.c
9155         * src\mcs51\gen.c
9156
9157 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
9158
9159         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
9160
9161 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9162
9163         * support\librarian\clean.mk: Do not remove Makefile.
9164         * support\librarian\Makefile: added.
9165
9166 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9167
9168         Added librarian to MSVC build:
9169         * all.dsp
9170         * sdcc.dsw
9171         * support\librarian\librarian.dsp
9172
9173         'configure' not needed for librarian, removed:
9174         * support\librarian\configure
9175         * support\librarian\configure.in
9176         * support\librarian\config_in.h
9177         * support\librarian\Makefile.in
9178
9179         Hopefully these ones built the librarian and the rest of sdcc properly:
9180         * Makefile
9181         * Makefile.common.in
9182
9183         Messed up 'configure', so revert to previous version:
9184         * configure
9185         * configure.in
9186
9187 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
9188
9189         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
9190         there, while the mantissa of a double is "only" 53 bits wide.
9191
9192 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9193
9194         Adding sdcclib to the build.  MSVC project coming soon.
9195         Files added/changed:
9196
9197         * support\librarian\clean.mk
9198         * support\librarian\configure
9199         * support\librarian\configure.in
9200         * support\librarian\config_in.h
9201         * support\librarian\Makefile.bcc
9202         * support\librarian\Makefile.in
9203         * support\librarian\sdcclib.c
9204         * Makefile.bcc
9205         * Makefile
9206         * Makefile.common.in
9207         * configure
9208         * configure.in
9209
9210 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9211
9212         Linker now complaints if linked modules have conflicting options, for
9213         example, one compiled using --model-large and another one compiled with
9214         --model-small.  The following files were modified:
9215
9216         * as\mcs51\asdata.c
9217         * as\mcs51\aslink.h
9218         * as\mcs51\asm.h
9219         * as\mcs51\asmain.c
9220         * as\mcs51\asout.c
9221         * as\mcs51\i51pst.c
9222         * as\mcs51\lkdata.c
9223         * as\mcs51\lklibr.c
9224         * as\mcs51\lkmain.c
9225         * as\z80\asdata.c
9226         * as\z80\asm.h
9227         * as\z80\asmain.c
9228         * as\z80\asout.c
9229         * as\z80\z80pst.c
9230         * link\z80\aslink.h
9231         * link\z80\lkdata.c
9232         * link\z80\lklibr.c
9233         * link\z80\lkmain.c
9234         * src\SDCCglue.c
9235
9236 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9237
9238         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
9239         as/mcs51/lklibr.c: Generate a warning when a library is not found.
9240
9241 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
9242
9243         * src/z80/mappings.i: fix _mul[us][int,long] entries
9244
9245 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9246
9247         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
9248
9249 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9250
9251         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
9252         * support/regression/tests/bitopcse.c: added
9253         fixed warning:
9254         * src/avr/gen.c:
9255         * src/pic/gen.c:
9256         * src/pic16/gen.c:
9257         * src/z80/gen.c:
9258         * src/xa51/gen.c:
9259
9260 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9261
9262         added support for new library format to z80, gbz80 linkers:
9263         *link/z80/aslink.h
9264         *link/z80/lklex.c
9265         *link/z80/lklib.c
9266         *link/z80/lklist.c
9267
9268 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9269
9270         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
9271         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
9272
9273 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
9274
9275         added DUMMY_READ_VOLATILE:
9276         * src/SDCC.y:
9277         * src/avr/gen.c:
9278         * src/xa51/gen.c:
9279         * src/z80/gen.c:
9280         * src/pic/gen.c:
9281         * src/pic16/gen.c:
9282         * src/mcs51/gen.c:
9283         * src/ds390/gen.c:
9284         * src/SDCCcse.c (algebraicOpts): many improvements
9285         * src/SDCCcse.h: removed algebraicOpts()
9286         * src/SDCCicode.c (picDummyRead): added
9287
9288 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9289
9290         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
9291         "Insufficient space in data memory".
9292
9293 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9294
9295         * src/mcs51/gen.c: fixed bug #771358
9296         * src/z80/gen.c: fixed bug #759087
9297
9298 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
9299
9300         * src/pic16/glue.c: minor cleanup by Vangelis
9301
9302 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9303
9304         * device/include/regc515c.h: fixed #758477
9305         * device/lib/_gptrget.c: saving some cycles in generic pointer get
9306         * device/lib/_gptrput.c: saved a few bytes
9307         * my tab spacing is 8, yours too?)
9308         * device/lib/_ser.c: process RX bytes earlier than TX bytes
9309         * device/lib/serial.c: process RX bytes earlier than TX bytes
9310         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
9311
9312 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9313
9314         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
9315
9316 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9317
9318     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
9319
9320 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
9321
9322         * device/lib/Makefile.in: bad fix, reverted to 1.43
9323
9324 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
9325
9326         * device/lib/Makefile.in: added missing z80 object files
9327
9328 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
9329
9330         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
9331         pic16 progress by Vangelis:
9332         * src/SDCCglobl.h:
9333         * src/SDCCmain.c:
9334         * src/pic/Makefile:
9335         * src/pic:
9336         * pic/Makefile:
9337         * pic16/device.c:
9338         * pic16/device.h:
9339         * pic16/gen.c:
9340         * pic16/gen.h:
9341         * pic16/genarith.c:
9342         * pic16/glue.c:
9343         * pic16/main.c:
9344         * pic16/pcode.c:
9345         * pic16/pcode.h:
9346         * pic16/pcodepeep.c:
9347         * pic16/peeph.def:
9348
9349 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9350
9351     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
9352
9353 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9354
9355     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
9356     added gbz80 build to MSVC project.
9357     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
9358     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
9359     from 8051 stuff and setup so it links using a .lnk file.
9360
9361 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9362
9363     * support/librarian/sdcclib.c: sdcc librarian.
9364     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
9365     with sdcclib.
9366
9367 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9368
9369     * as/mcs51/lkmain.c: properly handle extensions in function afile.
9370
9371 2003-07-02  Borut Razem <borut.razem AT siol.net>
9372
9373         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
9374         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
9375         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
9376         src/xa51/main.c, src/z80/main.c:
9377         virtualization of glue() function: each port has it's own glue function,
9378         which is accessed by do_glue function pointer in PORT.general structure
9379
9380 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
9381
9382         * DS800C400 fun, improved ROM interface and tinibios.
9383
9384 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
9385
9386         * More support for DS80C400. Now includes beginning of interface to ROM.
9387
9388 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
9389
9390         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
9391
9392 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9393
9394         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
9395
9396 2003-06-19  Borut Razem <borut.razem AT siol.net>
9397
9398         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
9399
9400 2003-06-19  Borut Razem <borut.razem AT siol.net>
9401
9402         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
9403         fixed Z80 port - crt0.o: cannot open.
9404
9405 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
9406
9407         * support/Util/MySystem.c (merge_command): revert bad fix
9408
9409 2003-06-18  Borut Razem <borut.razem AT siol.net>
9410
9411         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9412
9413 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9414
9415         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9416         option --use-stdout sends errors to stdout instead of stderr.
9417
9418 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9419
9420         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9421
9422 2003-06-15  Borut Razem <borut.razem AT siol.net>
9423
9424         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9425         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9426         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9427         fixed width array of pointers replaced with sets;
9428         multiple include and lib paths ared transferred to preprocessor and linker
9429         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9430         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9431         fixed width array of pointers
9432         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9433         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9434         fixupPath(), getPathDifference()
9435         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9436         fixed width array of pointers
9437
9438 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9439
9440         * src/pic16/ralloc.c: fix warnings
9441         * src/pic16/pcode.c: fix warning
9442
9443 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9444
9445          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9446         know all the details, but essentially this set of changes enable
9447         the pic16 port to generate movff instructions and generate assembler
9448         directives,
9449         * src/SDCCmain.c:
9450         * src/pic16/gen.c:
9451         * src/pic16/glue.c:
9452         * src/pic16/pcode.c:
9453         * src/pic16/device.c:
9454         * src/pic16/main.c:
9455         * src/pic16/pcode.h:
9456         * src/pic16/pcoderegs.c:
9457         * src/pic16/ralloc.c:
9458         * src/pic16/ralloc.h:
9459
9460 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9461
9462         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9463         added option --vc, so sdcc errors and warnings are compatible with
9464         Microsoft Visual Studio.
9465
9466 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9467
9468         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9469           device/lib/libfloat.lib: added atof function.
9470
9471 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9472
9473         * doc/sdccman.lyx: updated to Lyx 1.3
9474         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9475         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9476         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9477
9478 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9479
9480         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9481
9482 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9483
9484         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9485           additions to the "related tools/documentation" section
9486
9487 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9488
9489         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9490
9491 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9492
9493         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9494         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9495
9496 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9497
9498         * doc/sdccman.lyx: fix double dash and other minor things
9499         * doc/Makefile: fix double dash
9500
9501 2003-05-28  Karl Bongers(patches from Martin Helmling)
9502         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9503           condition and ignore commands.
9504
9505 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9506
9507         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9508           is in parts still quite out of date, I did changes as far as I felt makes sense
9509           for a non-native english speaker.
9510           Please feel free to add to the manual or to correct my changes.
9511         * doc/Makefile: undid touching the date of intermediate tex files.
9512
9513 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9514
9515         * doc/sdccman.lyx: Manual has an index now
9516
9517 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9518
9519         Finalize muluint/mulsint and mululong/mulslong merging:
9520         * device/lib/_mulint.c
9521         * device/lib/_mullong.c
9522         * device/lib/gbz80/mul.s
9523         * device/lib/gbz80/stubs.s
9524         * device/lib/z80/mul.s
9525         * device/lib/z80/stubs.s
9526         * src/SDCCsymt.c (initCSupport)
9527
9528 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9529
9530         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9531         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9532           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9533           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9534           instead of /Zm500.
9535
9536 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9537
9538         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9539           the regression tests I'm not brave enough to enable 245.b, 245.c
9540         * doc/sdccman.lyx: added latex preamble for hyperref package.
9541           Using pdflatex this will give you a hyperlinked pdf file with
9542           bookmarks. (prepend '%' before /usepackage if this breaks something)
9543
9544 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9545
9546          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9547
9548 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9549
9550         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9551
9552 2003-05-21    <johan AT balder>
9553
9554         * src/SDCCglue.c (printIval): fixed bug #739934
9555
9556 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9557
9558         Applied patch from bug 737905 (renamed yylineo to mylineno):
9559         * src/altlex.c
9560         * src/SDCCast.c
9561         * src/SDCglobl.h
9562         * src/SDCC.lex
9563         * src/SDCCsymt.c
9564         * src/SDCCval.c
9565         * src/pic16/pcode.c: Cleaned warnings
9566         * src/pic16/pcodeflow.c: Cleaned warnings
9567         * src/pic16/pcoderegs.c: Cleaned warnings
9568
9569 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9570
9571         * src/pic16/pcode.c: Cleaned warnings
9572         * src/pic16/pcodepeep.c: Cleaned warnings
9573         * src/pic16/ralloc.c: Cleaned warnings
9574
9575 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9576
9577         * doc/sdccman.lyx: fixed bug 739745
9578         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9579
9580 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9581
9582         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9583         it can be defined with CFLAGS when running configure
9584         * src/SDCCmain.c: fixed compiling + linking with object files
9585
9586 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9587
9588         * configure.in: configure for pic16 port,
9589             added --disable-pic16-port
9590         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9591         * src/SDCCmain.c: linkOptions is changed to set *,
9592             added if/endif conditional macros to remove options help
9593             messages from optionsTable when a port is not configured, added
9594             support for the PIc16 port in the ports table, when executing
9595             the compiler with no port specified on command line, a default
9596             port is selected with the new macro DEFAULT_PORT which is
9597             defined in port.h, in setDefaultOptions() linkOptions is removed
9598             from initialization assignment, since now it is a set,
9599             parseCmdLine uses setParseWithComma for linkOptions, in
9600             linkEdit() linkOptions are accessed with new function indexSet()
9601             which returns the i'th item of a set variable. See SDCCset.c, in
9602             linkEdit() when calling buildCmdLine(), added linkOptions as
9603             last argument. Now users can pass arguments to gplink via the
9604             -Wl option, main() uses pic16glue() to glue up pic16 programs
9605         * src/SDCCpeeph.c: various changes to support pic16
9606         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9607             return the i'th item of the set
9608         * src/SDCCset.h: added function prototype for indexSet()
9609         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9610         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9611         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9612             added macro DEFAULT_PORT
9613         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9614         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9615             generated
9616         * src/pic16/glue.c: commented out some error producing lines
9617         * src/pic16/main.c: __config directives are commented out to stop
9618             gpasm complaining and test the linkage with gplink, _linkCmd and
9619             _asmCmd changed to be more gplink and gpasm friendly
9620         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9621             produced an error when parsed, peep rule 12 is added to utilize
9622             movff, but it is commented out since the pCode does not support
9623             yet a command with 2 address arguments
9624
9625 2003-05-18    <johan AT balder>
9626
9627         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9628         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9629 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9630
9631         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9632   Added feature to script commands from file.
9633
9634 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9635
9636         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9637         * src/SDCCutil.c: include ctype.h for win32
9638
9639 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9640
9641         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9642
9643 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9644
9645         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9646   Fixed so you can set breakpoints prior to run, run does not stop
9647   on entry now.  Add tbreak.  Other enhancements and fixes for use
9648   with ddd.
9649
9650 2003-05-12  Borut Razem <borut.razem AT siol.net>
9651
9652         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9653
9654 2003-05-11  Borut Razem <borut.razem AT siol.net>
9655
9656         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9657         the path of bin directory, so that PATH is the only env. variable, which has to be set
9658         in case of standard installation.
9659         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9660         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9661         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9662
9663 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9664
9665         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9666         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9667         temp files are in the port dir; clean the gen/test directory when
9668         generating new test.c
9669         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9670         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9671         * support/regression/tests/zeropad.c: added
9672
9673 2003-05-09    <johan AT balder>
9674
9675         * src/SDCCglue.c: fixed bug #597940
9676
9677 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9678
9679         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9680   cache sfr, optimize next,step, fix off by one sourceline,
9681   support ddd list function.
9682         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9683
9684 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9685
9686         * support/regression/HTMLgen.py: added compare_s2f()
9687         * support/regression/Makefile: redo 1.27
9688         * support/regression/generate-cases.py: redo 1.5
9689
9690 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9691
9692         * support/regression/tests/float.c: workaround 33 bit hex constant
9693         * support/regression/tests/simplefloat.c: fix division for host
9694
9695 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9696
9697         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9698         that tame's the PIC's over-aggressive optimizer.
9699
9700 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9701
9702          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9703          support for MSVC.
9704
9705 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9706
9707         Initial support for DS80C400. "Hello world" runs on TINIm400
9708         (with polled I/O).
9709
9710 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9711
9712          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9713          * Some notes on ddd usage added in debugger/README
9714          Martin Helmling adding more features and fixes for ddd GUI debugger.
9715          Code added for nexti, stepi, up, down, and other adjustments.
9716
9717 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9718
9719         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9720         * src/pic/peeph.def Added two rules to optimize carry manipulation
9721         * src/pic/* removed debug printfs
9722
9723 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9724
9725         * debugger/mcs51/cmd.c: added header newalloc.h
9726
9727 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9728
9729         * as/Makefile: new EXEEXT
9730         * as/z80/Makefile: remove trailing slash of BUILDIR
9731         * as/z80/clean.mk: new EXEEXT
9732         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9733         * support/cpp2/Makefile.in: new EXEEXT
9734         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9735
9736 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9737
9738         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9739         EXEEXT was introduced to fix all related problems with targets
9740         "clean", "install" and "uninstall"; a couple of further flaws
9741         especially with "clean" have been fixed too
9742         * as/mcs51/Makefile.in
9743         * as/mcs51/clean.mk
9744         * as/z80/Makefile
9745         * Makefile
9746         * clean.mk
9747         * debugger/mcs51/Makefile.in
9748         * debugger/mcs51/clean.mk
9749         * link/z80/Makefile
9750         * link/z80/Makefile.in
9751         * link/z80/clean.mk
9752         * link/Makefile
9753         * packihx/Makefile.in
9754         * packihx/clean.mk
9755         * sim/ucsim/Makefile
9756         * sim/ucsim/clean.mk
9757         * sim/ucsim/avr.src/Makefile.in
9758         * sim/ucsim/avr.src/clean.mk
9759         * sim/ucsim/s51.src/Makefile.in
9760         * sim/ucsim/s51.src/clean.mk
9761         * sim/ucsim/xa.src/Makefile.in
9762         * sim/ucsim/xa.src/clean.mk
9763         * sim/ucsim/z80.src/Makefile.in
9764         * sim/ucsim/z80.src/clean.mk
9765         * sim/ucsim/main_in.mk
9766         * sim/ucsim/packages_in.mk
9767         * sim/ucsim/gui.src/Makefile.in
9768         * sim/ucsim/gui.src/serio.src/Makefile.in
9769         * sim/ucsim/gui.src/serio.src/clean.mk
9770         * src/Makefile.in
9771         * src/clean.mk
9772         * support/cpp2/Makefile.in
9773         * support/cpp2/clean.mk
9774         * support/makebin/Makefile
9775         * support/makebin/clean.mk
9776         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9777         * doc/sdccman.lyx: --program-suffix no longer needed
9778
9779 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9780
9781          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9782          Martin Helmling added support for ddd GUI debugger.
9783          Code added to display assembly, set variables, and other commands
9784          to interface to ddd.
9785
9786 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9787
9788         * as/Makefile: fix target clean
9789         * as/clean.mk: fix target clean
9790         * as/z80/clean.mk: fix target clean
9791
9792 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9793
9794         * Makefile.common.in: added  AT EXEEXT AT
9795         * configure.in: removed all mingw32 stuff
9796         * configure: rebuilt from configure.in
9797         * doc/sdccman.lyx: updated section "installation"
9798         * support/scripts/sdcc_mingw32: adapted to configure
9799         * support/scripts/sdcc_cygwin_mingw32: added
9800
9801 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9802
9803         * src/pic Added object file support for the PIC port
9804         * src/pic Applied patch from Craig Franklin (this started the object file support)
9805         * src/regression Updated the PIC regression tests for object files
9806
9807 2003-04-20  Borut Razem <borut.razem AT siol.net>
9808
9809         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9810           lklex.c: In function `getfid':
9811           lklex.c:203: warning: array subscript has type `char'
9812         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9813           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9814         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9815           stack handling macros
9816
9817 2003-04-19  Borut Razem <borut.razem AT siol.net>
9818
9819         * "handling space characters in file path" task:
9820         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9821         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9822         * support/Util/MySystem.h: make it self-sufficient
9823         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9824           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9825           handling space characters in file path
9826         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9827           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9828         * support/Util/MySystem.c: handling space characters in executable's path
9829
9830 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9831
9832         * as/z80/Makefile: fix permanent rebuild of z80
9833         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9834         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9835
9836 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9837
9838         * src/SDCCopt.c: add special case optimization to replace modulo by
9839           a power of two with a bitwise AND.
9840
9841 2003-04-18    <johan AT balder>
9842
9843         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9844
9845 2003-04-17    <johan AT balder>
9846
9847         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9848         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9849
9850 2003-04-13  Borut Razem <borut.razem AT siol.net>
9851
9852         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9853         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9854           fixed mingw problem in adl_NORMALIZE_PATH
9855
9856 2003-04-12  Borut Razem <borut.razem AT siol.net>
9857
9858         * fixed "#pragma SAVE/RESTORE can not be nested":
9859         * src/SDCC.lex: reworked pragma handling functions
9860         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9861         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9862
9863 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9864
9865         * src/SDCCutil.c (pathEquivalent): defined but not used
9866         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9867         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9868         * configure: rebuilt from configure.in
9869         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9870         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9871         * device/include/Makefile.in: replace sdcc_datadir
9872         * device/lib/Makefile.in: replace sdcc_datadir
9873         * Makefile.common.in: add LDFLAGS from configure
9874         * packihx/Makefile.in: use LDFLAGS
9875         * src/Makefile.in: use LDFLAGS
9876         * support/cpp2/Makefile.in: add LDFLAGS from configure
9877         * support/makebin/Makefile: use LDFLAGS
9878         * .version: bumped version number to 2.3.5
9879
9880 2003-04-12  Borut Razem <borut.razem AT siol.net>
9881
9882         * completed "different paths" task:
9883         * src/SDCCmacro.c: fixed bug in handling quotes
9884         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9885         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9886
9887 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9888
9889         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9890
9891 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9892
9893         * ds390/gen.c ds390/peeph.def: fix bug 706781
9894
9895 2003-04-11  Borut Razem <borut.razem AT siol.net>
9896
9897         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9898
9899 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9900
9901         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9902         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9903          set - this bit used to not be set...).
9904         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9905           bad code in PIC Port
9906         * src/regression/and2.c added to test bug 609268
9907         * src/regression/Makefile added and2.c to regression test
9908
9909
9910 2003-04-08    <johan AT CP255758-A>
9911
9912         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9913         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9914         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9915
9916 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9917
9918         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9919         fix bug #487815
9920         * support/cpp2/Makefile.in: fix bug #487815
9921         * configure: rebuilt from configure.in
9922         * Makefile.common.in: docdir changed, new path suffixes
9923         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9924         * sdcc_vc_in.h: reflect changes from sdccconf.h
9925         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9926         * src/SDCCutil.h: remove BINDIR hack
9927         * doc/sdccman.lyx: update new path hierarchy
9928
9929 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9930
9931         * src/SDCCpeeph.c: added okToRemoveSLOC test
9932
9933 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9934
9935         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9936
9937 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9938
9939         * src/SDCCpeeph.c: added labelIsReturnOnly test
9940         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9941
9942 2003-04-05    <johan AT balder>
9943
9944         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
9945         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
9946         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
9947         * src/SDCCast.c: fixed a warning
9948         * src/SDCCast.h: fixed a warning
9949         * src/SDCCicode.c (operandFromAst): fixed a warning
9950
9951 2003-04-04    <johan AT balder>
9952
9953         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
9954         * src/SDCCast.c (decorateType): fixed bug #715076
9955         * src/SDCC.y: fixed bug #702907
9956
9957 2003-04-03    <johan AT balder>
9958
9959         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
9960         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
9961         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
9962         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
9963         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
9964
9965 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
9966
9967         * _decdptr.c: fix return values
9968         * _gptrget.c: fix return values
9969         * _gptrgetc.c: fix return values
9970         * _gptrput.c: fix return values
9971         * _mulint.c: fix return values
9972         * as/z80/Makefile: fix 'make -j' problem
9973
9974 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
9975
9976         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
9977         * configure.in: big cleanup, updated to autoconf 2.5x
9978         * configure: rebuilt from configure.in
9979         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9980         * sdcc_vc_in.h: reflect changes from sdccconf.h
9981         * doc/Makefile: fixed a flaw in "make install"
9982
9983 2003-04-02    <johan AT balder>
9984
9985         * src/ds390/gen.c (genCmp): no comments
9986         * src/mcs51/gen.c (genCmp): no comments
9987         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
9988         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
9989
9990 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
9991
9992         * support/regression/generate-cases.py: place generated file in given sub directory
9993         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
9994         * support/regression/Makefile: improvements for 'make -j';
9995         side effect: it's simpler and faster now
9996
9997 2003-03-31  Borut Razem <borut.razem AT siol.net>
9998
9999         * src/z80/main.c: link-{port} and as-{port} defined without path
10000         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
10001
10002 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
10003
10004         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
10005
10006 2003-03-30  Borut Razem <borut.razem AT siol.net>
10007
10008         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
10009           changed type of list parameter to set
10010         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
10011         * src/port.h: changed type of do_assemble() parameter to set
10012         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
10013           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
10014           definition of "cppoutfilename" macro with NULL value in preProcess()
10015         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
10016         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
10017         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
10018           replaced with set *binPathSet
10019         * shash_add() deallocates the item, if allready exsists, before adding the new one
10020         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
10021
10022 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
10023
10024         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
10025           a nested for loop bug in the PIC port
10026         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
10027           for loops
10028
10029 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
10030
10031         * support/Util/dbuf.h: remove C++ stuff to make it portable
10032
10033 2003-03-28  Borut Razem <borut.razem AT siol.net>
10034
10035         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
10036           literal strings in stringLiteral()
10037         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
10038         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
10039           to the project
10040
10041 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
10042
10043         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
10044
10045 2003-03-26    <johan AT balder>
10046
10047         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
10048         * src/ds390/gen.c (saveRegisters): catched symbol abuse
10049         * src/SDCCast.c (decorateType): fixed " -v < 3"
10050
10051 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
10052
10053         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
10054         Added Lenny Story's debug infrastructure changes:
10055         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
10056         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
10057         * src/cdbFile.c: added
10058         * src/SDCCdebug.c: added
10059         * src/SDCCdebug.h: added
10060         * src/SDCCast.c (createFunction)
10061         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
10062         * src/SDCCmain.c (parseCmdLine, main)
10063         * src/SDCCmem.c (redoStackOffsets)
10064         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
10065         * src/SDCCsymt.h
10066         * src/common.h
10067         * src/avr/gen.c (genAVRCode)
10068         * src/ds390/gen.c (gen390Code)
10069         * src/mcs51/gen.c (gen51Code)
10070         * src/pic/gen.c (genpic14Code)
10071         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
10072         * src/xa51/gen.c (genXA51Code)
10073         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
10074
10075 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10076
10077         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
10078         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
10079
10080 2003-03-22    <johan AT balder>
10081
10082         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
10083
10084 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
10085
10086         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
10087         * doc/cdbfileformat.lyx: added, written by Lenny Story
10088         * doc/Makefile: added cdbfileformat.lyx
10089         * doc/clean.mk: added cdbfileformat.lyx
10090
10091 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
10092
10093         * src/mcs51/peeph.def: fix bug #705773
10094
10095 2003-03-20    <johan AT balder>
10096
10097         An sfr/sbit can have an "at #" AND an initializer
10098         * src/SDCCsymt.c (checkSClass):
10099         * src/SDCCmem.c (allocGlobal):
10100         * src/SDCCmem.c (allocLocal):
10101         * src/SDCCast.c (createBlock):
10102
10103 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
10104
10105         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
10106
10107 2003-03-16    <johan AT balder>
10108
10109         Undid the hackup of const and volatile, the problem is much bigger
10110         * src/SDCC.y:1.65
10111         * src/SDCCast.c:1.171
10112         * src/SDCCglue.c:1.138
10113         * src/SDCCicode.c:1.146
10114         * src/SDCCsymt.c:1.150
10115         * src/SDCCval.c:1.65
10116
10117 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
10118
10119         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
10120         * src/ds390/gen.c (genAddrOf): fixed bug #704087
10121
10122 2003-03-13    <johan AT balder>
10123
10124         Hackup const and volatile modifiers in type chains a bit:
10125         * src/SDCC.y:1.63
10126         * src/SDCCast.c:1.169
10127         * src/SDCCglue.c:1.136
10128         * src/SDCCicode.c:1.143
10129         * src/SDCCsymt.c1.146
10130         * src/SDCCsymt.h1.59
10131         * src/SDCCval.c:1.63
10132
10133 2003-03-12    <johan AT balder>
10134
10135         * src/SDCCBBlock.h: more LRH debugging junk
10136         * src/SDCCcflow.h: more LRH debugging junk
10137         * src/SDCCloop.c: more LRH debugging junk
10138         * src/SDCC.y (struct_declaration): fixed bug #697590
10139         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
10140         * src/ds390/gen.c (aopForRemat): fixed bug #700031
10141         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
10142
10143 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10144         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
10145         test function names must now match exactly).
10146         * src/SDCCcse.c: added special case in findCheaperOp to allow
10147         extending a short integer. Makes less awful code for bug 700121 test case.
10148
10149 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10150
10151         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
10152         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
10153
10154 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10155
10156         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
10157         actually called (operandsNotEqual() was called for all
10158         operandsNotEqualX tests).
10159
10160 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10161
10162         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
10163         with shorter literals. Fixes bug 700121.
10164
10165 2003-03-11    <johan AT balder>
10166
10167         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
10168
10169 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
10170
10171         * src/SDCCloop.c (mergeRegions): an evil beast is dead
10172         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
10173
10174 2003-03-10  Borut Razem <borut.razem AT siol.net>
10175
10176         * src/SDCCmain.c: pipe preprocessor's output
10177         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10178         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10179         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10180         which closes all pipes in pipeSet set
10181         * src/SDCCset.c: free deleted item in function deleteSetItem()
10182         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10183         moved from z80 to src subproject
10184         * .version: increased version number to 2.3.4
10185
10186 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
10187
10188         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
10189         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
10190         * support/regression/ports/xa51/spec.mk: fix typo
10191
10192 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
10193
10194         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
10195
10196 2003-03-09  Borut Razem <borut.razem AT siol.net>
10197
10198         * src/SDCCmain.c: pipe preprocessor's output
10199         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10200         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10201         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10202         which closes all pipes in pipeSet set
10203         * src/SDCCset.c: free deleted item in function deleteSetItem()
10204         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10205         moved from z80 to src subproject
10206
10207 2003-03-09  Borut Razem <borut.razem AT siol.net>
10208
10209         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
10210         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
10211         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
10212         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
10213         * src/SDCCglobl.h: unification of WIN32 native definitions
10214
10215 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10216
10217         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
10218
10219 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10220
10221         * src/configure.in:   check for endianess (even while cross-compiling)
10222         * src/configure:      check for endianess (even while cross-compiling)
10223         * src/configure_in.h: check for endianess (even while cross-compiling)
10224         * src/avr/gen.c:        remove old endianess stuff
10225         * src/mcs51/gen.c:      remove old endianess stuff
10226         * src/ds390/gen.c:      remove old endianess stuff
10227         * src/pic/gen.c:        remove old endianess stuff
10228         * src/pic/genarith.c:   remove old endianess stuff
10229         * src/pic/glue.c:       fix endianess check
10230         * src/pic16/gen.c:      remove old endianess stuff
10231         * src/pic16/genarith.c: remove old endianess stuff
10232         * src/pic16/glue.c:     fix endianess check
10233         * src/xa51/gen.c:       remove old endianess stuff
10234         * src/z80/gen.c:        fix endianess check
10235         * src/SDCCglue.c:       fix endianess check
10236         * src/ds390/peeph.def: fix bug 700036
10237
10238 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10239
10240         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
10241         * src/configure: find appropriate data-types on host for SDCC's int and long
10242         * src/configure.in: find appropriate data-types on host for SDCC's int and long
10243         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
10244         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
10245
10246 2003-03-07    <johan AT balder>
10247
10248         Just a big NOOP:
10249                 some minor cleanups before the big shot
10250                 OP_DEFS and OP_USES now use Kevin's protection
10251                 new option --nolabelopt
10252
10253         * src/SDCCBBlock.c:
10254         * src/SDCCast.c,:
10255         * src/SDCCcflow.c:
10256         * src/SDCCcse.c:
10257         * src/SDCCicode.c:
10258         * src/SDCCicode.h:
10259         * src/SDCClabel.c:
10260         * src/SDCCloop.c:
10261         * src/SDCCmain.c:
10262         * src/ds390/ralloc.c:
10263         * src/mcs51/ralloc.c:
10264         * src/pic/ralloc.c:
10265         * src/xa51/ralloc.c:
10266         * src/z80/ralloc.c:
10267
10268 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
10269
10270         * src/pic/pcode.c (get_op): fix 64 bit warnings
10271         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
10272         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
10273         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
10274         * support/regression/tests/malloc.c: fix 64 bit warnings
10275
10276 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
10277
10278         * src/mcs51/gen.c (genMinus): fixed bug 696436
10279
10280 2003-03-02  Borut Razem <borut.razem AT siol.net>
10281
10282         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
10283
10284 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
10285
10286         * configure.in: test for mkstemp
10287         * sdccconf_in.h: add HAVE_MKSTEMP
10288
10289 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
10290
10291         * device/include/ctype.h: removed warning while using --stack-auto
10292         * device/include/malloc.h: removed warning while using --stack-auto
10293         * device/include/string.h: removed warning while using --stack-auto
10294
10295 2003-02-23  Borut Razem <borut.razem AT siol.net>
10296
10297         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
10298         because NDEBUG is defined (see man assert)
10299         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
10300
10301 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10302
10303         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
10304         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
10305
10306 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10307
10308         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
10309         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
10310
10311 2003-02-18    <johan AT balder>
10312
10313         * as/mcs51/asmain.c (asmbl): module can start with a digit
10314         * as/z80/asmain.c (asmbl): module can start with a digit
10315
10316 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
10317
10318         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
10319         * src/asm.c: fix pipe() for Mingw32
10320
10321 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
10322
10323         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
10324         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
10325         make -V work again; --c1mode reads now from stdin
10326         * doc/sdccman.lyx: added --c1mode
10327         * support/Util/SDCCerr.c: new messages for c1 mode
10328         * support/Util/SDCCerr.h: new messages for c1 mode
10329         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
10330
10331 2003-02-15    <johan AT balder>
10332
10333         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
10334
10335 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
10336
10337         * doc/sdccman.lyx: Environment variables, -o and other minor things
10338
10339 2003-02-14    <johan AT balder>
10340
10341         * src/xa51/main.c: before anyone really tries to use it :)
10342
10343         * Install doc's in share/sdcc/doc
10344         * removed some obsolete files
10345         * Do a proper make distclean and uninstall
10346         M Makefile.common.in
10347         R sdccbuild.sh
10348         M as/Makefile
10349         M device/include/Makefile.in
10350         M device/lib/Makefile.in
10351         M doc/sdccman.lyx
10352         M link/Makefile
10353         M sim/ucsim/doc/Makefile.in
10354         M src/clean.mk
10355         R src/avr/peeph.rul
10356         R src/xa51/peeph.rul
10357         M support/cpp2/Makefile.in
10358         M support/makebin/Makefile
10359
10360
10361 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
10362
10363         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
10364
10365 2003-02-10  Borut Razem <borut.razem AT siol.net>
10366
10367         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
10368         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
10369         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
10370         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
10371         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
10372         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
10373         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
10374         src/z80/Makefile.bcc: Borland Makefile cleanup
10375         * as/z80/Makefile.bcc: Added Borland Makefile
10376         * support/cpp2/borland.h: Removed
10377
10378 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
10379
10380         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
10381         * src/SDCC.lex: new pragma NOIV
10382         * src/SDCCglobl.h: new pragma NOIV
10383         * src/SDCCmem.c: new pragma NOIV
10384
10385 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10386
10387         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
10388
10389 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10390
10391         * src/SDCCmain.c: signal handling is switched off by --debug
10392         * doc/Makefile: small fix for install; use clean.mk again
10393         * doc/clean.mk: clean *.pdf and *.html too
10394
10395 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
10396
10397         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
10398         * device/lib/printfl.c: fix a ds390 bug by making it portable
10399         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
10400         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
10401         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
10402         * debugger/mcs51/cmd.c: converted multi-line string literals
10403         * sim/ucsim/globals.cc: converted multi-line string literals
10404         * src/SDCCmain.c: introduced signal handler to remove temp files
10405         * doc/Makefile: small tweaks, implement clean
10406         * doc: removed generated files
10407
10408 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10409
10410         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10411         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10412         Address Record is not correctly generated for DS390."
10413
10414 2003-02-02  Borut Razem <borut.razem AT siol.net>
10415
10416         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10417         * as/mcs51/asm.h: fixed compilation with Borland C
10418         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10419         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10420         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10421         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10422         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10423         src/z80/Makefile.bcc: delete $(LIB) only if exist
10424         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10425
10426 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10427
10428         * device/include/malloc.h: introduced NULL
10429         * device/include/string.h: introduced NULL
10430         * device/include/stdlib.h: introduced NULL
10431         * device/lib/_memcpy.c: removed NULL
10432         * device/lib/_strcat.c: removed NULL
10433         * device/lib/_strchr.c: removed NULL
10434         * device/lib/_strcmp.c: removed NULL
10435         * device/lib/_strcpy.c: removed NULL
10436         * device/lib/_strcspn.c: removed NULL
10437         * device/lib/_strlen.c: removed NULL
10438         * device/lib/_strncat.c: removed NULL
10439         * device/lib/_strncmp.c: removed NULL
10440         * device/lib/_strncpy.c: removed NULL
10441         * device/lib/_strpbrk.c: removed NULL
10442         * device/lib/_strrchr.c: removed NULL
10443         * device/lib/_strspn.c: removed NULL
10444         * device/lib/_strstr.c: removed NULL
10445         * device/lib/_strtok.c: removed NULL
10446         * device/lib/malloc.c: removed NULL, include own header
10447
10448 2003-02-02    <johan AT balder>
10449
10450         * 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
10451         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10452         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10453         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10454         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10455         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10456
10457 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10458
10459         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10460         area 'DATA'"
10461
10462 2003-02-01    <johan AT balder>
10463
10464         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10465
10466 2003-01-31    <johan AT CP255758-A>
10467
10468         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10469
10470 2003-01-30    <johan AT balder>
10471
10472         * src/SDCCBBlock.c: automatic bug detection
10473         * src/SDCCicode.c: automatic bug detection
10474
10475 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10476
10477         * src/SDCCglobl.h:   now --xram-size 0 works
10478         * src/SDCCmain.c:    now --xram-size 0 works
10479
10480 2003-01-29    <johan AT balder>
10481
10482         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10483
10484 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10485
10486         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10487         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10488         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10489         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10490         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10491         * src/SDCCmain.c:    Added options --xram-size and --code-size
10492
10493 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10494
10495         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10496         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10497
10498 2003-01-27    <johan AT balder>
10499
10500         * src/SDCC.y: fixed bug #613764
10501
10502 2003-01-26    <johan AT balder>
10503
10504         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10505         * src/SDCCsymt.h: fixed bug #673374
10506         * src/SDCCglue.c: fixed bug #661910
10507         * src/SDCCast.c: fixed bug #458099 and 673374
10508
10509 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10510
10511         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10512         * as/mcs51/strcmpi.h: added
10513         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10514         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10515         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10516         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10517         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10518         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10519         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10520         * as/mcs51/Makefile.aslink: new module strcmpi
10521         * as/mcs51/Makefile.asx8051: new module strcmpi
10522         * as/mcs51/Makefil.bcc: new module strcmpi
10523         * as/mcs51/Makefile.in: new module strcmpi
10524         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10525
10526 2003-01-26    <johan AT balder>
10527
10528         * src/SDCCglue.c: reverted back to 1.124
10529         * src/SDCCast.c: reverted back to 1.156
10530         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10531
10532 2003-01-25    <johan AT balder>
10533
10534         * src/SDCCglue.c: A better fix for bug #661910
10535         * src/SDCCast.c: A better fix for bug #661910
10536         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10537
10538 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10539
10540         * src/Makefile.in: remove spawn.o
10541         * src/SDCCmain.c: remove spawn.h
10542         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10543         * src/spawn.c: removed
10544         * src/spawn.h: removed
10545         * support/regression/ports/ds390/spec.mk: link with -r
10546
10547 2003-01-24    <johan AT CP255758-A>
10548
10549         * src/ds390/gen.c (aopOp): fixed bug #667458
10550         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10551         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10552         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10553
10554 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10555
10556         * src/mcs51/peeph.def: better assembler identation by Frieder
10557         * src/mcs51/gen.c: better assembler identation by Frieder
10558
10559 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10560
10561         * as/z80/string.h: removed for gcc 3.2
10562         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10563         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10564
10565 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10566
10567         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10568         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10569         * support/regression/Makefile: separate temp files for ports
10570         * support/regression/generate-cases.py: separate temp files for ports
10571         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10572         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10573
10574 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10575
10576         * moved tinitalk to device/examples/ds390
10577
10578 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10579
10580         * as/mcs51/lkmem.c: rflag is for DS390
10581         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10582         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10583                          (linkEdit): move mem- and map-files the same way as ihx-files
10584         * src/z80/main.c (_setDefaultOptions): removed --generic
10585         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10586         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10587         * src/pic/glue.c (picglue): --c1mode works again
10588         * src/pic16/glue.c (pic16glue): --c1mode works again
10589         * src/asm.c (printCLine): fix #660034
10590
10591 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10592
10593         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10594         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10595         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10596         * as/mcs51/lkmem (summary): better fix for sp problem
10597         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10598         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10599         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10600                                               remove --stack-after-data
10601
10602 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10603
10604         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10605         * src/SDCCutil.c (join): ugly bug: missing '\0'
10606         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10607
10608 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10609
10610         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10611         * src/port.h: typo
10612         * src/pic/main.c (_asmCmd): gpasm supports -o
10613         * src/z80/main.c: more general macros
10614         * device/lib/Makefile.in: remove intermediate files
10615
10616 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10617
10618         * .version: Bumped version number to 2.3.3
10619         * src/SDCCBBlock.c: new option -o
10620         * src/SDCCglobl.h: new option -o
10621         * src/SDCCglue.c: new option -o
10622         * src/SDCCmain.c: new option -o
10623         * src/asm.c: new option -o
10624         * src/ds390/main.c: new option -o
10625         * src/pic/glue.c: new option -o
10626         * src/pic/pcode.c: new option -o
10627         * src/pic/ralloc.c: new option -o
10628         * src/pic16/glue.c: new option -o
10629         * src/pic16/pcode.c: new option -o
10630         * src/pic16/ralloc.c: new option -o
10631         * src/z80/main.c: new option -o
10632         * device/lib/Makefile.in: use -o
10633         * support/regression/ports/ds390/spec.mk: use -o
10634         * support/regression/ports/gbz80/spec.mk: use -o
10635         * support/regression/ports/mcs51/spec.mk: use -o
10636         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10637         * support/regression/ports/z80/spec.mk: use -o
10638         * support/regression/ports/ucz80/spec.mk: use -o
10639         * support/regression/ports/xa51/spec.mk: use -o
10640         * support/regression/fwk/lib/timeout.c: fix usage string
10641
10642 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10643         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10644
10645 2003-01-07    <johan AT balder>
10646
10647         * src/SDCCast.c (decorateType): fixed bug #600035
10648
10649 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10650         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10651         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10652         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10653         * src/pic/pcode.c: outcommented unused variable to remove warnings
10654         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10655
10656 2003-01-06    <karl AT turbobit.com>
10657         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10658    regression tests.
10659
10660 2003-01-06    <johan AT balder>
10661
10662         * src/SDCCicode.c: fixed array add
10663
10664 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10665         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10666         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10667
10668 2003-01-04    <johan AT balder>
10669
10670         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10671
10672 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10673         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10674
10675 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10676         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10677         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10678
10679 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10680         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10681
10682 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10683         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10684
10685 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10686         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10687
10688 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10689
10690     * in \sdcc\as\mcs51\ changed these files in order to create an
10691     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10692     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10693     following files to include the previous two files: aslink.dsp,
10694     Makefile.aslink, Makefile.bcc, and Makefile.in.
10695
10696     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10697     .adb instead of .cdb
10698
10699 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10700
10701         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10702         value from option --iram-size.
10703
10704 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10705
10706         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10707         dram[] array.
10708
10709 2002-09-18    <wiml AT hhhh.org>
10710
10711         * SDCClrange.h: exposed setFromRange() and setToRange()
10712         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10713           packRegsForAccUse() (bug 542397)
10714         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10715           multiple times and emitting the fetch operations more than once
10716           added aopGetUsesAcc() function to allow binary operators to
10717           fetch their operands in the correct order; made genMinus() emit
10718           compact code for X = LITERAL - Y
10719
10720 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10721         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10722         sprintf() in line 1267.
10723
10724 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10725         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10726         like ports.
10727
10728 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10729         Changes to aslink (All the changes are marked with 'JCF'):
10730
10731         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10732         summary().
10733
10734         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10735         area BSEG.  Also moves, if possible, the DATA area down into the internal
10736         ram so more space is available.
10737
10738         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10739         sflag.
10740
10741         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10742         not bytes.  Function summary() which creates a memory usage summary
10743         file with extension .mem.  Reports of overlaping stack and small stack
10744         size.  If the space for the stack is less than 16 bytes aslink trows a
10745         warning.
10746
10747         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10748         the 8051.  Option 'y' for memory summary output file.
10749
10750         Changes to sdcc (All the changes are marked with 'JCF'):
10751
10752         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10753
10754         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10755         overlaying area for it (uses RegBankUsed[4]).
10756
10757         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10758         bank zero as used by default.  By default aslink locates the stack
10759         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10760         the creation of the .mem file.  Delegates the allocation of data area
10761         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10762         the begining of the stack area to aslink.
10763
10764         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10765         glue() in SDCCglue.c creates an area for it.
10766
10767 2002-09-03  Borut Razem <borut.razem AT siol.net>
10768         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10769         sdcc/src/pic/glue.c:
10770         introduced atexit() handler for teporay files removal in case of
10771         errors, assertions, ...
10772
10773 2002-08-29  Borut Razem <borut.razem AT siol.net>
10774         * sdcc/support/cpp2/auto-host_vc_in.h:
10775         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10776         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10777         Maybe there is a similar problem with BORLANDC? It should be checked!
10778
10779         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10780         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10781         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10782         was not executed, and the compiler (cl) launched a warning:
10783         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10784
10785 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10786         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10787
10788 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10789         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10790
10791         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10792           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10793           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10794           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10795           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10796           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10797           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10798         - added Release configuration in VS projects
10799         - review of compiler an linker options
10800         - VC .exe files are generated in bin_vc directory, not to interfere
10801           with binaries generated from other projects (cygwin, mingw, bcc ...)
10802
10803         * sdcc/src/yacc.dsp: added
10804
10805         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10806         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10807         and insert the version number definitions from .version
10808
10809         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10810
10811         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10812         added - genarate auto-host.h using auto-host_vc_in.h as template
10813
10814         * sdcc/sdcc_vc.h,
10815         removed from CVS, generated automatically
10816
10817 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10818         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10819
10820 2002-08-11  Borut Razem <borut.razem AT siol.net>
10821         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10822
10823 2002-08-10  Borut Razem <borut.razem AT siol.net>
10824         * src/SDCCmain.c (main):
10825         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10826         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10827         The consequence was that some temporary files were not removed.
10828
10829         * src/SDCCglue.c:
10830         unification of code in functions tempfilename() and tempfile():
10831         function tempnam() is defined in Visual Studio 6.0 and .NET
10832
10833         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
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         - removed compiler command line option /WX: Treats all warnings as errors
10838         - update a list of source files, included into the project
10839
10840         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10841           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10842         changed project type to Generic Project so that can be correcly converted to VS.NET project
10843
10844         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10845
10846         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10847
10848         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10849
10850         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10851         added return 0 statements after assert() to make compiler happy
10852
10853         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10854         added newline in the def file to keep MSC compiler satisfied
10855
10856         * sdcc/src/z80/gen.c:
10857         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10858           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10859         - solved MSC error in function aopDump()
10860
10861         * sdcc_vc.h: define PREFIX as "\\sdcc"
10862
10863 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10864         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10865
10866 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10867         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10868         - Rewrote the register banking algorithm.
10869         - Added pCode live-range analysis to registers (for now, only non-used and
10870         singly-used registers optimized away)
10871
10872         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10873
10874         * 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.
10875
10876 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10877         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10878
10879 2002-04-22  Michael Hope  <michaelh AT vroom>
10880
10881         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10882
10883         * configure.in (DD_COPT): Added include support required for gbdk.
10884
10885         * .version: Bumped version number just to increase it.
10886
10887         * src/SDCCmain.c: Added -nostdinc to the default options.
10888
10889 2002-04-15  Michael Hope  <michaelh AT vroom>
10890
10891         * device/lib/z80/printf.c (sprintf): Added.
10892
10893         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10894
10895         * src/z80/peeph.def: Added transpose redundent load rule.
10896
10897         * src/z80/main.c: Added force callee saves for jaune.
10898
10899         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10900
10901         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10902
10903 2002-03-28  Johan Knol  <johan AT balder>
10904
10905         * src/SDCCval.c: fixed bug #532436
10906
10907 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10908         * /src/port.h:
10909         Added "char *Processor" field to the port structure.
10910
10911         * /src/SDCCmain.c:
10912         Added -p option. Allows port dependent processor to be specified.
10913
10914         * all ports:
10915         Initialized the new field char *Processor field to NULL in all ports
10916
10917         * /src/pic/*:
10918         Compiler generated registers for interrupt context saving
10919         were not getting allocated.
10920
10921 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10922
10923         * /src/SDCCast.c:
10924         Fixed left shift. Will promote the left side of a left shift
10925         if a) left shifting more than size of operand or b) when assigned
10926         to something size > size of left side
10927
10928 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10929         * src/pic/*
10930         tons of changes. Register allocation has been
10931         rewritten. Added customization for the various PICs. Flow
10932         analysis is restructured. ...
10933
10934         * src/pic/device.h:
10935         Added
10936
10937         * src/pic/device.c:
10938         Added. device.c is a PIC port hack to accomodate variations
10939         in PIC devices.
10940
10941 2002-03-13  Michael Hope  <michaelh AT vroom>
10942
10943         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10944
10945 2002-03-04  johanknol  <johanknol AT manik>
10946
10947         * /src/SDCCval.c: fixed
10948
10949         const unsigned char arr[][2] = { { 0, 1 } };
10950         t18.c:1: error: Initializer element is not constant
10951
10952 2002-03-04  bela  <bela AT manik>
10953
10954         * /device/include/mcs51reg.h:
10955         ds89c420 register definition update
10956
10957 2002-03-03    <johan AT FRIJA>
10958
10959         * support/Util/SDCCerr.c: did something, but don't no why anymore
10960
10961         * support/regression/tests/bug-524691.c: made it a little less shy
10962
10963         * src/SDCCast.c (decorateType): fixed bug #524697
10964
10965         * src/SDCCast.c: made some lineno improvements
10966
10967         * src/SDCCval.c (getNelements): changed warning to error
10968
10969         * src/SDCCglue.c (printIvalArray): changed warning to error
10970
10971         * src/SDCCicode.c: fixed a warning for mingw
10972
10973         * src/SDCCast.c (decorateType): fixed the << promotion for ops
10974
10975         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
10976
10977 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
10978
10979         * src/ds390/peeph.def:
10980         Added some more peephole rules
10981
10982         * src/ds390/gen.c: Various fixes & enhancements
10983
10984         * src/SDCClrange.c, src/SDCClrange.h:
10985         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
10986
10987         * src/ds390/ralloc.c:
10988         various fixes & enhancements (ds390) specific
10989
10990         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
10991         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
10992         from rallocs.
10993
10994         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
10995
10996 2002-03-02    <johan AT FRIJA>
10997
10998         * src/SDCCast.c (decorateType): fixed bug #524708
10999
11000         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
11001
11002         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
11003
11004 2002-03-01  Michael Hope  <michaelh AT vroom>
11005
11006         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
11007
11008         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
11009
11010 2002-03-01    <johan AT FRIJA>
11011
11012         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
11013
11014         * src/SDCCast.c (decorateType): fixed bug #524209
11015
11016         * src/SDCCval.c (valNot): fixed bug #524195
11017
11018 2002-02-26    <johan AT balder>
11019
11020         * src/xa51/gen.c: fixed a warning
11021
11022         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
11023
11024         * src/SDCCast.c (decorateType): fixed bug #522534
11025
11026 2002-02-23    <johan AT balder>
11027
11028         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
11029
11030 2002-02-22    <johan AT balder>
11031
11032         * src/SDCCast.c: fixed bug #514865
11033
11034         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
11035
11036 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
11037
11038         * sdcc/src/SDCCloop.c:
11039         Previous fix was not good. basic blocks that have "break" or "return" are
11040         not really partof a loop , but live ranges used in these blocks should
11041         be live thru the entire loop, so set partOfLoop but don't add them to
11042         loop region
11043
11044 2002-02-21    <johan AT FRIJA>
11045
11046         * src/SDCCcse.c: fixed bug #514308
11047
11048 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
11049
11050         * src/SDCCloop.c:
11051         Fixed BUG #519583. If a conditional block ended in a return/break
11052         statement inside a loop, it was not being considered part of the loop.
11053
11054         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
11055
11056 2002-02-10  Karl Bongers <karl AT turbobit.com>
11057
11058         * debugger/*:
11059         Fixed up SDCDB debugger somewhat.  Updated debugger/README
11060         with lots of comments and notes.
11061
11062         * device/examples/test2.c:
11063         Fix bug, "red" variable not being initialized(compiler complained).
11064
11065         * device/examples/Makefile, examples/test3.c:
11066         Add Makefile in device/examples folder, compiles test3.c
11067         for use as a multiple module SDCDB test case.
11068
11069         * sim/ucsim/cmd.src/cmdset.cc:
11070         Took out debug printfs in ucsim "next" command.
11071
11072         * sim/ucsim/xa.src:
11073         Karl and Johan start ucsim XA support.  Most dissassembly working,
11074         about 75% emulation done(plenty of work remaining).
11075
11076         * sim/ucsim/z80.src:
11077         Add Z80 support to ucsim, add test-ucz80 regression test,
11078         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
11079         Notice z80 compiler fails on examples/test3.c/crc code.
11080
11081 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
11082
11083         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
11084         Added support for --parms-in-bank1
11085
11086         * src/ds390/peeph.def:
11087         added a few more peephole optimzations
11088
11089         * src/ds390/main.c:
11090         1) added __builtin_inp & __builtin_outp used to read in data of given length
11091            from a memory mapped port
11092         2) added __builtin_memcmp
11093         3) added __builtin_swapw swap bytes of a short
11094
11095         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
11096         1) handle multiple send & receives from register bank1
11097         2) ralloc can now allocate DPTR1 to some liveRanges
11098
11099         * src/SDCCsymt.c, src/SDCCsymt.h:
11100         changes to handle multiple sends & receives
11101
11102         * src/SDCCptropt.h:
11103         added some pointer arithmetic optimization
11104
11105         * src/SDCCptropt.c:
11106         added some pointer arithmetic optimizations but not stable yet so not
11107         called from anywhere (will get this working shortly)
11108
11109         * src/SDCCopt.c: fixed for multiple sends & receives
11110
11111         * src/SDCCmain.c:
11112         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
11113         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
11114            set preprocessor defines (depending on options)
11115
11116         * src/SDCCicode.c, src/SDCCicode.h:
11117         changes made to handle multiple sends & receives
11118
11119         * src/SDCCglobl.h:
11120         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
11121
11122         * src/SDCCcse.c, src/SDCCcse.h:
11123         added function findbackward def (to be used in upcoming optimization)
11124
11125         * src/SDCCcflow.c, src/SDCCcflow.h:
11126         added function returnAtEnd - to determine if a basic block terminates with
11127         a RETURN iCode
11128
11129         * src/SDCCast.c, src/SDCCast.h:
11130         added option parms-in-bank1
11131
11132         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
11133         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
11134         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
11135         adjusted for --parms-in-bank1 option
11136
11137         * device/include/string.h:
11138         donot redefine "reentrant" keyword
11139
11140         * device/include/ds80c390.h: Added some more SFRs
11141
11142 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
11143
11144         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
11145
11146 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
11147
11148         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
11149
11150 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
11151
11152         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
11153
11154 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
11155
11156         * Added --xram-movc option
11157
11158 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
11159
11160         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
11161
11162 2002-01-11  Johan Knol
11163
11164         * Added math lib of Jesus Calvino-Fraga
11165
11166 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
11167
11168         * src/SDCCmain.c (processFile): fix processing of ../../src.c
11169         * support/regression/Makefile: new target test-mcs51-stack-auto
11170         * support/regression/ports/mcs51-stack-auto/spec.mk: added
11171
11172 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11173
11174         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
11175
11176 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11177
11178         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
11179
11180 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
11181
11182         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
11183
11184         * src/SDCCglue.h: add definition for printIvalChar()
11185
11186 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11187
11188         * src/SDCCast.c: fix #498138 by Johan
11189
11190         * src/SDCCglue.c: fix #498138 by Johan
11191
11192 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11193
11194         * support/regression/Makefile: fix clean
11195
11196         * support/regression/ports/ds390/support.c: fix transmission of last character
11197
11198 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
11199
11200         * /sdcc/src/ds390/gen.c:
11201         a) improved computing address of stack variable
11202         b) took out some #if 0 code
11203         c) improved parmBytes adjustment
11204         d) improved genPlusIncr & genMinusIncr
11205         e) genCmp could generate bad code (when left assigned to DPTR)
11206         f) Fixed bug in hasInc
11207
11208         * /sdcc/src/ds390/ralloc.c:
11209         a) packRegsForSupport could mess up live information (Fixed)
11210         b) packRegsDPTRuse could be incorrect for left & right shift
11211
11212         * /sdcc/src/mcs51/ralloc.c:
11213         packRegsForSupport could mess up the live information (Fixed)
11214
11215         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
11216
11217         * /sdcc/src/SDCCast.c:
11218         can reverse a loop even if function call is present as long
11219         as the loop control variable is local & is not passed as parameter
11220
11221 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11222
11223         * /sdcc/ChangeLog: *** empty log message ***
11224
11225         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
11226         More builtin function additions for TININative
11227
11228         * /sdcc/src/ds390/ralloc.c:
11229         Had broken the regression testsuite
11230
11231         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
11232
11233         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
11234         Added funcattr hasStackParms will be set for reentrant functions when there
11235         are paramteres on the stack, this helps in minimizing frame pointer generation
11236         typeFromStr can handle function pointers now
11237
11238         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
11239         *** empty log message ***
11240
11241 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11242
11243         * /src/ds390/gen.c, /src/ds390/main.c:
11244         More builtin function additions for TININative
11245
11246         * /src/ds390/ralloc.c:
11247         Had broken the regression testsuite
11248
11249         * /src/SDCCast.c: Fixed a bug in dumptree
11250
11251         * /src/SDCCsymt.c, /src/SDCCsymt.h:
11252         Added funcattr hasStackParms will be set for reentrant functions when there
11253         are paramteres on the stack, this helps in minimizing frame pointer generation
11254         typeFromStr can handle function pointers now
11255
11256         * /doc/builtins.txt, /doc/TININative.txt:
11257         *** empty log message ***
11258
11259
11260 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11261
11262         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
11263         ALPHA version for -mTININative
11264
11265         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
11266         updated to reflect changes in the port structure
11267
11268         * /src/port.h:
11269         added function do_assemble (similar to do_link) if non-null this function
11270         will be called to do assembly (-mTININative) requires a multi command
11271         assembly
11272         added function genAssemblerEnd will be called to generate assembler Epilogue
11273
11274         * /src/SDCCsymt.c:
11275         added _JavaNative to debug info printing
11276
11277         * /src/SDCCmain.c: added option --tini-libid
11278         added port->do_assemble function (-mTININative) has a multi command assemble
11279
11280         * /src/SDCCglue.c: Disabled "constExpr" check
11281         added port->genAssemblerEnd function
11282
11283         * /src/SDCCglobl.h: Added option --tini-libid value
11284
11285         * /src/SDCCast.h:
11286         tookout optimizeCompare from the header (has no external references)
11287
11288         * /src/SDCCast.c: made one more function "static"
11289
11290 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
11291
11292         * src/z80/mappings.i: Added z80asm support.
11293
11294         * src/z80/main.c: Added z80asm support on --asm=z80asm
11295
11296         * src/z80/gen.c: Fixed asm portability issues.
11297
11298         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
11299
11300         * src/SDCCglue.c (printExterns): Added global/extern split.
11301
11302 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
11303
11304         * support/regression/Makefile: added test for mcs51 model large
11305
11306         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
11307
11308         * support/regression/ports/gbz80/spec.mk: added -mgbz80
11309
11310 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
11311
11312         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
11313
11314 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
11315
11316         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
11317
11318         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
11319
11320 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
11321
11322         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
11323
11324         * support/regression/tests/simplefloat.c: Port to mcs51.
11325
11326 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
11327         * support/regression/tests/bug-485362.c: Added.
11328
11329         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
11330
11331         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
11332
11333         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
11334
11335         * src/z80/gen.c (aopDump): Added a dump function.
11336
11337 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
11338         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
11339
11340         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
11341
11342         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
11343
11344         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
11345
11346         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
11347
11348         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
11349
11350         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
11351
11352         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
11353
11354         * support/regression/ports/ds390/support.c: Use tinibios.
11355
11356         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
11357
11358 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
11359
11360         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
11361         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
11362
11363         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
11364
11365         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
11366
11367 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
11368
11369         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
11370
11371         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
11372         (packRegsForIYUse): Created and optimised.
11373
11374 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11375
11376         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
11377 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
11378
11379         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
11380
11381         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
11382
11383         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
11384
11385 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11386
11387         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
11388
11389         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
11390
11391 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11392
11393         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
11394
11395         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
11396
11397         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
11398
11399 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11400
11401         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
11402         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
11403         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
11404
11405         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
11406
11407         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
11408         (genNotFloat): Added.
11409         (genUminusFloat): Added.
11410
11411         * device/lib/z80/Makefile: Added floating pt stubs.
11412
11413         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11414
11415         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11416
11417         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11418
11419 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11420
11421         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11422
11423         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11424
11425         * sdcc/support/regression/Makefile: Add port ds390.
11426
11427         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11428
11429         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11430
11431         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11432
11433         * sdcc/support/regression/ports/ds390/support.c: Added.
11434
11435         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11436
11437         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11438
11439         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11440
11441 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11442
11443         * device/include/malloc.h: Added z80 and gbz80 support.
11444
11445         * device/lib/gbz80/heap.s: Added.
11446
11447         * device/lib/z80/heap.s: Added.
11448
11449         * device/lib/malloc.c: Added z80 and gbz80 support.
11450
11451         * support/regression/tests/malloc.c (testMalloc): Added.
11452
11453         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11454
11455         * support/regression/tests/bug-478094.c: Added.
11456
11457         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11458
11459 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11460
11461         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11462
11463         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11464
11465         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11466
11467         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11468
11469         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11470
11471 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11472
11473         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11474
11475 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11476
11477         * support/regression/tests/bug-477927.c: Added.
11478
11479         * src/z80/peeph.def: Added minor rules.
11480
11481         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11482
11483         * src/z80/peeph.def: Added jump optimisation modification.
11484
11485 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11486
11487         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11488
11489 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11490
11491         * support/regression/tests/funptrs.c: Added.
11492
11493 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11494
11495         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11496
11497 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11498
11499         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11500
11501         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11502
11503         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11504         (movLeft2ResultLong): Created.
11505
11506         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11507         (joinPushes): Added.  Joins two char pushes into a word push.
11508
11509 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11510
11511         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11512
11513         * support/makebin/Makefile (install): Added creation of dest dir.
11514
11515 2001-10-24 Karl Bongers <karl AT turbobit.com>
11516
11517         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11518
11519 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11520
11521         * src/z80/ralloc.c: Turned off faulty pack for one use.
11522
11523         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11524
11525         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11526
11527 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11528
11529         * support/regression/Makefile: Improved clean
11530
11531         * support/regression/ports/gbz80/spec.mk: Added clean
11532
11533         * support/regression/ports/host/spec.mk: Added clean
11534
11535         * support/regression/ports/z80/spec.mk: Added clean
11536
11537         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11538
11539         * support/regression/ports/mcs51/timeout.c: little improvements
11540
11541 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11542
11543         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11544
11545         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11546
11547         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11548
11549 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11550
11551         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11552
11553         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11554
11555 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11556         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11557
11558         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11559
11560         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11561
11562         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11563
11564         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11565
11566         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11567
11568         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11569
11570         * support/regression/tests/longor.c: Added.
11571
11572 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11573
11574         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11575
11576         * as/mcs51/aslink.h: define PATH_MAX
11577
11578         * as/mcs51/asm.h: define PATH_MAX
11579
11580         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11581
11582         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11583
11584         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11585
11586         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11587
11588         * src/SDCCglobl.h: define PATH_MAX
11589
11590         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11591
11592         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11593
11594 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11595
11596         * src/z80/gen.c (gencjneshort): Fixed
11597
11598         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11599
11600 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11601
11602         * support/regression/tests/bug-469671.c: Added.
11603
11604         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11605
11606 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11607
11608         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11609
11610         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11611
11612 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11613
11614         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11615
11616         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11617
11618         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11619
11620         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11621
11622         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11623
11624         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11625
11626         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11627
11628 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11629
11630         * 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.
11631
11632         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11633
11634         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11635
11636 2001-10-07    <johan AT FRIJA>
11637
11638         * device/lib/gets.c (gets): fixed the return value.
11639
11640 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11641         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11642
11643         * 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.
11644
11645         * 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.
11646
11647         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11648
11649         * src/pic/gen.c: Removed Safe_strdup.
11650
11651         * configure.in: Added option to enable libgc support.
11652
11653         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11654         (bitVectUnion): Optimised.
11655         (bitVectIntersect): Optimised.
11656         (bitVectBitsInCommon): Optimised.
11657         (bitVectCplAnd): Optimised.
11658
11659         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11660
11661 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11662
11663         * src/SDCCmain.c: distinguish between assembler debug and plain options
11664
11665         * src/avr/main.c:   remove standard assembler options
11666
11667         * src/ds390/main.c: remove standard assembler options
11668
11669         * src/mcs51/main.c: remove standard assembler options
11670
11671         * src/port.h: removed "PENDING" comment
11672
11673 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11674
11675         * src/device/lib/_mulint.c  : new, with assember functions
11676
11677         * src/device/lib/_mullong.c : new, with assember functions
11678
11679         * src/device/lib/_divuint.c : with assember functions
11680
11681         * src/device/lib/_divsint.c : with assember functions
11682
11683         * src/device/lib/_divulong.c: with assember functions
11684
11685         * src/device/lib/_divslong.c: with assember functions
11686
11687         * src/device/lib/_moduint.c : with assember functions
11688
11689         * src/device/lib/_modsint.c : with assember functions
11690
11691         * src/device/lib/_modulong.c: with assember functions
11692
11693         * src/device/lib/_modslong.c: with assember functions
11694
11695         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11696
11697         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11698
11699         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11700                                       replaced _mululong.c and _mulslong.c by _mullong.c
11701
11702 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11703
11704         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11705
11706 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11707
11708         * src/SDCCglue.c: test, if win32api is available for MINGW
11709
11710 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11711
11712         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11713         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11714         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11715         * support/regression/ports/host/spec.mk: removed GENERIC
11716         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11717         * support/regression/ports/z80/spec.mk: removed GENERIC
11718
11719 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11720
11721         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11722
11723         * support/regression/tests/bug-467035.c: Created.
11724
11725 2001-10-01    <johan AT FRIJA>
11726
11727         * src/SDCC.y: fixed bug #466586 part 1
11728
11729 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11730
11731         * SDCCicode.c: z80 has no generic pointers
11732         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11733
11734 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11735
11736         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11737
11738 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11739
11740         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11741
11742         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11743
11744 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11745
11746         * configure.in: Fixed up so that ucsim is only configured once.
11747
11748         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11749
11750         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11751         (getPathDifference): As above.
11752
11753         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11754
11755         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11756
11757 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11758         * .version: Updated to 2.3.1
11759
11760         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11761         Added copyright header.
11762
11763         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11764         (assemble): Added support for macro based assembler commands.
11765         (linkEdit): Added support for macro based linker commands.
11766         (preProcess): Changed the pre-processor to use macros.
11767         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11768         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11769
11770         * device/lib/z80/crt0.s: Added module name for debugging.
11771
11772 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11773
11774         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11775
11776         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11777
11778         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11779
11780         * src/Makefile.in: Added SDCCmacro and SDCCutil
11781
11782 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11783
11784         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11785
11786 2001-09-16    <johan AT FRIJA>
11787
11788         * 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.
11789
11790 2001-09-15    <johan AT FRIJA>
11791
11792         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11793         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11794
11795 2001-09-11    <johan AT FRIJA>
11796
11797         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11798
11799 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11800
11801         * support/regression/tests/bug-460444.c: Added test case.
11802
11803         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11804         (genCast): Added justification for all of the asserts.
11805
11806 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11807
11808         * support/regression/support.c: _xdata replaced by xdata
11809
11810         * support/regression/spec.mk: removed _generic
11811
11812 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11813
11814         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11815
11816         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11817         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11818
11819         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11820
11821         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11822
11823         * support/regression/tests/bug-460010.c: Added test case.
11824
11825         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11826
11827 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11828
11829         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11830
11831         * support/regression/testfwk.c: removed workaround for bug #436344
11832
11833         * support/regression/tests/bp.c: use less memory with mcs51
11834
11835         * support/regression/tests/bug-441448.c: use less memory
11836
11837         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11838
11839         * support/regression/collate-results.py: typo
11840
11841 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11842
11843         * support/regression/tests/fetchoverlap.c: Added new test case.
11844
11845         * support/regression/tests/bp.c: Added new test case.
11846
11847         * support/regression/tests/bug-448984.c: Added new test case.
11848
11849         * support/regression/tests/pow2shifts.c: Added new test case.
11850
11851         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11852         (genlshTwo): Fixed right shift for count > 8.
11853
11854         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11855
11856 2001-09-08    <johan AT FRIJA>
11857
11858         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11859
11860 2001-09-07    <johan AT FRIJA>
11861
11862         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11863
11864         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11865
11866 2001-09-06    <johan AT FRIJA>
11867
11868         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11869         * bernhard noted me at this: "() equals to (void)" (1.38)
11870
11871 2001-09-05    <johan AT FRIJA>
11872
11873         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11874
11875 2001-09-04    <johan AT FRIJA>
11876
11877         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11878
11879
11880 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11881
11882         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11883
11884 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11885
11886         * link/z80/aslink.h: Fixed path for PATH_MAX
11887
11888 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11889
11890         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11891
11892         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11893
11894         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11895
11896         * 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.
11897
11898 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11899
11900         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11901         (genCmp): Fixed up genCmp for the GB with longs.
11902
11903         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11904
11905         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11906
11907         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11908
11909         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11910
11911 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11912
11913         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11914
11915 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11916
11917         * 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.
11918
11919         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11920
11921 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11922
11923         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11924
11925         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11926
11927 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11928
11929   * sim/ucsim/configure:    little improvement of Cygwin-detection
11930   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11931   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11932   * support/regression/tests/bug-221100.c: small changes for mcs51
11933   * support/regression/tests/bug-221168.c: small changes for mcs51
11934   * support/regression/tests/bug-227710.c: small changes for mcs51
11935   * support/regression/tests/staticinit.c: small changes for mcs51
11936   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11937   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11938   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11939
11940 $Revision$