* device/include/stdint.h: added
[fw/sdcc] / ChangeLog
1 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * device/include/stdint.h: added
4         * device/lib/abs.c: added
5         * device/lib/labs.c: added
6         * device/include/stdlib.h: added abs() and labs() prototypes
7         * device/lib/libsdcc.lib: added abs and labs
8         * device/include/float.h,
9         * device/lib/_fsmul.c,
10         * device/lib/printf_fast.c,
11         * device/lib/printf_tiny.c: updated comments
12
13 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
14
15         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
16         bug #1164313
17
18 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
19
20         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
21         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
22
23 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
24
25         * device/lib/printf_large.c: removed inline assembly for portability and
26           readability. Use printf_fast if speed or size are more important.
27         * src/pic16/gen.c: removed conditions around use of DEBUGpc
28         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
29
30 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
31
32         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
33         prevent compiler warning
34
35 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
36
37         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
38         moved to level 0 and declared as static. Also they are explicit
39         placed in access bank. This was necessery because some times they
40         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
41         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
42         optimizations. Currently only compare to unsigned char is implemented,
43         * src/pic16/gen.c: added fReturnIdx array,
44         * (struct resolvedIfx) is moved to gen.h and made public,
45         * (struct _G): added sregsAlloc and sregsAllocSet fields,
46         * (aopForSym): added an optimization to directly store in stack of
47         the operand of a SEND iCode,
48         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
49         but as registers instead (AOP_REG) using the fReturnIdx array,
50         * (pic16_freeAsmop): remove the freed register from the
51         _G.sregsAlloc field,
52         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
53         a compare of 'WREG',
54         * (pic16_popGetTempRegCond): changed function prototype, now
55         function takes also a bitVector argument v which holds the current
56         set of registers that are allocated for stack access by aopForSym,
57         registers allocated in aopForSym for accessing stack symbols are not
58         any more part of the functions usedRegs field,
59         * (genCall): some times aopOp is called for a stack variable to be
60         send, aopForSym might perform the push, if this is true make sure
61         that genCall doesn't push the variable twice by testing _G.resDirect,
62         * (genFunction): changed testing for unspecified interrupt number
63         from 256 to INTNO_UNSPEC,
64         * modified selection scheme of frame pointer generation. Previously
65         if function did use local registers a frame pointer was generated,
66         now a frame pointer is generated only if function has arguments
67         (that need PLUSW2 register access), or has stack arguments, or the
68         compiler is not instructed to omit the frame pointer,
69         * (genEndFunction): before restoring local registers that were saved
70         in the function preamble, also restore the registers that *might*
71         have been allocated for stack access,
72         * (genRet): removed some old comments,
73         * (genCmp, the active (RN's) version): added a call to the
74         pic16_genCmp_special function to perform the compare with a more
75         robust and optimized way,
76         * (genInline): a feature has been added in inline code generation,
77         which allows a wildcard variable substitution when writing inline
78         assembly. Code is incomplete and experimental therefore undocumented,
79         * (genCast): changed order of aopOp for result and right to allow
80         aopForSym to directly load the result if possible,
81         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
82         perform an optimized compare on some selected special occasions,
83         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
84         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
85         generate an IVT any more,
86         * src/pic16/main.c (pic16_optionsTable): added command line option
87         --optimize-cmp,
88         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
89         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
90         macros,
91         * src/pic16/NOTES: Raphael Neider added in list of active developers
92         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
93         jumptable_end to prevent bug #,
94         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
95         inCond and outCond fields,
96         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
97         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
98         turn off register spilling,
99         * (packRegsForOneUse): synced with other ports' versions although it
100         is not used currently,
101         * (pic16_packRegisters): added an optimization while reading
102         structure bitfields, some registers may be saved (malloc code is
103         decreased by 80 bytes)
104
105 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
106
107         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
108         left is a bitfield, if yes, then don't optimize assignment. Perhaps
109         this can be optimized more?
110
111 2005-03-10 Raphael Neider <rneider AT web.de>
112
113         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
114           genNearPointerGet): (hopefully) fixed access to bitfields via
115           pointers (p->bitN = x; and x = p->bitN; failed)
116
117 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
118
119         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
120
121 2005-03-09 Raphael Neider <rneider AT web.de>
122
123         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
124
125 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
126
127         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
128         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
129           (regTypeNum): set REG_BIT type if necessary
130         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
131         * support/regression/tests/critical.c: check bug 1144613
132
133 2005-03-02 Raphael Neider <rneider AT web.de>
134
135         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
136
137 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
138
139         * src/avr/ralloc.c (serialRegAssign),
140         * src/ds390/ralloc.c (serialRegAssign),
141         * src/hc08/ralloc.c (serialRegAssign),
142         * src/mcs51/ralloc.c (serialRegAssign),
143         * src/pic/ralloc.c (serialRegAssign),
144         * src/pic16/ralloc.c (serialRegAssign),
145         * src/xa51/ralloc.c (serialRegAssign),
146         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
147
148 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
149
150         * src/SDCCast.c (decorateType): fixed bug 1124787
151
152 2005-02-20 Hubert Sack <sack AT digiplan.de>
153         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
154
155         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
156         patch #1121755
157
158 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
159
160         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
161         to keep the correct label reference count when adding/removing references
162         to labels. A peephole file using this is appended to patch #1144962.
163
164 2005-02-14 Raphael Neider <rneider AT web.de>
165
166         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
167         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
168         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
169           retrievals of result operand's value on assignment
170
171 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
172
173         * device/include/pic16/string.h: modified prototype for memccpy()
174         to memccpy(void *, void *, char, size_t)
175         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
176         check whether to omit frame pointer or not,
177         * (genInline): convert all occurences of "\n" to LF in inline
178         assembler blocks, this helps formatting the inline text,
179         * (pic16_loadFSR0): modified prototype,
180         * (genNearPointerGet, genNearPointerSet): reorganization of code,
181         removed some 8051 legacy code,
182         * (genPackBits): enabled handling bitfields exceeding one byte in size,
183         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
184         before allocating temporary registers in functions,
185
186 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
187
188         * support/regression/tests/bitvars.c: corrected the "fix"
189
190 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
191
192         * support/regression/tests/bitvars.c,
193         * support/regression/tests/bitwise.c,
194         * support/regression/tests/rotate.c: "fixed" problems on Alpha
195
196 2005-02-10 Raphael Neider <rneider AT web.de>
197
198         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
199           different size for Alpha
200         * src/pic16/gen.c (genCmpEq) : improved compare with 0
201
202 2005-02-09 Raphael Neider <rneider AT web.de>
203
204         * src/SDCC.lex(doPragma) : save and restore warning options as well
205           (also added new stack plus clone- and copyAndFreeSDCCERRG())
206         * have #pragma less_pedantic set the errorlevel to WARNING
207           (fixes #1117001)
208         * (cloneOptimize) : fixed wrong malloc's size
209         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
210           facilitate correct handling of #pragma (save|restore)
211
212 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
213
214         * src/mcs51/gen.c: removed non-standard C nameless struct/union
215
216 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
217
218         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
219
220 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
221
222         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
223
224 2005-02-02 Raphael Neider <rneider AT web.de>
225
226         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
227         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
228         * (pic16_storeForReturn): fixed to allow returning function pointers
229         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
230         * device/include/pic16/{stddef.h,stdbool.h}: added
231
232 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
233
234         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
235
236 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
237
238         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
239         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
240          appeared to be required
241
242 2005-01-31 Borut Razem <borut.razem AT siol.net>
243
244         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
245           include/mcs51 and include/z80 directories to the package
246
247 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
248
249         * src/hc08/gen.c (genFunction): fixed bug #1112752
250
251 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
252
253         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
254
255 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
256
257         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
258
259 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
260
261         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
262
263 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
264
265         * device/include/c8051fxxx.h: removed these 6 files
266         * device/include/mcs51/c8051fxxx.h: added these 11 new files
267
268 2005-01-26 Raphael Neider <rneider AT web.de>
269
270         * src/pic16/gen.c (genAssign): fixed assignment from longs
271           in codespace (were cut to three bytes)
272         * (genDummyRead): implemented (except for CODESPACE...),
273           fixed bug #1108575
274         * src/pic16/glue.c (emitStatistics): beautified
275         * device/lib/pic16/libm/Makefile: added include path
276
277 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
278
279         * src/z80/gen.c (aopPut): fixed bug #1103902
280
281 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
282
283         * device/lib/expf.c: fixed bug #1095792
284
285 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
286
287         * device/lib/pic16/libm: added Math library sources
288
289 2005-01-24 Raphael Neider <rneider AT web.de>
290
291         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
292           to enable upcast to pCodeOpReg2 (there is no type tag to
293           differenciate the two and pic16_popGet2p cast into PCOR2)
294         * src/pic16/main.c (_process_pragma): fixed another malloc bug
295           (sizeof(sectNames) changed to sizeof(sectName))
296           Both patches fix segfaults under MinGW.
297
298 2005-01-23 Raphael Neider <rneider AT web.de>
299
300         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
301           Safe_[mc]?alloc()'ed variables
302         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
303           of (byte sized) temporaries (assign them to WREG for now)
304         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
305           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
306           this might fix SIGSEGVs on MinGW...
307         * src/SDCCopt.c (killDeadCode): restored original behaviour
308           (volatile operands might get thrown away though)
309
310 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
311
312         * src/pic16/gen.c: fixed bug #1106975,
313         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
314         pointer update, INTCON is saved, global interrupts are disabled and
315         restored after updateing TOS.
316         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
317         * added function attribute 'shadowregs' to take advantage of shadow
318         registers,
319         * added function attribute 'wparam' as an alternative to the wparam
320         pragma,
321         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
322         user declares a non-ISR function as 'shadowregs',
323         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
324
325 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
326
327         * .version: bumped version number to 2.4.8
328         * device/lib/pic16/pics.all: list of PIC18F devices supported by
329         pic16 port,
330         * device/lib/pic16/libio/i2c/: I2C module support library,
331         * device/include/pic16/i2c.h: I2C support library header,
332         * device/lib/pic16/libc/stdio/: standard IO support sources,
333         * (printf_small.c): printf_small() source, supports float print,
334         * (printf_tiny.c): printf_tiny() source, does not support floats,
335         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
336         enable global optimizations for entire library source, other
337         Makefiles in the source tree are also modified to reflect this,
338         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
339         function,
340         * doc/sdccman.lyx: updated to reflect new changes,
341         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
342         sym->onStack if-case,
343         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
344         sbit, idata, _idata, xdata, _xdata,
345         * added pragma library, to link an external library, (see doc),
346         * removed command line options, --pomit-config-words, --pomit-ivt,
347         --pleave-reset-vector,
348         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
349         when calling assembler to reflect memory model used, also define
350         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
351         reflect stack model used,
352         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
353         on stack return NULL,
354
355 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
356
357         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
358           of the operands is volatile. Fixes #1020220
359
360 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
361
362         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
363         * (OptimizeRegUsage): make sure that there is really no other flow where
364           the first pCode is used
365
366 2005-01-22 Raphael Neider <rneider AT web.de>
367
368         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
369           to fix #1106967 (pCode->seq are not set up correctly)
370
371 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
372
373         * src/SDCCglue.c (glue): make sure code area is declared before the
374         static initialization area.
375
376 2005-01-21 Raphael Neider <rneider AT web.de>
377
378         * device/lib/Makefile.in: fixed test for pic16 install dir
379         * device/lib/pic16/*/Makefile*: modified compile flags to enable
380           optimizations
381         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
382           added --optimize-goto compiler switch and pragma wparam documentation
383         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
384         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
385           and PRODH closing bug #1071770 (peephole optimizer)
386
387 2005-01-19 Raphael Neider <rneider AT web.de>
388
389         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
390           cmdLine buffers (used when calling sdcpp...) are large enough
391           (MAX_PATH=256 truncates arguments leading to system halts when
392           used in MinGW...)
393         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
394         * (genUminus): rewritten to for efficiency
395         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
396           used uninitialized in some cases)
397         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
398           copy the third byte from the int -- now assumes 0x80 (data memory)
399         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
400           operands (genAddLit expects the iCode's operands to swapped as
401           well), fixed leftover bytes (crashed for short left operands)
402         * (pic16_genMinusDec): performance improvements, removed false
403           PIC14 emitSKPNCs
404         * (pic16_genMinus): fixed to cope with differently sized operands
405         * src/pic16/glue.c (pic16_glue): added new banksel optimization
406           for --obanksel > 1
407         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
408         * src/pic16/graph.[ch]: implementation of directed graphs, used by
409           new banksel optimization
410         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
411           analysis for temporary registers (segfaults...)
412         * src/pic16/peeph.def: added rule
413
414 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
415
416         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
417         which converts a float number to its ASCII representation
418         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
419         functions to convert the fractional and integer part of a float to ASCII,
420         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
421         realloc.c): added _MALLOC_SPEC to explicit place variables in data
422         ram
423         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
424         _STATMEM macros,
425         * device/include/pic16/adc.h: added GPL info,
426         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
427         a pCodeOp as tested operand,
428         * (genNearPointerGet): optimized bit testing, does not use
429         intermediate register for bit value, test directly instead with
430         BTFSS, BTFSC, works only for single bits,
431         * (genpic16Code): dump the name of the iCode in the asm,
432         * src/pic16/ralloc.c (decodeOp): removed static declaration and
433         renamed to pic16_decodeOp,
434         * (serialRegAssign): do not allocate a temporary register for iCode
435         sequences that test a single bit for 1/0
436
437 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
438
439         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
440         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
441         access stack and frame pointers. They are initially assigned to
442         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
443         accessing SFRs. Updated all occurences of modification of stack or
444         frame pointer in gen.c and pcode.c,
445         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
446         assigning of a literal value to pointers,
447         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
448         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
449         selected
450
451 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
452
453         * doc/sdccman.lyx: update documentation about stack pragma, added
454         some info for stack memory models
455
456 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
457
458         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
459
460 2005-01-08 Raphael Neider <rneider AT web.de>
461
462         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
463           udata sections to fix bug #1097823
464
465 2005-01-05 Raphael Neider <rneider AT web.de>
466
467         * src/pic16/gen.c (genGenericShift): added handling of differently
468           sized left operand and result
469
470 2005-01-04 Raphael Neider <rneider AT web.de>
471
472         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
473         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
474           to hold the condition bit)
475         * added new version of genCmp (old code available via #define)
476         * added new version of genShiftLeft/genShiftRight in a generic
477           way, now supports shifting by negative values
478         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
479           shiftCount (expected by genGenericShift)
480         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
481         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
482           dump
483         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
484           is an invalid literal too...)
485
486 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
487
488         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
489         from Raphael Neider,
490         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
491         for 8-bit literals. This fixes some literal operands which are sign
492         extended to 16-bits ints when instruction needs only 8-bits.
493
494 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
495
496         * device/lib/logf.c: added mcs51 assembly version
497         * device/lib/expf.c: added mcs51 assembly version
498         * device/lib/_logexpf.c: new shared asm code for expf and logf
499         * device/include/math.h: add defines for assembly math library
500         * device/lib/Makefile.in: build new _logexpf.c
501         * device/lib/libfloat.lib: use new _logexpf.c
502
503 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
504
505         * src/pic/device.c
506         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
507           device types which have less than 0x7f registers.
508
509 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
510
511         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
512
513 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
514
515         * device/lib/printf_fast.c: only build on supported arch.
516         * device/lib/printf_tiny.c: only build on supported arch.
517         * device/lib/printf_fast_f.c: only build if asm float lib
518         * device/lib/_fsget1arg.c: only build if asm float lib
519         * device/lib/_fsget2args.c: only build if asm float lib
520         * device/lib/_fsnormalize.c: only build if asm float lib
521         * device/lib/_fsreturnval.c: only build if asm float lib
522         * device/lib/_fsrshift.c: only build if asm float lib
523         * device/lib/_fsswapargs.c: only build if asm float lib
524         * device/include/stdio.h: don't provide print_fast,
525           print_fast_f, print_tiny prototypes if --xstack used
526
527 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
528
529         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
530         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
531           to the SOURCES
532
533 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
534
535         * device/lib/printf_fast_f.c: same as printf_fast, but
536           with floating point enabled
537         * device/lib/printf_fast.c: minor tweaks
538         * device/include/stdio.h: add printf_fast_f
539
540 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
541
542         * src/SDCCmain.c: make --float-reent default for mcs51
543         * device/lib/_fsadd.c: added mcs51 assembly version
544         * device/lib/_fssub.c: added mcs51 assembly version
545         * device/lib/_fsmul.c: added mcs51 assembly version
546         * device/lib/_fsdiv.c: added mcs51 assembly version
547         * device/lib/_fseq.c: added mcs51 assembly version
548         * device/lib/_fsneq.c: added mcs51 assembly version
549         * device/lib/_fsgt.c: added mcs51 assembly version
550         * device/lib/_fslt.c: added mcs51 assembly version
551         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
552         * device/lib/Makefile.in: add _fscmp to build
553         * device/lib/libfloat.lib: add _fscmp to build
554
555 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
556
557         * device/lib/_fs2slong.c: added mcs51 assembly version
558         * device/lib/_fs2sint.c: added mcs51 assembly version
559         * device/lib/_fs2schar.c: added mcs51 assembly version
560         * device/lib/_fs2ulong.c: added mcs51 assembly version
561         * device/lib/_fs2uint.c: added mcs51 assembly version
562         * device/lib/_fs2uchar.c: added mcs51 assembly version
563         * device/lib/_slong2fs.c: added mcs51 assembly version
564         * device/lib/_sint2fs.c: added mcs51 assembly version
565         * device/lib/_schar2fs.c: added mcs51 assembly version
566         * device/lib/_ulong2fs.c: added mcs51 assembly version
567         * device/lib/_uint2fs.c: added mcs51 assembly version
568         * device/lib/_uchar2fs.c: added mcs51 assembly version
569         * device/include/float.h: added #define to select asm vs c
570
571 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
572
573         * device/lib/printf_fast.c: improvements to float output
574         * device/include/float.h: add defines for assembly float library
575         * device/lib/_fsget1arg.c: receive 1 float arg
576         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
577         * device/lib/_fsnormalize.c: normalize a float
578         * device/lib/_fsreturnval.c: return float, various helper routines
579         * device/lib/_fsrshift.c: right shift a float's mantissa
580         * device/lib/_fsswapargs.c: swap 2 floats
581         * device/lib/Makefile.in: build these 6 new files for mcs51
582         * device/lib/libfloat.lib: add these 6 files to the library
583
584 2004-12-26 Borut Razem <borut.razem AT siol.net>
585
586         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
587           built by gcc 3.4.2
588
589 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
590
591         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
592           and fully reentrant and register bank neutral.
593         * device/lib/printf_fast.c: added float (not enabled by default),
594           added compact/slower integer (also not enabled by default),
595           improved size/speed of fast integer code, other minor changes
596         * device/include/stdio.h, device/lib/Makefile.in,
597           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
598
599 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
600
601         * src/pic16/pcode.c: declaring variables other than at the start of a
602           block is not supported in C by VC6.
603
604 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
605
606         * applied a previous patch from Raphael Neider that wasn't included
607         in the previous commits, which fixes infinite loops within jumptable
608         improvements,
609         * made some fixes that previous patches introduced
610
611 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
612
613         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
614         that fixes an issue with AOP_PCODE asmop's offset,
615         * (pic16_popCopyReg): update instance field too,
616         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
617         function of pic port,
618         * (genCmp, genAnd, genAssign),
619         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
620
621 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
622
623         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
624         variables initial values to idata section,
625         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
626         variables in some functions. This utilizes parmBytes field of iCode
627         structure to hold the offset of the variable in stack. (might be
628         able to use the stack field too?)
629         * applied patch from Raphael Neider # ### , # ###
630         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
631         variable initial values in idata section,
632         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
633         for static variables with initial value
634         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
635         applied fix in while loop from Raphael Neider.
636
637 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
638
639         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
640         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
641         * src/ds390/ralloc.c (serialRegAssign): spill bits
642         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
643         * support/Util/SDCCerr.c,
644         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
645         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
646         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
647
648 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
649
650         * device/include/sdcc-lib.h: inserted LGPL, added includes
651           asm/ds390/features.h and asm/mcs51/features.h
652         * device/include/asm/default/features.h,
653         * device/include/asm/gbz80/features.h,
654         * device/include/asm/z80/features.h: added empty _AUTOMEM
655           and _STATMEM
656         * device/include/asm/ds390/features.h,
657         * device/include/asm/mcs51/features.h: added files with defines for
658           _AUTOMEM and _STATMEM indicating automatic and static storage class
659         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
660         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
661         * src/SDCCicode.c (geniCodeCast),
662         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
663         * src/SDCCloop.c (loopInduction): removed unused variable lr
664         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
665           to convertToFcall to include char modulo (RFE 1065037), added check
666           if left operand is unsigned and use abs of literal value
667         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
668           as it doesn't work after conversion from peephole.def to peephole.rul
669         * src/mcs51/gen.c (toBoolean): added check for size,
670           (genModOneByte): optimized code for signed char modulo a literal
671           power of 2 (thanks to Hubert Sack),
672           (genRRC): removed unnecessary "clr c",
673           (genRLC): replaced "add a,acc" with cheaper "rlc a"
674         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
675           jump optimization,
676           swapped rules 256.c and 256.d,
677           extended 256.d by using new multiple checks (thanks Erik),
678           added rules 256.e and 256.f,
679           updated rule 261.a and 261.b to new generated code
680         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
681
682 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
683
684         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
685           induction related bugs, including first part of bug #1074377
686
687 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
688
689         * applied patch from bug-report #1076292,
690         * applied patches for genAnd and Goto-optimizations for Raphael
691         Neider,
692         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
693         dump a less iCode information,
694         * src/pic16/device.h (pic16_options_t): added field debgen,
695         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
696         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
697         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
698         puclic,
699         * (various functions): added macros FENTRY and FENTRY2 to functions,
700         to emit function prologue,
701         * (various functions): fixed indentation,
702         * (genNearPointerGet): fixed loading of FSR0,
703         * (genPackBits): applied patch from Raphael Neider to fix updating
704         of FSR0 and touching only the modified bits,
705         * src/pic16/genarith.c (various functions): added macros FENTRY to
706         emit function prologue in comments,
707         * src/pic16/pcode.h: added functions debugf2, debugf3,
708         * src/pic16/ralloc.c: partial fix for packForPush caused
709         segmentation fault,
710
711 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
712
713         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
714           <stsp AT users.sourceforge.net> with reversed byte order
715         * support/regression/tests/rotate.c: added (ds390 skips some tests)
716
717 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
718
719         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
720           bug #1074377
721         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
722         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
723
724 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
725
726         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
727
728 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
729
730         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
731           conditions,
732           (setFromConditionArgs): friendly operand parser for peephole rules,
733           (operandBaseName, operandsNotRelated): new peephole condition
734           "operandsNotRelated" -- similar to "operandsNotSame", but takes
735           architecture specific register naming into account, handles n-way
736           comparisons, and supports quoted literals
737         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
738
739 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
740
741         * src/mcs51/peeph.def: fixed bug #1076940
742
743 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
744
745         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
746
747 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
748
749         Adding support for replacing ljmps with sjmps in jumptables
750         generated for switch statements. For now you need to set the
751         environment variable SDCC_SJMP_JUMPTABLE to enable this.
752         Now 4 algorithms for mcs51 jumptable generation are used:
753         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
754         addresses loaded pc-relative for up to 112 cases and stack-pushing
755         target addresses loaded with offset from dptr for up to 256 cases.
756
757         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
758         * src/mcs51/main.c: adapted constants for switch table generation
759         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
760
761 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
762
763         * device/lib/printf_large.c (_print_format): fixed bug 1073386
764         * support/regression/tests/bug1057979.c: added test for bug 1073386
765
766 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
767
768         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
769         compilers
770
771 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
772
773         * src/pic16/device.h,
774         * src/pic16/genarith.c,
775         * src/pic16/glue.c,
776         * src/pic16/main.c,
777         * src/pic16/pcode.c: applied patches #1068154 and #1070213
778
779 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
780
781         Large cummulative patch for pic16 port.
782         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
783         to call when a stack overflow occurs,
784         * (malloc.h): added CVS Id tag,
785         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
786         variable,
787         * added libc directory. The current version of LibC contains string
788         functions, ctype functions and macros and some functions of the
789         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
790         be extensively tested in the future. Standard disclaimer here.
791         Library is not automatically build yet. But one can build it by
792         invoking 'make' inside the libc directory.
793         * added ADC library under libio. Preliminary version yet.
794
795         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
796         * src/pic16/gen.c (aopForRemat): asmop size is filled by
797         aopForRemat() now and not by pic16_aopOp(),
798         * (pic16_popGetTempReg): removed warning messgae when allocating
799         temporary registers, its a buggy feature and will be removed,
800         * (pic16_popGet): set register instance field in AOP_CRY,
801         * (pic16_outBitC): fixed for results in size greater than 1,
802         * (genUminusFloat): fixed for pic16, ported code from mcs51,
803         * (pic16_storeForReturn): optimized return of 0,
804         * (genCmp): experimental code for new genCmp which uses PIC18's
805         special compare&skip instructions. Initial tests fail some times
806         with variables grater than 1 byte in size, so new code is disabled,
807         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
808         a single bit,
809         * (genCast): began a fix to optimize the casting of a bit to another
810         bit, now assigning a bitfield to another bitfield will fail, sorry,
811         * src/pic16/main.c: disabled the use of lr-support feature,
812         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
813         * added some function prototypes, added function _debugf prototype,
814         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
815         bits with offset (case PO_GPR_BIT),
816         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
817         command line,
818         * (isBankInstruction): modified to return 0 for no banking instruction,
819         and 1 for banking instruction,
820         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
821         caused stop processing pCodes after a inline assembly block,
822         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
823         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
824         registers when it shouldn't,
825         * src/pic16/ralloc.c (allocReg): add preliminary support for
826         supporting a limited set of temporary registers,
827
828 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
829
830         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
831           genDataPointerSet): ensure assignments always copy in MSB to LSB
832           order,
833           (loadRegFromAop): recognize CLRH optimization,
834           (genFunction): optimize RECEIVE iCodes in reentrant functions
835
836 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
837
838         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
839           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
840           selected.
841         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
842         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
843           contiguous with data
844
845 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
846
847         * device/lib/_gptrget.c (_gptrget),
848         * device/lib/_gptrgetc.c (_gptrgetc),
849         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
850           instead of sjmp to ret
851         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
852           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
853
854 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
855
856         * .version: bumped version to 2.4.7
857         * device/lib/_gptrget.c (_gptrget): is now _naked
858         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
859         * device/lib/_gptrput.c (_gptrput): is now _naked
860         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
861           (createFunction): fixed xstack
862         * src/SDCCglue.c (emitMaps): set allocation required for bit area
863         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
864           or bit either,
865           (geniCodeCritical): store original interrupt state in an iTemp bit
866           var unless stack-auto
867         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
868         * src/SDCCmain.c (setIncludePath): added include/target to search path
869         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
870         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
871           prototype,
872           (processFuncArgs): put bit vars in bit area
873         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
874           unsaveRBank): fixed xstack,
875           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
876           (genFunction, genEndFunction): fixed xstack,
877           (genAssign): optimization don't walk backwards through mem
878         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
879         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
880         * support/regression/Makefile: also make library (for stack-auto) when
881           making "all" and added "test-mcs51-xstack-auto"
882         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
883         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
884         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
885         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
886         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
887           make-library by MAKE_LIBRARY
888         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
889           regression tests for xstack
890         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
891         * support/regression/tests/critical.c: test for critical on mcs51
892
893 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
894
895         * support/regression/ports/ucz80/spec.mk: use include and lib files from
896           built version of sdcc instead of installed version
897
898 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
899
900         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
901         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
902           vprintf.c now
903         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
904         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
905           WARNING: remove device/lib/build/z80/printf.o by hand when
906           updating from previous build!
907         * device/lib/z80/printf.c: updated comment
908         * support/regression/tests/bug1057979.c: test all ports now
909         * support/regression/tests/bug1065458.c: file added
910
911 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
912
913         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
914           *_start and *_end symbols for static functions
915
916 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
917
918         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
919           and search crt0.o in all library paths,
920           (setIncludePath): proper handling of --nostdinc,
921           (setLibPath): proper handling of --nostdlib
922         * support/regression/Makefile,
923         * support/regression/ports/ds390/spec.mk,
924         * support/regression/ports/gbz80/spec.mk,
925         * support/regression/ports/hc08/spec.mk,
926         * support/regression/ports/mcs51/spec.mk,
927         * support/regression/ports/mcs51-large/spec.mk,
928         * support/regression/ports/mcs51-stack-auto/spec.mk,
929         * support/regression/ports/z80/spec.mk: use include and lib files from
930           built version of sdcc instead of installed version
931         * doc/sdccman.lyx: fixed typo in --nostdinc
932
933 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
934
935         * src/pic/pcode.c,
936         * src/pic/device.c,
937         * src/pic/ralloc.c,
938         * src/pic/gen.c : added support to generate code for struct bit fields.
939
940 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
941
942         * as/xa51/xa_version.h,
943         * device/include/errno.h,
944         * device/include/regc515c.h,
945         * device/lib/_itoa.c,
946         * device/lib/_ltoa.c,
947         * device/lib/ser_ir_cts_rts.c,
948         * sim/ucsim/xa.src/glob.cc,
949         * sim/ucsim/xa.src/inst_gen.cc,
950         * sim/ucsim/xa.src/xa_bit.cc,
951         * sim/ucsim/xa.src/xa_sfr.cc,
952         * sim/ucsim/z80.src/inst_dd.cc,
953         * sim/ucsim/z80.src/inst_fdcb.cc,
954         * support/scripts/keil2sdcc.pl,
955         * src/pic16/pic16.dsp,
956         * src/pic16/pic16a.dsp: corrected cvs line endings
957         * device/lib/printf_large.c: fixed bug 1057979
958         * src/pic16/gen.c: fixed non-C standard code
959         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
960         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
961         * support/regression/ports/mcs51/support.c: reload T1 asap
962         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
963           pdata use and clear idata startup behaviour
964         * support/regression/tests/bug1057979.c: added
965
966 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
967
968         * device/examples/ds390/ow390/ad26.h,
969         * device/examples/ds390/ow390/cnt1d.h,
970         * device/examples/ds390/ow390/crcutil.c,
971         * device/examples/ds390/ow390/ownet.h,
972         * device/examples/ds390/ow390/owsesu.c,
973         * device/examples/ds390/ow390/swt12.h,
974         * device/examples/ds390/ow390/swtoper.c,
975         * device/examples/ds390/ow390/temp10.h,
976         * device/examples/ds390/ow390/thermodl.c,
977         * device/examples/ds390/tinitalk/tinitalk.dsp,
978         * device/examples/ds390/tinitalk/tinitalk.dsw,
979         * device/examples/mcs51/clock/hw.h,
980         * device/examples/mcs51/simple2/go.bat,
981         * device/examples/serialcomm/windows/serial.h,
982         * device/examples/xa51/dummy.c,
983         * device/examples/xa51/hello.c,
984         * device/include/80c51xa.h,
985         * device/include/at89x051.h: corrected cvs line endings
986
987 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
988
989         * src/pic16/main.c (options): added command line --gstack, to trace
990         stack over/under flows,
991         * added pragma 'wparam' to allow passing first byte of function
992         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
993         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
994         call to __gstack_test function and sets up the symbol as extern,
995         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
996         * popaop): added call to pic16_testStackOverflow,
997         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
998         wparamList list,
999         * (genCall, genPcall): now all parameters are passed via stack
1000         except in functions that are pass to wparam pragma in which WREG is
1001         used too,
1002         * (genPcall): REENTRANT flag is checked to see if variable prototype
1003         contains reentrant keyword, don't call a non-reentrant function, via
1004         a reentrant function pointer or vice versa, functions are never
1005         passed via WREG,
1006         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
1007         D.Winkler,
1008         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
1009         SIGSEGV when accessing a NULL register stucture,
1010         * (pic16_printGPointerType): modified to handle UPPER modifier for
1011         function initializers, changed prototype of function to simpler one,
1012         * (pic16_printIvalFuncPtr): check to see if function is already
1013         added in externs list,
1014         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
1015         optimized a move from W to SFR with a move to the same register
1016         later after a CALL,
1017         * device/lib/pic16/debug: NEW directory, contains debug features
1018         which are enabled when linking with libdebug.lib, currently command
1019         line option --gstack enables stack pointer tracing for over/under
1020         flow, corresponding sources are in debug/gstack
1021
1022 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
1023
1024         * doc/sdccman.lyx: updated SDCC version,
1025         * (PIC16 port): update list of command line options,
1026         * src/pic16/device.h (structure pic16_options_t): added field gstack
1027         to enable stack overflow tracing on push/pops,
1028         * src/pic16/device.c (statistics structure): added statistics
1029         structure,
1030         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
1031         pic16_dump_int_registers): increase statistics counters for each
1032         * variable which is encountered
1033         * (pic16_dump_usection): emit each .udata variable to its own udata
1034         section,
1035         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
1036         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
1037         parameters via stack, otherwise use old scheme,
1038         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
1039         assembler output file,
1040         * src/pic16/main.c: added command line options --gstack to enable
1041         push/pop tracing for stack overflow,
1042         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
1043         instructions): added size of each instruction,
1044         * (pic16_countInstruction): estimate size of instructions in
1045         the_pFile list, inline assembly blocks are not counted,
1046         * (pic16_FixRegisterBanking): trace previous register usage, when
1047         banksel optimizations is greater than 0, don't emit a redudant
1048         banksel directive,
1049
1050 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
1051
1052         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
1053         * src/pic16/ralloc.c : applied same fix for pic16.
1054         * src/pic/gen.c : tidied it up a little.
1055
1056 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1057
1058         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
1059         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
1060
1061 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1062
1063         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
1064
1065 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1066
1067         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
1068         non-reentrant function __modsint in the interrupt function (thus
1069         corrupting math operations during serial I/O)
1070         * device/lib/ser_ir.c: as above, changed buffersize
1071         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
1072         256.c,d for zeroing
1073         * doc/Makefile: added option -t for rsync
1074
1075 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1076
1077         * src/SDCCast.h (struct ast),
1078         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
1079
1080 2004-10-20 Borut Razem <borut.razem AT siol.net>
1081
1082         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
1083         package
1084
1085 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
1086
1087         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
1088         makefile targets,
1089         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
1090         support functions to replace long sequences of MOVFF's from access
1091         bank registers to stack and vice versa,
1092         * src/pic16/device.h: added new field opt_flags, where optimization
1093         flags can be set to enable certain features,
1094         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
1095         * pBlock, (genFunction, genEndFunction): surroung loop for
1096         saving/loading used registers in stack with PC_INFO pCodes,
1097         INF_LREGS. Code in between can then be optimized by pCode optimizer
1098         to support function calls,
1099         * (genDataPointerSet): fixed bug which loaded float fields in
1100         structures with corrupt data,
1101         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
1102         in a standard way debug info on stderr. Feature used for developing
1103         and debugging only,
1104         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
1105         obsolete chunks of code,
1106         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
1107         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
1108         * pic16/src/pcode.c (pic16_newpCodeInfo,
1109         * (pic16_newpCodeOpLocalRegs),
1110         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
1111         feature,
1112         * (pic16_pCodeConstString): printing of the initial value of a
1113         symbol as a comment is inhibited since parsing was already done by
1114         copyStr and output is corrupt,
1115         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
1116
1117 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1118
1119         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
1120
1121 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
1122
1123         * as/mcs51/lkarea.c: removed old K&R style,
1124           (lnksect): changed check on boundary error,
1125           (lnksect2): changed check on boundary error,
1126           (lnksect2): extend XSTK to end of page if size = 1
1127         * as/mcs51/lkmain.c: removed old K&R style,
1128           (Areas51): create l_IRAM symbol
1129         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
1130         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
1131           model-mcs51-stack-auto, added model-mcs51-xstack-auto
1132         * device/lib/_mullong.c: added version to be compiled with xstack
1133         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
1134         * device/lib/mcs51/crtxclear.asm: clear pdata as well
1135         * device/lib/mcs51/crtxstack.asm: fixed comment
1136         * src/SDCCglue.c: maxInterrupts defaults to 0,
1137           (emitMaps): added pdata,
1138           (createInterruptVect): (re)moved default,
1139           (glue): added pdata,
1140           (glue): moved __start__xstack to XSTK with default size 1
1141         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
1142           and options.float_rent when options.stackAuto is set,
1143           (linkEdit): only write XDATA_NAME if provided on command line
1144         * src/SDCCmem.h,
1145         * src/SDCCmem.c: added pdata
1146         * src/port.h: added pdata_name to PORT
1147         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
1148           (saveRegisters, unsaveRegisters): removed usage of B,
1149           (genMinus): fixed accumulator clash,
1150           (genJumpTab): added comment, this needs another look
1151         * src/mcs51/gen.c: added check for "B in use" paranoia,
1152           added pushB() and popB()
1153         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
1154           chance
1155         * src/avr/main.c,
1156         * src/ds390/main.c,
1157         * src/hc08/main.c,
1158         * src/mcs51/main.c,
1159         * src/pic/main.c,
1160         * src/pic16/main.c,
1161         * src/xa51/main.c,
1162         * src/z80/main.c: (reset_regparms) made void parameter explicit and
1163           added PSEG (PAG,XDATA) or NULL to port specifier
1164         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
1165         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
1166           (_mcs51_genInitStartup): removed __start__xstack equ,
1167           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
1168         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
1169         * src/z80/gen.c (_rleAppend): fixed warnings
1170         * support/regression/tests/zeropad.c: added pdata test
1171         * .version: bumped to 2.4.6
1172
1173 2004-10-17 Borut Razem <borut.razem AT siol.net>
1174
1175         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
1176         as a part of nightly build
1177
1178 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
1179
1180         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
1181         WREG holds the first byte function parameters,
1182         * (aopForSym): take special case for symbols which are in FARSPACE
1183         but in CODESPACE too,
1184         * (assignResultValue): modified to take into account _G.useWreg,
1185         * (genCall): don't use wreg for parameter passing when function is
1186         declared as reentrant, too, added optimization INCF to stack
1187         pointer when stack parameter count is 1,
1188         * (genFunction, genEndFunction): refurnished and fixed to not using
1189         wreg for passing parameters when function has varargs or is
1190         reentrant, fixed bug with symbol name compare for generating
1191         functions in absolute address,
1192         * (pic16_storeForReturn): refurnished,
1193         * (genCmp): began writing a new version of the function, not ready
1194         yet, therefore it is disabled,
1195         * (genAssign): do not read code memory when assigning a function to
1196         a pointer function,
1197         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
1198         array of characters, not pointer,
1199         * (pic16initialComments): in debug mode emit an .ident directive for
1200         the assembler,
1201         * (_process_pragma): emit a new warning type (internal to pic16)
1202         when setting stack to default length, emit a similar warning when
1203         placing a function at absolute address and address is not word aligned
1204         * (_pic16_parseOptions): added 'return TRUE' statement,
1205         * (_pic16_linkEdit): if compiling a source, then add the source's
1206         file object, first in the list of objects to link,
1207
1208 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
1209
1210         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
1211         * src/pic/main.c : removed VC warning.
1212         * src/pic/gen.c : changed comment.
1213
1214 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
1215
1216         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
1217         reference to a deprecated symbol _GPTRREG was causing failure to
1218         link. Thanks G. M. Gallant for the info.
1219
1220 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
1221
1222         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
1223         comments for Bugs item #954788.
1224
1225 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
1226
1227         * src/pic16/device.c (pic16_dump_gsection,
1228         * pic16_groupRegistersInSection): handle symbols declared to be in
1229         access bank differently,
1230         * src/pic16/gen.c (struct _G): added field resDirect,
1231         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
1232         send values read from stack directly to result and don't allocate
1233         temporary values,
1234         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
1235         same registers,
1236         * (pic16_sameRegsOfs): NEW,
1237         * (freeAsmop): if _G.resDirect is set then do not mark registers as
1238         free because they were not allocated from temporary pool,
1239         * pic16_popRegFromString): workaround to fix a problem with
1240         allocating variables twice or never,
1241         * (genGenPointerGet): using PRODL instead of FSR0H,
1242         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
1243         instead of FSR0H,
1244         * (genAssign): take advantage of the _G.resDirect flag,
1245         * (genCast): around line 11844, use mov2f instead of directly
1246         MOVFF'ing between operands to account for literal values,
1247         * src/pic16/genutils.c: some new debug functions for gpsim have been
1248         added,
1249         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
1250         float with integer part only,
1251         * src/pic16/main.c (_process_pragma): handle pragma udata access to
1252         place variables in access bank
1253         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
1254         updated sources to reflect recent changes in gen.c
1255
1256 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
1257
1258         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
1259         sources that searched for headers in installation path, now the
1260         device/include/pic16 is used,
1261         * src/pic16/glue.c (pic16glue),
1262         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
1263         .line directives if not in debug mode, this suppresses assembler's
1264         warnings for ignored directives
1265
1266 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
1267
1268         * src/port.h: made reset_regparms prototype void parameter explicit.
1269         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
1270         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
1271         * doc/sdccman.lyx: documented warning disabling and how to use
1272           printf_large to make it print floats.
1273         * device/include/stdbool.h: NEW
1274         * device/lib/_atof.c,
1275         * device/lib/_divuint.c,
1276         * device/lib/_divulong.c,
1277         * device/lib/expf.c,
1278         * device/lib/printf_large.c,
1279         * device/lib/sincosf.c,
1280         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
1281         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
1282           a completely reentrant lib.
1283
1284 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
1285
1286         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
1287         * device/include/pic16/stdio.h: fixed bug with colon
1288
1289 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
1290
1291         * device/include/pic16/stdio.h,
1292         * device/include/pic16/stdlib.h,
1293         * device/include/pic16/math.h: NEW
1294         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
1295         declared as _naked to reduce overhead
1296         * device/lib/Makefile.in (target port-specific-objects-pic16):
1297         changed * to *.* so to ignore the CVS directory,
1298         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
1299         stacked variables back in stack,
1300         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
1301         corruption
1302
1303 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
1304
1305         * .version: bumped version number to 2.4.5
1306         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
1307         * support/Util/SDCCerr.c (messages structure): added entry for
1308         W_POSSBUG2
1309
1310         Large cumulative patch for pic16 port and libraries.
1311         * device/include/pic16/sdcc-lib.h,
1312         * device/include/pic16/stdarg.h,
1313         * device/include/asm/pic16/features.h,
1314         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
1315         * device/include/pic16/float.h: changes reentrant keyword with
1316         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
1317         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
1318         updated target build-libraries to include objects from gptr,
1319         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
1320         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
1321         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
1322         all function headings,
1323         * src/SDCCmain.c: added global parameter userIncDirsSet,
1324         * (parseCmdLine): when option -I is encountered add directory to
1325         userIncDirsSet too,
1326         * src/version.awk: added space between control and long,
1327         * src/pic16/NOTES: added some notes for the port,
1328         * src/pic16/gen.c: added prototype for mov2fp function,
1329         * (fReturnpic16[]): properly named return value registers,
1330         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
1331         * (aopForSym): added code to handle symbols with onStack flag set,
1332         symbols onStack are allocated PTRSIZE bytes,
1333         * (aopFreeAsmop): handles special case where asmops are stack objects,
1334         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
1335         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
1336         added argument lock to trace flaws in allocating temporary registers
1337         when developing port,
1338         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
1339         * (pic16_popRegFromString): reenabled allocating a direct register
1340         from string,
1341         * (assignResultValue): various beautifications,
1342         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
1343         referenced function argument,
1344         * (genIpush): reenabled to allow stacked arguments, handles only
1345         ic->parmPush iCodes,
1346         * (genCall, genPcall): major changes to allow for variable argument
1347         functions, fixed a bug with falsely restoring stack pointer after
1348         returning from call,
1349         * (genFunction): pending code for critical function,
1350         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
1351         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
1352         * (genNearPointerGet): fixed bug with indirect reading, was always
1353         reading from INDF0
1354         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
1355         pointers,
1356         * (genAddrOf): rewrote code to take address of a stacked function parameter
1357         * (genCast): fixed casting to generic pointer type,
1358         * src/pic16/gen.h: added AOP_STA,
1359         * (struct asmop): added field stk,
1360         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
1361         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
1362         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
1363         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
1364         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
1365         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
1366         generic pointers,
1367         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
1368         and library paths,
1369         * (pic16_port structure): generic pointer size is set to 3,
1370         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
1371         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
1372         compiler warning,
1373         * src/pic16/ralloc.c (allocReg): prevent allocating register when
1374         operand is an iTemp,
1375
1376 2004-09-24 Martin Helmling <mh AT octo-soft.de>
1377
1378         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
1379         * debugger/mcs51/simi.c: addapt new syntax of s51
1380
1381 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
1382
1383         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
1384         * src/pic16/pcode.c: commented out some calls to free() in order to
1385         fix bug #989576,
1386
1387 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1388
1389         * src/SDCCicode.h,
1390         * src/SDCCicode.c (isiCodeInFunctionCall),
1391         * src/avr/ralloc.c (selectSpil),
1392         * src/pic/ralloc.c (selectSpil),
1393         * src/pic16/ralloc.c (selectSpil),
1394         * src/ds390/ralloc.c (selectSpil),
1395         * src/hc08/ralloc.c (selectSpil),
1396         * src/xa51/ralloc.c (selectSpil),
1397         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
1398         stack in the middle of a function call sequence (fixes bug #1020268)
1399         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
1400         costs associated with the minimum switch case.
1401
1402 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1403
1404         * src/SDCC.lex: fixed bug #1030549
1405
1406 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1407
1408         * src/SDCCcse.h (struct cseDef),
1409         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
1410         over a function call if the CSE is derived from a symbol whose
1411         address has been taken (fixes bug #1029883)
1412         * support/regression/tests/bug-1029883: a new regression test for
1413         this bug
1414
1415 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1416
1417         * src/hc08/gen.c (emitinline): fixed bug #1029778
1418         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
1419         to a cast object is no longer a syntax error ("fixes" bug #1030006,
1420         and starts toward RFE #905167)
1421
1422 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
1423
1424         * src/pic16/gen.c (mov2f): New function to move an operand to
1425         another without considering if it is a literal or a register,
1426         * (pic16_sameRegs): don't check if they are both AOP_REG,
1427         * (AccRsh): removed andmask=0 lines,
1428         * (genLeftShift): duplicated to be improved in future versions,
1429         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
1430         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
1431         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
1432         * (pic16initMnemonics): added initialization for POC_INFSNZW,
1433         * (insertBankSwitch): fixed inserting banksel directives algorithm
1434         for instructions that follow a skip instruction, this fixes a report
1435         for broken subtraction code generation,
1436         * src/pic16/ralloc.c (deassignLRs): do not free register if current
1437         iCode is a left op, just in case result and right share the same
1438         registers
1439
1440 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1441
1442         * src/hc08/main.c,
1443         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
1444         preservation of HX
1445         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
1446         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
1447         on 2004-09-12; it was buggy
1448
1449 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
1450
1451         * src/SDCCsymt.h: removed RESULT_CHECK
1452         * src/SDCCast.c,
1453         * src/SDCCglue.c,
1454         * src/SDCCval.c,
1455         * src/pic/glue.c,
1456         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
1457
1458 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
1459
1460         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
1461         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
1462         configuration values no more rejected by compiler, they are assigned
1463         to configuration registers with a warning message instead,
1464         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
1465         the for-loop so last conf register is emitted too,
1466         * (_pic16_initPaths): link library libsdcc.lib by default,
1467         * (_hasNativeMulFor): modified test for multiplication according to
1468         Raphael Neider's remarks. Integer multiplication is also done with
1469         support functions,
1470         * device/include/pic16/pic18fregs.h: corrected type error in while
1471         testing and including 18f6720 header file
1472
1473 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
1474
1475         * src/pic16/device.h (pic16_options): removed field use_crt,
1476         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
1477         until an optimization to handle single bits is added,
1478         * (pic16_loadFSR0): moved before genUnpackBits,
1479         * (genAnd): some white lines removed,
1480         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
1481         leave_reset flags in pic16_options when using crt modules,
1482
1483 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
1484
1485         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
1486           for bugs 898889 & 979599. Also used some safer print instructions.
1487
1488 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
1489
1490         * src/pic16/device.h (pic16_options_t): added field use_crt,
1491         crt_name, no_crt,
1492         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
1493         catch a probable future bug,
1494         * src/pic16/gen.c: aopIdx function commented out,
1495         * (genAssign): commented out old code which used aopIdx,
1496         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
1497         code, added if conditionals to take into account the --use-crt
1498         command line options,
1499         * src/pic16/main.c (pic16_optionsTable): added new command line
1500         options, --use-crt= and --no-crt,
1501         * (_pic16_linkEdit): now the proper crt object is added in the
1502         linker command line except than when --no-crt is specified,
1503         * src/pic16/pcode.c,
1504         * src/pic16/pcode.h: added some structures and functions for a new
1505         optimization scheme to compansate for instruction overhead between
1506         same iCodes, this scheme is currently under development and is not
1507         working in any way,
1508         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
1509         to && operator,
1510         * device/lib/pic16/startup/crt0i.c,
1511         * device/lib/pic16/startup/crt0iz.c: added global char variable
1512         __uflags to force the generation of an idata section
1513
1514 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
1515
1516         * doc/Makefile,
1517         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
1518         * doc/sdccman.lyx: updated sdcc version to 2.4.4
1519
1520 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1521
1522         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
1523         Frieder) and clarified the default code optimization mode
1524
1525 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1526
1527         * src/SDCC.lex (doPragma, process_pragma),
1528         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
1529         "opt_code_size", and "opt_code_balanced"
1530         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
1531         regrouped options by category, added support for category headers
1532         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
1533         and "--opt-code-size"
1534         * doc/sdccman.lyx: documented these new options and pragmas
1535         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
1536         preference into account
1537
1538 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
1539
1540         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
1541           geniCodePreDec): Fixed bug 904237 by generating a warning
1542         * src/SDCCerr.h,
1543         * src/SDCCerr.c: added warning W_SIZEOF_VOID
1544
1545 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
1546
1547         * src/pic/device.c : When no max ram set validate full memory range.
1548         * src/pic/pcode.c,
1549         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
1550
1551 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
1552
1553         * device/lib/_gptrget.c,
1554         * device/lib/_gptrput.c: updated comment
1555         * device/lib/calloc.c,
1556         * device/lib/free.c,
1557         * device/lib/malloc.c,
1558         * device/lib/realloc.c: added LGPL, made them reentrant-safe
1559         * src/SDCCcse.c (cseBBlock),
1560         * src/SDCCicode.c (printOperand, geniCodeArray),
1561         * src/SDCCicode.h (struct operand): fixed bug 868103
1562         * support/regression/tests/bug-868103.c: added
1563         * src/SDCCast.c (searchLitOp),
1564         * src/SDCCcse.h (struct cseDef),
1565         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
1566         * src/SDCCicode.h (struct operand),
1567         * src/SDCCsymt.h (struct sym_link),
1568         * src/avr/gen.c (hasInc),
1569         * src/ds390/gen.c (hasInc),
1570         * src/hc08/gen.c (genPlusIncr, hasInc),
1571         * src/mcs51/gen.c (hasInc),
1572         * src/pic16/glue.c (pic16_printIvalChar),
1573         * src/pic16/ralloc.c (regWithIdx),
1574         * src/xa51/gen.c (hasInc) : removed warnings
1575         * src/SDCCast.c (createBlock): added comment ???
1576         * src/hc08/ralloc.c: updated comments
1577
1578 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1579
1580         * doc/sdccman.lyx: updated section on switch statements, added
1581         section about semaphore locking
1582         * doc/Makefile: added option -info for latex2html
1583         * device/lib/_gptrget.c,
1584         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
1585
1586 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
1587
1588         * src/pic/device.h,
1589         * src/pic/device.c,
1590         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
1591          maxram is less than 0x100.
1592
1593 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
1594
1595         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
1596
1597 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1598
1599         * src/port.h,
1600         * src/mcs51/main.c,
1601         * src/ds390/main.c,
1602         * src/z80/main.c,
1603         * src/hc08/main.c,
1604         * src/pic/main.c,
1605         * src/pic16/main.c,
1606         * src/avr/main.c,
1607         * src/xa51/main.c
1608         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
1609         a jump table is the best form for a switch statement, including
1610         automatic insertion of missing cases to make the case range
1611         continuous. Developed in collaboration with Frieder Ferlemann.
1612
1613 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1614
1615         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
1616         accumulator result if it needs sign extension
1617
1618 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
1619
1620         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
1621
1622 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
1623
1624         * device/lib/gbz80/printf.c,
1625         * device/lib/z80/printf.c: removed define for NULL
1626
1627 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
1628
1629         * as/xa51/xa_link.c,
1630         * device/examples/ds390/ow390/ad26.c,
1631         * device/examples/ds390/ow390/cnt1d.c,
1632         * device/examples/ds390/ow390/counter.c,
1633         * device/examples/ds390/ow390/ds2480.h,
1634         * device/examples/ds390/ow390/ds2480ut.c,
1635         * device/examples/ds390/ow390/findtype.c,
1636         * device/examples/ds390/ow390/gethumd.c,
1637         * device/examples/ds390/ow390/owllu.c,
1638         * device/examples/ds390/ow390/ownetu.c,
1639         * device/examples/ds390/ow390/swt12.c,
1640         * device/examples/ds390/ow390/swtloop.c,
1641         * device/examples/ds390/ow390/temp.c,
1642         * device/examples/ds390/ow390/temp10.c,
1643         * device/examples/ds390/ow390/thermo21.c,
1644         * device/examples/ds390/ow390/tinilnk.c,
1645         * device/examples/ds390/ow390/tstfind.c,
1646         * device/examples/serialcomm/windows/serial.cpp,
1647         * device/examples/serialcomm/windows/test_serialcomm.cpp,
1648         * device/include/reg51.h: fixed line endings for cvs
1649
1650 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1651
1652         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
1653         packRegsForAccUse, packRegisters): new accumulator register
1654         packing algorithm
1655         * support/regression/ports/hc08/support.c (_putchar): suppress
1656         warning of unused variable
1657         * src/SDCCicode.c: added SWAP entry to codeTable
1658
1659 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
1660
1661         * device/lib/sprintf.c: forgot to add this file before previous commit
1662
1663 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
1664
1665         * src/pic16/gen.c (genPackBits): added operand right in function
1666         parameters, load result directly if p_type is POINTER (that is
1667         called by genNearPointerSet)
1668         * (genUnPackBits): added operand left in function parameters,
1669         * (genNearPointerGet, genNearPointerSet): prevent the loading of
1670         FSR0 if accessing bitfields,
1671
1672 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
1673
1674         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
1675           _print_format; updated printf, sprintf, vsprintf
1676         * device/include/asm/default/features.h: corrected comment/define
1677         * device/lib/Makefile.in: added sprintf.c
1678         * device/lib/libsdcc.lib: added sprintf module
1679         * device/lib/printf_large.c,
1680         * device/lib/vprintf.c,
1681         * device/lib/sprintf.c: totally refactored printf_large and vprintf
1682           into these 3 files
1683         * support/regression/Makefile: changed ALL_PORTS into a usefull default
1684         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
1685         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
1686           hc08 test
1687         * support/regression/tests/zeropad.c: define idata as data for hc08
1688
1689 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1690
1691         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
1692         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
1693         labels are referenced at least once (even if a reference is not found)
1694         * src/hc08/gen.c (emitcode): set isComment flag for comments
1695         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
1696         loads), rules 6a..6b (optimize jumps to return)
1697
1698 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1699
1700         * device/lib/acosf.c (acosf),
1701         * device/lib/asinf.c (asinf),
1702         * device/lib/atanf.c (atanf),
1703         * device/lib/ceilf.c (ceilf),
1704         * device/lib/cosf.c (cosf),
1705         * device/lib/coshf.c (coshf),
1706         * device/lib/cotf.c (cotf),
1707         * device/lib/fabsf.c (fabsf),
1708         * device/lib/floorf.c (floorf),
1709         * device/lib/log10f.c (log10f),
1710         * device/lib/logf.c (logf),
1711         * device/lib/sinf.c (sinf),
1712         * device/lib/sinhf.c (sinhf),
1713         * device/lib/sqrtf.c (sqrtf),
1714         * device/lib/tanf.c (tanf),
1715         * device/lib/tanhf.c (tanhf),
1716         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
1717         replaced all instances of "reentrant" in the library functions
1718         defined in math.h with this macro.
1719         * support/regression/tests/float_trans.c: reenabled test for hc08
1720
1721 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
1722
1723         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
1724         erroneously deleted
1725
1726 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1727
1728         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
1729         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
1730         multi-byte volatile operands are used
1731         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
1732         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
1733         initialization to area GSINIT0 so that it would always precede
1734         any static initializers in GSINIT
1735         * support/regression/tests/zeropad.c: fixed idata define for hc08
1736         * support/regression/tests/bug-927659.c,
1737         * support/regression/tests/float_trans.c: disabled tests for hc08
1738         pending missing library routines
1739         * .version: increased version number to 2.4.4 - hc08 port now passes
1740         regression tests
1741
1742
1743 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
1744
1745         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
1746         * Makefile.common.in,
1747         * as/Makefile,
1748         * as/hc08/Makefile.in,
1749         * as/mcs51/Makefile.in,
1750         * as/z80/Makefile.in,
1751         * debugger/mcs51/Makefile.in,
1752         * device/include/Makefile.in,
1753         * device/lib/Makefile.in,
1754         * doc/Makefile,
1755         * link/Makefile,
1756         * link/z80/Makefile.in,
1757         * packihx/Makefile.in,
1758         * sim/ucsim/main_in.mk,
1759         * sim/ucsim/avr.src/Makefile.in,
1760         * sim/ucsim/doc/Makefile.in,
1761         * sim/ucsim/gui.src/serio.src/Makefile.in,
1762         * sim/ucsim/hc08.src/Makefile.in,
1763         * sim/ucsim/s51.src/Makefile.in,
1764         * sim/ucsim/xa.src/Makefile.in,
1765         * sim/ucsim/z80.src/Makefile.in,
1766         * src/Makefile.in,
1767         * support/cpp2/Makefile.in,
1768         * support/librarian/Makefile,
1769         * support/makebin/Makefile: added DESTDIR to the install path proposed
1770         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
1771         * doc/sdccman.lyx: added DESTDIR documentation
1772
1773 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
1774
1775         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
1776         instruction for interrupt handlers, use fast returns when returning
1777         from high priority interrupts
1778
1779 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1780
1781         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
1782         code generation
1783         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
1784         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
1785         bugs, ported much of Bernhard's code from mcs51
1786         * src/mcs51/gen.c (genSend),
1787         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
1788         than one when calling a reentrant function
1789         * device/lib/_mullong.c: defined an alternate struct layout for big
1790         endian ports (hc08)
1791
1792 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1793
1794         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
1795         test
1796
1797 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1798
1799         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
1800         are sane and complete before asking the port its prefered parameter
1801         passing method (fixes bug #1017633)
1802         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
1803         and _ret3
1804
1805 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1806
1807         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
1808         problem in bitfields >= 8 bits.
1809
1810 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
1811
1812         * src/SDCCsymt.c: undid changes that were not meant to be committed
1813
1814 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
1815
1816         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
1817
1818 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
1819
1820         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
1821           copied and wrong bit got inverted
1822
1823 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1824
1825         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
1826         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
1827         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
1828         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
1829         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
1830         assignments to bitfields at known addresses
1831         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
1832         reads from bitfields at known addresses
1833         * src/hc08/ralloc.c (packRegisters),
1834         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
1835         genhc08Code): optimize pointer get values used as conditionals
1836         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
1837         and branch
1838
1839 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1840
1841         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
1842         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
1843         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
1844         as conditionals
1845
1846 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1847
1848         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
1849
1850 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1851
1852         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
1853         related problems
1854
1855 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
1856
1857         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
1858
1859 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1860
1861         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
1862         mcs51 port
1863
1864 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
1865
1866         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
1867
1868 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1869
1870         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
1871         cases use more compact code.
1872
1873 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
1874
1875         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
1876
1877 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1878
1879         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
1880
1881 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1882
1883         * src/SDCCsymt.h,
1884         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
1885         parameter of changePointer() from symbol* to sym_link*
1886         * src/SDCCast.c (decorateType): call changePointer() for CAST op
1887         * src/SDCCsymt.c (compareType): void* type is castable to other
1888         pointers, but not necesarily an exact match.
1889         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
1890         is no longer blindly treated as an exact match.
1891         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
1892
1893 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
1894
1895         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
1896
1897 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
1898
1899         * src/pic/gen.c,
1900         * src/pic/pcode.c,
1901         * src/pic/ralloc.h,
1902         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
1903
1904 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
1905
1906         * src/pic/device.c,
1907         * src/pic/device.h,
1908         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
1909
1910 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1911
1912         * src/mcs51/gen.c (emitcode): fixed bug #992819
1913
1914 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
1915
1916         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
1917           there's no need to make it worse
1918
1919 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1920
1921         * src/mcs51/ralloc.c (deassignLR),
1922         * src/ds390/ralloc.c (deassignLR),
1923         * src/hc08/ralloc.c (deassignLR),
1924         * src/z80/ralloc.c (deassignLR),
1925         * src/pic/ralloc.c (deassignLR),
1926         * src/pic16/ralloc.c (deassignLR),
1927         * src/avr/ralloc.c (deassignLR),
1928         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
1929         rlivePoint): fixed another part of bug #971834
1930
1931 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1932
1933         * src/z80/main.c: enabled "critical" keyword
1934         * src/z80/mappings.i,
1935         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
1936         functions (fixes bug #979646)
1937         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
1938
1939 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1940
1941         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
1942           such as c:\mydir.
1943
1944 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
1945
1946         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
1947           doesn't disable too much optimizations
1948
1949 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
1950
1951         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
1952
1953 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
1954
1955         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
1956
1957 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
1958
1959         * src/pic/gen.c tidied up tabs
1960         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
1961         * src/pic/main.c tidied up tabs
1962         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
1963         * src/pic/pcoderegs.c tidied up tabs
1964         * src/pic/ralloc.c tidied up tabs
1965
1966 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
1967
1968         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
1969         to S_FIXED for pic16 port and when symbol is not in level 0,
1970         allocate for S_REGISTER storage class and pic16 port, too,
1971         * src/pic16/device.h: prototype for checkSym,
1972         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
1973         * (pic16_assignConfigWordValue): test the value and the mask to
1974         validate that the value is suitable for the configuration word,
1975         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
1976         collect extern declared symbols, don't emit symbol twice, check
1977         first if symbol is in publics set first,
1978         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
1979         * added command line '--fstack' which enables an experimental
1980         feature for stack access, too buggy to be used yet...
1981         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
1982         * (pic16_allocDirReg): when register has storage class S_REGISTER
1983         allocate in pic16_dynAccessRegs,
1984         * device/include/pic16/pic18f????.h: modified configuration word
1985         naming convention, words started as CONFIG0H but should be CONFIG1H
1986
1987 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
1988
1989         * device/include/mcs51reg.h: fixed bug 970993
1990
1991 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
1992
1993         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
1994         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
1995         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
1996         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
1997         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
1998         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
1999           error/warning numbers,
2000           added function setWarningDisabled()
2001         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
2002         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
2003           _memcmp.c _memmove.c calloc.c realloc.c free.c
2004         * support/regression/tests/malloc.c: added tests for new functionality
2005         * support/regression/tests/zeropad.c: added tests for truncated initializers
2006           and initialized char arrays starting with '\x0'
2007         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
2008
2009 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
2010
2011         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
2012
2013 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2014
2015         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
2016         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
2017         peephole 177.e. Thanks to anonymous
2018
2019 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
2020
2021         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
2022         function isn't used in the source but referenced as a
2023         variable initializer then declare it as extern in .asm file
2024
2025 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
2026
2027         * .version: increased version number to 2.4.3
2028
2029         Adding version extension according to ChangeLog CVS revision
2030         * src/Makefile.in (target all): added dependency 'version.h'
2031         * (rule version.h): added rule to create version.h from ChangeLog,
2032         * (rule dep): added dependency version.h,
2033         * src/version.awk: AWK script to create version.h
2034         * src/SDCCdwarf2.c (dwWriteModule),
2035         * src/SDCCglue.c (initialComments),
2036         * src/SDCCmain.c (printVersionInfo): modified to write after
2037         version string the version extension number,
2038         * src/SDCCutil.c: included "version.h"
2039         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
2040         number,
2041         * src/SDCCutil.h: added prototype for getBuildNumber
2042
2043         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
2044         includeDirsSet, too,
2045         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
2046         const char [] is found in function prototype...
2047
2048         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
2049         moving to WREG with source is already in WREG,
2050         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
2051         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
2052         * (aopForSym): stack'ed symbols are partially supported, added
2053         if-clause to support symbols in FARSPACE,
2054         * (sameRegs): added test for AOP_ACC to see if registers are same,
2055         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
2056         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
2057         * (pic16_popRegFromString): will not allocate a new register if it
2058         doesn't find one by name, bug may have introduced...
2059         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
2060         * (genIpush): revived to use pic16 port's stack,
2061         * (genAddrOf): added incomplete case for stack'ed operand,
2062         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
2063         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
2064         can handle multibyte operands,
2065         * src/pic16/glue.c (pic16_printIval*): some debug info added,
2066         * (pic16initialComments): added message for MPLAB compatibility
2067         mode enabled,
2068         * src/pic16/main.h: prototype for pic16_mplab_comp,
2069         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
2070         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
2071         * (_pic16_linkEdit): NEW, handles link stage, transferred here
2072         because of increased complexity of procedure,
2073         * (_process_pragma): stack pragma changed to format 'stack pos len',
2074         emit symbol '_stack_end' to conform with gplink,
2075         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
2076         to search for register,
2077         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
2078         PO_GPR_REGISTER,
2079         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
2080         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
2081         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
2082         case for PO_GPR_REGISTER,
2083         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
2084         dies, the new era is ahead !...
2085         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
2086         pic16_dynInternalRegs,
2087         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
2088         * (pic16_allocDirReg): minor optimizations and bug fixes,
2089         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
2090
2091         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
2092         load stack and frame pointer with address of 'stack_end' symbol
2093
2094 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
2095
2096         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
2097         without source code but only variable initializers
2098
2099 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
2100
2101         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
2102         external are not declared as extern to reduce overhead while linking
2103
2104 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
2105
2106         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
2107
2108 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
2109
2110         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
2111           Yee Keat for the patch
2112         * src/SDCCast.c (decorateType): fixed bug #979599
2113         * src/ds390/gen.h: removed local fReturnSizeDS390
2114         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
2115         * src/ds390/gen.c (genAnd, genOr, genXor),
2116         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
2117
2118 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
2119
2120         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
2121         add relFilesSet to $3, manipulate $2 to handle linking of object
2122         files without source files in command line,
2123         * device/include/pic16 (all headers): added ID location macros,
2124         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
2125         entries for ID location bytes,
2126         * (pic16_assignIdByteValue): NEW,
2127         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
2128         added field dumpcalltree to pic16_options_t,
2129         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
2130         is used instead of pic16_Gstack_base_addr, check if (ifx) before
2131         emitting rFalseIfx label after check_carry label,
2132         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
2133         pic16_emitDIRegs), NEW
2134         * (pic16glue): dump .calltree file when option --calltree found,
2135         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
2136         * (_pic16_genAssemblerPreamble): emit ID locations after
2137         configuration registers,
2138         * (pic16_linkCmd): modifications of the link command,
2139         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
2140         * (pic16_pCodeInitRegisters): don't init stack registers,
2141         * (pic16_findPrevInstruction): fixed bug,
2142         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
2143         bug with immediate registers,
2144         * (buildCallTree): traces stack push and pop,
2145         * (pct2): dump also stack usage for each function,
2146         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
2147         * (pic16_allocDirReg): various modifications,
2148         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
2149         fixed to 1,
2150
2151 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
2152
2153         * src/pic16/pcode.c: removed buggy double colon
2154
2155 2004-07-01 Borut Razem <borut.razem AT siol.net>
2156
2157         * support/scripts/sdcc.nsi: added include/pic16 to setup
2158
2159 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
2160
2161         * device/lib/Makefile.in: fixed bug in target objects-pic16,
2162         * device/lib/pic16/Makefile: prefixed with dash (-) command under
2163         target 'clean',
2164         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
2165         specific command line arguments. Also added sample lkr script
2166         for placing a variable at a specific memory bank.
2167         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
2168         at a specific memory bank,
2169         * (pic16_dump_isection): fixed bug which caused string literals to
2170         be omitted when dumping idata section,
2171         * (pic16_groupRegistersInSection): added code to handle registers
2172         in specific memory banks,
2173         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
2174         public, all references are renamed too,
2175         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
2176         AOP_DPTR2,
2177         * (pic16_storeForReturn): added case to handle when dest is WREG,
2178         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
2179         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
2180         pic16_rel_udata, check to see if that register is marked as being
2181         a member of a specific memory bank,
2182         * (pic16_printIvalCharPtr): added code to add string literals either
2183         to code or the idata sections,
2184         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
2185         also accept the 'udata' pragma,
2186         * src/pic16/main.h: new structure types sectName and sectSym
2187         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
2188         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
2189         * (pic16_findPrevInstruction): fixed, it returned nothing,
2190         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
2191         instruction combinations,
2192         * (pic16_FixRegisterBanking): heavily reorganised,
2193         * (pic16_AnalyzeBanking): if generating banksel directives is
2194         disabled, then don't call FixRegisterBanking at all,
2195         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
2196         completely removed,
2197         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
2198
2199 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
2200
2201         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
2202         Phuah Yee Keat <yk.phuah AT nestac.com>
2203
2204 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
2205
2206         * src/pic16/glue.c (pic16createInterruptVect): function now emits
2207         correctly the IVT even if it is relocated to some other location
2208
2209 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
2210
2211         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
2212         * device/include/pic16/pic18f2220.h: NEW,
2213         * device/lib/pic16/libdev/pic18f2220.c: NEW,
2214         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
2215         * src/pic16/device.c (struct Pics16): added info for 18f2220,
2216         * src/pic16/device.h (struct pic16_options): added ivt_loc and
2217         nodefaultlibs, ivt_loc is the location of the interrupt vector
2218         table, and nodefaultlibs signs that default libraries should not be
2219         linked in link stage,
2220         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
2221         according to --ivt-loc argument,
2222         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
2223         when pragma stack is found,
2224
2225 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2226
2227         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
2228         256 (range check), 257 (do while), 258.a-f (bit banging
2229         f.e. on 3-wire SPI bus)
2230
2231 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2232
2233         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
2234         variables used exclusively within a loop
2235
2236 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
2237
2238         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
2239
2240 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2241
2242         * src/SDCClrange.c (computeClash): fixed bug #971834
2243
2244 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2245
2246         * src/mcs51/gen.c (genCmp): fixed bug #975903
2247         * src/hc08/gen.c (operandsEqu),
2248         * src/ds390/gen.c (operandsEqu),
2249         * src/z80/gen.c (operandsEqu),
2250         * src/pic/gen.c (operandsEqu),
2251         * src/pic16/gen.c (operandsEqu),
2252         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
2253         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
2254
2255 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2256
2257         * src/SDCCcse.c (cseBBlock): fixed bug #966963
2258
2259 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
2260
2261         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
2262         default case in switch statement,
2263         * glue.c (pic16_initPointer): expr is initialised via decoarteType
2264         to eliminate problem with initialisation of pointers, but problem
2265         still exists,
2266         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
2267         * (emitStaticSegment): removed various lines emitting debug info,
2268         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
2269         added processor registers for utilizing EEPROM,
2270         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
2271         configurable and set 8
2272
2273 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
2274
2275         * .version: increased version number to 2.4.2,
2276
2277         Cumulative patch for pic16 port
2278         * src/pic16/device.c: changed scheme to dump initial values for
2279         variables in idata segment, all print_idata* functions were removed,
2280         now the pic16_printIval* will be called,
2281         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
2282         * _pic16_printPointerType, pic16_printPointerType,
2283         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
2284         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
2285         NEW, similar to the respective functions in SDCCglue.c,
2286         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
2287         way, emitting hex bytes,
2288         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
2289
2290 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2291
2292         * src/avr/ralloc.c (serialRegAssign),
2293         * src/xa51/ralloc.c (serialRegAssign),
2294         * src/pic/ralloc.c (serialRegAssign),
2295         * src/pic16/ralloc.c (serialRegAssign),
2296         * src/hc08/ralloc.c (serialRegAssign),
2297         * src/z80/ralloc.c (serialRegAssign),
2298         * src/ds390/ralloc.c (serialRegAssign),
2299         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
2300
2301 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2302
2303         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
2304         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
2305
2306 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
2307
2308         Cumulative patch for pic16 port:
2309         * src/pic16/device.h (typedef PIC16_device) modified fields for
2310         defining microcontrollers,
2311         * src/pic16/device.c: added new info for all devices in Pics16 array,
2312         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
2313         to be optimised out by the pCode optimiser,
2314         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
2315         specially, bug reported by G.M. Gallant,
2316         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
2317         as force'd so that cannot be optimised out by pCode optimiser,
2318         * src/pic16/pcode.c,
2319         * src/pic16/pcodepeeph.c,
2320         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
2321         they are disabled by default, but can be enabled explicit with
2322         command argument --denable-peeps, for testing,
2323         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
2324         --pomit-ivt in COMPILE_FLAGS
2325
2326 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
2327
2328         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
2329           compilation on MSVC
2330
2331 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
2332
2333         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
2334
2335 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2336
2337         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
2338         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
2339
2340 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
2341
2342         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
2343         would only assign 0x300001 register.
2344
2345 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
2346
2347         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
2348         in COMPILE_FLAGS. Thanks to G. Gallant for report.
2349
2350 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2351
2352         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
2353         for ds80c400
2354         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
2355         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
2356         added peephole 254 (left shift), 255 (jump table)
2357
2358 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
2359
2360         * device/lib/Makefile.in: removed comment line with model-pic16,
2361         * (target port-specific-objects-pic16): the libraries and objects
2362         are copied to the build directory form the device/lib/pic16/bin
2363         directory
2364
2365         Cumulative patch concerning pic16 port:
2366         * library directory has been re-organized,
2367         * added support for PIC18F1220,
2368         * added headers and library sources for chips 18f1220,18f6520,
2369         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
2370
2371         * configuration registers setting has changed, now each supported
2372         device has a complete description of the registers it uses,
2373         * all initialisations are moved to idata sections, these section
2374         can be absolute or relocatable,
2375         * fixed initialisation of codespace variables,
2376         * fixed warning about PCLATU and gpsim,
2377         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
2378         * (genAssign): use table reads when assigning from variables in codespace,
2379         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
2380         char/int variables placed in codespace,
2381         * (pic16_emitConfigRegs): NEW, emits a list with configuration
2382         registers set in .asm file, no need for --pomit-config-words anymore,
2383         * (pic16glue): some 8051 legacy segments are commented out
2384         (to be removed completely),
2385         * added support for alternative assembler and linker with --asm=
2386         and --link= command line arguments,
2387         * peepholes are disabled automatically in the port, no need to
2388         specify on command line,
2389         * port supports natively char/int/long multiplication, but converts
2390         all divisions to support functions,
2391         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
2392         to the file set in variable $2,
2393         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
2394         strings in ASCII format and not in hex,
2395         * ralloc.c (serialRegAssign): added a triplet of conditional calls
2396         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
2397         allocate proper register if iCodes aren't temporary,
2398
2399 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
2400
2401         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
2402
2403 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
2404
2405         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
2406         is commented out
2407
2408 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2409
2410         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
2411         computed address is reused
2412         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
2413         multi-byte bitfields
2414
2415 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
2416
2417         * src/z80/gen.c: (genArrayInit): must check for pointers too
2418
2419 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
2420
2421         * support/regression/tests/zeropad.c: never meant to commit the
2422           nestedstruct test: removed, added check for GCC version
2423
2424 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
2425
2426         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
2427         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
2428         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
2429           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
2430           bugs 928906 and 954082 half-empty initializers
2431         * src/SDCCsymt.h,
2432         * src/SDCCsymt.c (getAllocSize): added for above fix
2433         * src/z80/gen.c (genArrayInit): fixed bug 741044
2434         * support/regression/tests/zeropad.c: added tests
2435
2436 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
2437
2438         * src/pic16/device.c (pic16_dump_section): corrected bug which
2439         caused some symbols of the libraries to be misplaced
2440
2441 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
2442
2443         * src/pic16/glue.c,
2444         * src/pic16/ralloc.h,
2445         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
2446         to fix conflict with pic port
2447
2448 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
2449
2450         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
2451         externs configuration variables,
2452         * src/pic16/ralloc.h,
2453         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
2454         prototype in header, commented out some debug messages
2455
2456 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
2457
2458         * src/pic16/glue.c,
2459         * src/pic16/main.c,
2460         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
2461         for gpasm COFF object generation. Thanks to D. Hawkins for
2462         his patch info
2463
2464 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2465
2466         * src/ds390/main.c,
2467         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
2468         Brock for spotting this)
2469         * src/ds390/gen.c (genEndFunction),
2470         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
2471         interrupt handler and critical. Disable push/pop optimizations when
2472         peephole optimizations disabled.
2473
2474 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
2475
2476         Updated pic16 library sources and headers.
2477         * device/lib/pic16/pic18f*/ ,
2478         * device/include/pic16/*.h: modified to handle structured SFR
2479         definitions
2480
2481 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
2482
2483         * src/port.h (PORT structure): added hook initPaths, now each
2484         port can declare its own default search paths,
2485         which can been seen with the --print-search-dirs option,
2486         see pic16 port for example,
2487         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
2488         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
2489         * (doPrintSearchDirs): NEW, replaces in a central manner the
2490         printing of search dirs which was split in set*Paths functions,
2491         * (main): added call to port->initPaths and doPrintSearchDirs,
2492         * src/avr/main.c,
2493         * src/ds390/main.c,
2494         * src/hc08/main.c,
2495         * src/izt/i186.c,
2496         * src/izt/tlcs900h.c,
2497         * src/mcs51/main.c,
2498         * src/pic/main.c,
2499         * src/pic16/main.c: modified port structures to reflect addition of
2500         initPaths hook,
2501
2502         * src/pic16/device.c (regCompare): registers are finally sorted by name,
2503         * (pic16_dump_section): for registers in same address reserve memory once,
2504         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
2505         to no_banksel,
2506         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
2507         result is greater in size than right or left,
2508         * (pic16_genUMult8X8_8): there are some cases where the result can
2509         be 16 bits size, so handle these,
2510         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
2511         * (pic16_outBitC): modified to emit pcodes,
2512         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
2513         or not,
2514         * (genDivOneByte): implemented algorithm to divide 8-bits,
2515         * (genCmp): uncommented goto, but issues still exist,
2516         * (genAnd): fixed a bug with variables >8bits,
2517         * (genPackBits): optimization added that uses BCF/BSF to change a
2518         single bit,
2519         * (genAssign): fixed bug when assigning floating point literals,
2520         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
2521         __sdcc_gsinit_startup label,
2522         * src/pic16/main.c (_pic16_init): removed search directory
2523         initialisations,
2524         * (_pic16_initPaths): NEW, used to initialise search directories,
2525         * (_hasNativeMulFor): support functions for all except char/int
2526         multiplication, and char division,
2527         * (PIC16_port struct): modified entry for native mul support,
2528         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
2529         no_banksel option,
2530         * (buildCallTree): call to register_usage is ifdef'ed out,
2531
2532 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2533
2534         * device/include/string.h: applied Stas Sergeev's patch to make this
2535         header file compatible with the preprocessor -Wundef option
2536         * src/SDCCmain.c (main): abort compilation if preprocessor reports
2537         failure (fixes bug #941458)
2538
2539 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2540
2541         * src/SDCCopt.c (killDeadCode): fixed bug #907733
2542         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
2543         that the variable, not the function, should be static
2544         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
2545         to be consistent with non-literal case
2546
2547 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2548
2549         * src/SDCCast.c (isConformingBody): fixed bug #949967
2550         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
2551         convilong): fixed bug #952086
2552
2553 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2554
2555         * src/SDCCmem.c (allocVariables): fixed bug #955321
2556
2557 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2558
2559         * src/hc08/main.c (_hc08_genAssemblerEnd),
2560         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
2561         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
2562         completely eliminated the use of a temporary file
2563         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
2564         when more than one file linked
2565         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
2566
2567 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2568
2569         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
2570         which fixes bug #543481
2571         * support/regression/tests/bug-751703.c: fixed comments left from a
2572         cut and paste error
2573         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
2574         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
2575         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
2576         scopes
2577         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
2578         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
2579         are now changed to underscores in moduleName
2580
2581 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2582
2583         * as/mcs51/lkmem.c: better fix for bug #954173
2584
2585 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2586         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2587
2588         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
2589         * device/include/c8051f000.h,
2590         * device/include/c8051f120.h,
2591         * device/include/c8051f300.h,
2592         * device/include/c8051f310.h,
2593         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
2594         PWM16) and detab'ed
2595
2596 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2597
2598         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
2599         and mailing lists, doc'ed --no-peep-comments, removed reference
2600         to knoppix (newest version has no LyX/LaTeX), other minor changes
2601         * src/SDCCglue.c (glue): save 2 bytes stack space with
2602         option --main-return. The ljmp could probably be avoided too
2603
2604 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2605
2606         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
2607
2608 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2609
2610         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
2611         * src/SDCCopt.c (isLocalWithoutDef),
2612         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
2613         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
2614         (credit to Maarten Brock for patch #949363, on which this is based)
2615         * support/regression/tests/bug-751703.c: some test cases of extern used
2616         within inner scopes.
2617
2618 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2619
2620         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
2621         SPEC_STRUCT
2622         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
2623         struct definitions
2624         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
2625         dwWriteLabel): fix to create valid debugger symbols even when
2626         the module name has non-alphanumeric symbols in it
2627         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
2628         when a variable's allocation has been optimized away
2629
2630
2631 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2632
2633         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
2634         * src/hc08/main.c,
2635         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
2636         * src/mcs51/main.c,
2637         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
2638         * src/ds390/main.c,
2639         * src/z80/gen.c (z80_emitDebuggerSymbol),
2640         * src/z80/main.c,
2641         * src/pic/gen.c (pic14_emitDebuggerSymbol),
2642         * src/pic/main.c,
2643         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
2644         * src/pic16/main.c,
2645         * src/avr/gen.c (avr_emitDebuggerSymbol),
2646         * src/avr/main.c,
2647         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
2648         * src/xa51/main.c,
2649         * src/SDCCdebug.c (emitDebuggerSymbol),
2650         * src/SDCCdebug.h,
2651         * src/port.h: added a debugger struct to the port struct. Added a
2652         callback for defining debugger symbols
2653
2654         * src/SDCCast.c (createLabel),
2655         * src/SDCC.y (labeled_statement): mark all compiler generated labels
2656         with isitmp = 1
2657         * src/SDCCicode.h,
2658         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
2659         iCode back to the ast for the function
2660
2661         * src/hc08/ralloc.c (hc08_assignRegisters),
2662         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
2663         unneeded fields from the regs struct.
2664         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
2665         pushReg() & pullReg() functions instead of emitcode()
2666
2667         * src/hc08/gen.c (genLabel, genhc08Code),
2668         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
2669
2670         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
2671         debugger hooks
2672
2673         * src/hc08/gen.c (genEndFunction, genhc08Code),
2674         * src/hc08/gen.h,
2675         * src/mcs51/gen.c (genEndFunction, gen51Code),
2676         * src/mcs51/gen.h,
2677         * src/ds390/gen.c (genEndFunction, gen390Code),
2678         * src/ds390/gen.h,
2679         * src/z80/gen.c (genEndFunction, genZ80Code),
2680         * src/z80/gen.h,
2681         * src/z80/z80.h,
2682         * src/pic/gen.c (genEndFunction, genpic14Code),
2683         * src/pic/gen.h,
2684         * src/pic16/gen.c (genEndFunction, genpic16Code),
2685         * src/pic16/gen.h,
2686         * src/avr/gen.c (genEndFunction, genAVRCode),
2687         * src/avr/gen.h,
2688         * src/xa51/gen.c (genEndFunction, genXA51Code),
2689         * src/xa51/gen.h,
2690         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
2691         specific code to cdbFile.c and out of the backend code generators
2692
2693         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
2694         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
2695         starting address is now 0
2696
2697         * as/hc08/asm.h,
2698         * as/hc08/m08pst.c,
2699         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
2700         assembler directive for DWARF support
2701         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
2702
2703         * src/src.dsp,
2704         * src/Makefile.in,
2705         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
2706
2707 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2708
2709         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
2710         and inappropriate peephole optimization in jump tables
2711
2712 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2713
2714         * as/hc08/m08pst.c,
2715         * src/SDCCglue.c: sdccopt works for the hc08 port now
2716
2717 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
2718
2719         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
2720
2721 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2722
2723         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
2724
2725 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2726
2727         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
2728         rules
2729         * src/SDCCmain.c,
2730         * src/SDCCglobl.h,
2731         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
2732         comments from the peephole optimizer replacement rules
2733         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
2734         symbols
2735         * src/SDCCcse.c (updateSpillLocation),
2736         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
2737         equivalents
2738         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
2739         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
2740         objects far pointers
2741
2742 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2743
2744         * src/SDCCsymt.h: a missing part of my last change
2745         * src/pic/ralloc.c (regTypeNum),
2746         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
2747
2748 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2749
2750         * src/SDCCicode.h,
2751         * src/SDCCicode.c (aggrToPtrDclType),
2752         * src/SDCCptropt.h,
2753         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
2754         ptrPseudoSymConvert),
2755         * src/pic/ralloc.c (regTypeNum),
2756         * src/pic16/ralloc.c (regTypeNum),
2757         * src/hc08/ralloc.c (regTypeNum),
2758         * src/ds390/ralloc.c (regTypeNum),
2759         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
2760         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
2761
2762 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2763
2764         * link/z80/lkmain.c (afile),
2765         * as/hc08/lkmain.c (afile),
2766         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
2767         prevent a pointer problem when a filename has no directory and
2768         no extension specified.
2769
2770 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2771
2772         * link/z80/lkmain.c (afile): allow periods in directory names
2773         * link/z80/lkmain.c (afile),
2774         * as/mcs51/lkmain.c (afile),
2775         * as/hc08/lkmain.c (afile): allow linker script file to have an
2776         extension other than ".lnk"
2777         * link/z80/lklex.c (getfid),
2778         * link/z80/lkmain.c (parse),
2779         * as/mcs51/lklex.c (getfid),
2780         * as/mcs51/lkmain.c (parse),
2781         * as/hc08/lklex.c (getfid),
2782         * as/hc08/lkmain.c (parse): Support comments in the linker script
2783         file on lines by themselves and after filenames
2784
2785 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2786
2787         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
2788
2789 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2790
2791         * src/z80/peeph-z80.def: removed some peephole rules that don't
2792         work with multibyte arithmetic (fixed bug #937126)
2793         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
2794         to registers and not global variables
2795         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
2796         geniCodePreInc, geniCodePostDec, geniCodePreDec,
2797         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
2798         checking for assignments not internally generated (fixed bug #931895)
2799         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
2800         structure member (fixed bug #930072)
2801
2802 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2803
2804         * src/SDCCmain.c (linkEdit),
2805         * src/hc08/main.c (_hc08_parseOptions),
2806         * as/hc08/Makefile.in,
2807         * as/hc08/aslink.h,
2808         * as/hc08/asm.h,
2809         * as/hc08/m08pst.c,
2810         * as/hc08/lkrloc.c (relr, rele),
2811         * as/hc08/lkarea.c (lnkarea)
2812         * as/hc08/lkmain.c (afile, parse),
2813         * as/hc08/lkelf.c: support for ELF output
2814         * as/hc08/lks19.c (s19),
2815         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
2816
2817 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2818
2819         * as/mcs51/lkihx.c: Fixed bug #899105.
2820
2821 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2822
2823         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
2824         .dsp files from Unix to DOS.
2825
2826 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2827
2828         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
2829         function pointers; we have been compliant for several months now.
2830         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
2831         change that was accidently commented out
2832         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
2833         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
2834         bug #922319
2835
2836 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2837
2838         * src/hc08/gen.c: output of all of the internal debugging information
2839         is now controlled by the D() macro; it is disabled by default
2840
2841 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2842
2843         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
2844         harder to keep the same registers during a CAST iCode
2845         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
2846         long via int can be done in a single cast, if the signedness is
2847         correct.
2848         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
2849         putchar() in tinibios.c in ds390's library
2850
2851 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
2852
2853         * src/SDCCast.c (decorateType): fixed bug #898889,
2854         cast result of a literal complement too
2855         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
2856         fixed check for bitfields
2857
2858 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
2859
2860         * src/SDCCicode.c (geniCodeLogic): made it static,
2861         (geniCodeLogicAndOr): added in order to fix bug #905492,
2862         (ast2iCode): fixed bug #905492
2863         * support/regression/tests/bug-905492.c: added
2864         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
2865         (processParms): fixed bug #927659: don't copy parms, this will clear
2866         decorated flag
2867         * support/regression/tests/bug-927659.c: added
2868
2869 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
2870
2871         * src/SDCCast.c (addCast): don't cast float to char
2872         * device/lib/libsdcc.lib: added _memmove
2873
2874 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
2875
2876         * device/lib/large/Makefile: fixed parallel execution by
2877         replacing `make` by `$(MAKE)`
2878
2879 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2880
2881         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
2882         offsets (fixes bug #923936)
2883
2884 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
2885
2886         * device/lib/small/Makefile: fixed parallel execution by
2887         replacing `make` by `$(MAKE)`
2888
2889 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
2890
2891         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
2892
2893 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
2894
2895         * src/pic/gen.c (genCpl): multi-byte complements were not working.
2896         * src/regression/Makefile: Regression test was not running.
2897
2898 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
2899
2900         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
2901         complement if possible
2902         * src/SDCCval.c (valComplement),
2903         * src/SDCCicode.c (operandOperation): fixed complement of literal
2904         * support/regression/tests/onebyte.c (testComplement): added
2905
2906 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
2907
2908         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
2909         return an optimized tree; actually replace actParm with the new tree
2910         * src/SDCCast.h: added some parantheses to remove side effects
2911         * support/regression/tests/bug-920866.c
2912
2913 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
2914         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
2915         Bit operands were not being handled properly in the pic14 port.
2916         (now src/regression/add.c passes again).
2917
2918 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2919
2920         * src/SDCC.y (labeled_statement): case and default no longer require
2921         a following statement (RFE #893037)
2922
2923 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2924
2925         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
2926         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
2927         disabled (fixes bug #916294)
2928         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
2929         "mov a,acc"; patch provided by Lenny Story
2930         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
2931
2932 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2933
2934         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
2935         functions
2936         * src/ds390/gen.c (genFunction, genEndFunction),
2937         * src/ds390/ralloc.c (ds390_assignRegisters),
2938         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
2939         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
2940         pushed if there are parameters passed on the stack. Also, a cleaner
2941         way to decide if r0/r1 should be pushed/popped. (Together they fix
2942         bug #918693)
2943
2944 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2945
2946         * doc/sdccman.lyx,
2947         * device/lib/mcs51/crtpagesfr.asm,
2948         * device/lib/mcs51/crtxinit.asm,
2949         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
2950         to avoid confusion with Si Lab's SFRPAGE register.
2951
2952 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2953
2954         * src/SDCCglue.c (emitMaps): allow public sfr variables
2955         * src/SDCCglue.c (initialComments): include compiler build date
2956         with compiler version and put the timestamp of the generated
2957         assembly file on a serperate line to be less confusing.
2958         * src/port.h: added genInitStartup hook
2959         * src/avr/main.c,
2960         * src/ds390/main.c,
2961         * src/hc08/main.c,
2962         * src/pic/main.c,
2963         * src/pic16/main.c,
2964         * src/xa51/main.c,
2965         * src/z80/main.c: genInitStartup initialize as NULL (default to
2966         historical behaviour)
2967         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
2968         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
2969         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
2970         library instead of hard coding it into the compiler.
2971         * support/regression/ports/mcs51-stack-auto/spec.mk,
2972         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
2973         * device/lib/mcs51/Makefile,
2974         * device/lib/small/Makefile,
2975         * device/lib/large/Makefile,
2976         * device/lib/mcs51/crtpagesfr.asm,
2977         * device/lib/mcs51/crtstart.asm,
2978         * device/lib/mcs51/crtxclear.asm,
2979         * device/lib/mcs51/crtxinit.asm,
2980         * device/lib/mcs51/crtclear.asm,
2981         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
2982         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
2983         and into user configurable files.
2984         * device/lib/clean.mk: clean mcs51 directory too
2985         * support/regression/tests/longlit.c: added static to T1 declaration
2986         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
2987         accesses in the initialization code
2988
2989 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2990
2991         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
2992         OSCTRIMVAL as noted in bug #916008
2993
2994 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2995
2996         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
2997         in loops with multiple exits (reported as incorrect registers
2998         used by Martin Helmling in Sdcc-user list)
2999
3000 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3001
3002         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
3003         made ds390 register extensions look less like error messages
3004
3005 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3006
3007         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
3008         reported by Adam Wozniak in Sdcc-user list
3009
3010 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
3011
3012         * src/SDCCast.c (decorateType): fixed with bug and promotion in
3013         arithmetic optimizations, added debug output
3014
3015 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
3016
3017         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
3018         * sdcc.spec: updated and split sdcc into 3 rpms
3019         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
3020         needed for literals of LEFT_OP and '+'
3021         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
3022         introduced RESULT_TYPE_NOPROM
3023         (geniCodeMultiply): fixed logic for decision if mul is optimized to
3024         left shift
3025         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
3026         limited promotion to int only for '*'
3027         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
3028
3029 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
3030
3031         * src/pic16/gen.c (genSkip),
3032         (genc16bit2lit), (gencjneshort): commented out
3033         (is_LitOp): new helper function, checks operand type
3034         (genCmpEq): rewritten
3035
3036 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
3037
3038         * support/regression/tests/bug-908454.c: added
3039
3040 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
3041
3042         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
3043         * src/SDCCicode.c (usualBinaryConversions): op needs int type
3044         (geniCodeCast): cosmetic, don't preserve bit storage class
3045         (geniCodeLeftShift): added promotion
3046         (geniCodeLogic): fixed regression
3047         * src/SDCCsymt.c (computeTypeOr): accept bits too
3048         (compareType): 2nd part of fix for bug #908454, needed for bitfields
3049
3050 2004-03-07  Borut Razem <borut.razem AT siol.net>
3051
3052         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
3053
3054 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
3055
3056         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
3057         version of pic16_genPackRegisters which does not check if ic is a
3058         CAST operator,
3059         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
3060         function cause string1.c regression test fails
3061
3062 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
3063
3064         * sim/ucsim/configure.in,
3065         * sim/ucsim/configure,
3066         * sim/ucsim/doc/Makefile.in: use docdir
3067         * src/SDCC.y: fixed sbit atrributes
3068         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
3069         * src/SDCCast.c (decorateType): |^& need special promotion handling
3070         * src/SDCCast.h,
3071         * src/SDCCsymt.h: moved definition of RESULT_TYPE
3072         * src/SDCCsymt.h (computeType),
3073         * src/SDCCicode.c: computeType() needs op
3074         * src/SDCCsymt.c (checkTypeSanity),
3075         * doc/sddman.lyx: "plain" bitfields are unsigned
3076         * src/SDCCsymt.c (computeTypeOr): added
3077         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
3078         |^& ops
3079         * src/SDCCval.c (val*): computeType() needs op
3080         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
3081         * support/regression/tests/onebyte.c: added tests for |^&
3082
3083 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
3084
3085         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
3086         for writing icode into asm output.
3087
3088 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
3089
3090         * src/pic16/device.c: added some debug lines enabled
3091         with macro DEBUG_CHECK,
3092         * src/pic16/genarith.c: more debug in genPlus,
3093         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
3094         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
3095         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
3096         * (aopForSym): onStack symbols are re-placed in data memspace,
3097         and onStack flag is cleared,
3098         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
3099         copy temporary pcodeop,
3100         * (genPcall): added warning for not updating PCLATU,
3101         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
3102         always true for pic16 port,
3103         * (genMultOneWord): NEW, supports integer multiplication,
3104         * (genMult): modified to call genMultOneWord,
3105         * (ifxForOp): added warning when return NULL,
3106         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
3107         flag is set before call to operandFromSymbol for implicit
3108         added structures,
3109         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
3110         options.intlong_rent are set by default,
3111         * (_hasNativeMulFor): modified to allow port generation of integer
3112         multiplication,
3113         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
3114         set regtype to REG_SFR for all registers, restricting seting the
3115         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
3116
3117 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3118
3119         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
3120         more than 500 times in the regression tests
3121
3122 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3123
3124         * support/Util/SDCCerr.h,
3125         * support/Util/SDCCerr.c,
3126         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
3127         enumerator_list),
3128         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
3129         for symbol conflicts.
3130         * support/valdiags/tests/enum.c,
3131         * support/valdiags/tests/tentdecl.c,
3132         * support/valdiags/tests/struct.c: expect possible error messages
3133         referring to original symbol definitions.
3134         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
3135         * src/SDCCsymt.h,
3136         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
3137
3138 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
3139
3140         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
3141
3142 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
3143
3144         * src/pic16/ralloc.c (newReg): fixed bug #908929
3145
3146 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3147
3148         * src/ds390/gen.c: added missing #include "main.h"
3149
3150 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
3151
3152         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
3153         checking if symbol is already in set,
3154         * src/pic16/device.h: prototype for checkAddSym,
3155         * src/pic16/gen.c: (_G): added entry interruptvector,
3156         * (assignResultValue): removed some commented out lines,
3157         * (genFunction): check for ISR via sym->type, absolute section for
3158         interrupt code is created via a new pBlock, the goto instruction is
3159         placed now correctly at the interrupt vector position, changed all
3160         references from ivec to _G.interruptvector,
3161         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
3162         is the interrupt is a high priority one, same for return from ISR,
3163         * src/pic16/glue.c: changed all calls of addSetHead for publics and
3164         externs to calls of checkAddSym,
3165         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
3166         pic16_pcode_verbose flag is set,
3167         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
3168         * src/pic16/pcoderegs.c: message about how many registers are saved
3169         will only be emitted if pic16_pcode_verbose flag is set,
3170
3171 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3172
3173         * src/ds390/ralloc.h,
3174         * src/ds390/ralloc.c (ds390_regWithIdx),
3175         * src/ds390/gen.c (emitcode),
3176         * src/ds390/main.h,
3177         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
3178         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
3179         ds390operandCompare, getRegsRead, getRegsWritten,
3180         initializeAsmLineNode): customized instruction size calculation for
3181         ds390, started basis for some register optimizations
3182         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
3183         corresponding assembly output
3184         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
3185         missing push/pop of r0/r1. Optimized push/pops
3186
3187 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3188
3189         * src/mcs51/main.c (instructionSize): fixed ACALL size
3190         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
3191
3192 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
3193
3194         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
3195         the sorting of rlist with NULL elements
3196         * (print_idataType, print_idata): NEW to create idata sections
3197         * src/pic16/device.h: idataSymSet new variable
3198         * src/pic16/gen.c (genFunction): fixed some bugs in string
3199         comparing, improved the absolute section creation for ISRs,
3200         added FSR0L/FSR0H in registers that are saved in an ISR,
3201         * (genInline): fixed the processing of inline snippets,
3202         now they undergo no process by the peephole optimizer
3203         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
3204         are placed in idataSymSet,
3205         * (pic16emitStaticSeg): extern symbols are added in externs,
3206         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
3207         switching when aboslute variables are placed in access bank memory
3208         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
3209         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
3210         commented out with #if,
3211         * (pic16_packRegisters): reintroduce the check for CAST because some
3212         symbols are not correctly handled,
3213         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
3214         pCodeInstruction instead of pCode,
3215         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
3216         pCodeAsmDir definition,
3217         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
3218         directive, then the argument directive is emitted without the leading
3219         tab, hack for inline labels which must be in the first column,
3220         * (compareLabel,pic16_findNextInstruction),
3221         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
3222         * (insertBankSwitch): modified for the new pCodeAsmDir,
3223
3224 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
3225         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
3226
3227         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
3228         instance,
3229         * (pushSide): commented out with #if,
3230         * (assignResultValue): fixed some typos in saving
3231         registers,
3232         * (genPcall): FIXED and sync'ed with genCall,
3233         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
3234         * (genNearPointerGet): fixed to handle some more cases,
3235         implementation scheme via table reads,
3236         * (genConstPointerGet): modified to access code memory correct,
3237         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
3238         and improved to handle some cases
3239         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
3240         instead of "RETLW" for init data
3241         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
3242         not IN_DIRSPACE, work around to reduce bank switching when aboslute
3243         variables are placed in access bank memory (<0x80 and >=0xf80),
3244         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
3245         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
3246         TBLWT_POSTDEC,TBLWT_PREINC
3247         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
3248         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
3249         directives
3250         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
3251         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
3252         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
3253         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
3254
3255 2004-02-29  Borut Razem <borut.razem AT siol.net>
3256
3257         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
3258         support/Util/findme.h, support/Util/system.h: enhance binary relative
3259         search for lib and include by using findProgramPath()
3260
3261 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3262
3263         * src/SDCCpeeph.h,
3264         * src/SDCCpeeph.c (pcDistance),
3265         * src/port.h,
3266         * src/mcs51/ralloc.h,
3267         * src/mcs51/ralloc.c (mcs51_regWithIdx),
3268         * src/mcs51/main.h,
3269         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
3270         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
3271         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
3272         size calculation port specific, started basis for some register
3273         optimizations
3274         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
3275         missing push/pop of r0/r1. Optimized push/pops
3276         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
3277         * device/lib/_modsint.c (_modsint),
3278         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
3279         and stack version so regression tests pass
3280
3281 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
3282
3283         * src/Makefile.in (dep): include SLIBOBJS in dependency check
3284         * src/SDCCast.c (decorateType): catch another small optimization
3285         with '?' operator
3286         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
3287         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
3288         modified to finally use computeType() all over SDCC,
3289         see Feature Request #877103
3290         * src/SDCCval.h: cosmetic
3291         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
3292         valCompare(); regression tested in muldiv.c
3293         * support/regression/tests/muldiv.c (testMod): mod sign follows
3294         dividend only
3295
3296 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
3297
3298         * src/SDCCast.c (decorateType): fixed bug #902362
3299         * doc/INSTALL.txt: fixed install instructions for win32
3300
3301 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
3302
3303         * device/include/Makefile.in (install): fixed by replacing spaces
3304         by tabs
3305         * doc/README.txt,
3306         * doc/INSTALL.txt: updated for release
3307         * doc/sdccman.lyx: added warning for --xstack being buggy
3308
3309 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
3310
3311         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
3312         to eliminate build warnings.
3313         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
3314
3315 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
3316            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
3317
3318         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
3319         removed -penable-stack, added comment for stack pragma, added
3320         warning for not initializing the stack/frame registers, removed
3321         comment at interrupts section
3322
3323         Stack is made permanent, there is no ability to disable stack usage.
3324         * src/pic16/device.h,
3325         * src/pic16/device.c: removed all references to USE_STACK macro,
3326         * src/pic16/device.c (pic16_dump_section): when no elements in
3327         rlist, free rlist before return,
3328         * (pic16_dump_int_registers): NEW, internal registers are a new set
3329         of general purpose registers reused by each function,
3330         * (checkAddReg): returns 1 if registers is added to set,
3331         * (pic16_groupRegistersInSection): when a registers is of type
3332         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
3333         * src/pic16/device.h: memRange and Assigned Memory are deleted,
3334         SRCASECMP macro is moved here from device.c
3335         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
3336         PO_PCLATU, PO_PRODL, PO_PRODH,
3337         * (pic16_pCodeOpType, genMinus,
3338         changed compares to "a" register, with AOP_ACC,
3339         * (pic16_genPlus): fixed some bugs and indented properly,
3340         * (pic16_addSign): changed size to size+offset in the MOVWF
3341         instruction,
3342         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
3343         multiply 8-bit operand by literal, result is 8-bit,
3344         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
3345         multiply 2 8-bit operand, result is 8-bit,
3346         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
3347         genUMult8X*_16,
3348         * src/pic16/gen.c: changed accUse to contain WREG only,
3349         * (pic16_emitcomment): renamed to pic16_emitpcomment,
3350         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
3351         true, do not use immediate addressing any more unless sym is a
3352         pointer in codespace,
3353         * (aopForRemat): do not use immediate addressing when symbol not in
3354         codespace and when symbol's address is requested,
3355         * (aopOp): for-loop in if(sym->accUse) is modified for the new
3356         accUse size (= 1),
3357         * (aopGet): added case for AOP_ACC and don't return "accumulator
3358         bug" but WREG instead,
3359         * (popGetTempReg): pushes contents of temporary register in stack,
3360         * (popReleaseTempReg): pops contents of temporary register from
3361         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
3362         * (pic16_popGet): separated case AOP_ACC to return register WREG
3363         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
3364         or PO_IMMEDIATE and initializes their instance/offset appropriately,
3365         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
3366         the use of immediate pointers to certain cases only.
3367
3368         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
3369         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
3370         * (assignResultValue, genCall, genRet): modified to use the new
3371         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
3372         genPcall is still broken,
3373         * (genFunction): added code to create 'A' type pBlocks when
3374         interrupt functions are generated, code not extensively tested yet,
3375         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
3376         * (genEndFunction): modified so ISRs pop stored registers from stack,
3377         * (genMultOneByte): cleanup,
3378         * (AccRsh): added flag andmask, to and result with appropriate mask,
3379         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
3380         * (genDataPointerGet): fixed and reenabled its use,
3381         * (genNearDataPointerGet): bugs fixed,
3382         * (genDataPointerSet): bugs fixed,
3383         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
3384         pic16_DumpSymbol, pic16_DumpOp,
3385         * src/pic16/genutils.h: function prototypes for the above functions,
3386         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
3387         pointers,
3388         * (pic16emitRegularMap): many many many improvements, but needs a
3389         major cleanup,
3390         * src/pic16/main.c: enable_stack in pic16_options is removed,
3391         * (_pic16_parseOptions): removed command line options -penable-stack,
3392         * (_process_pragma): emit stack symbol only when stack pragma is
3393         processed,
3394         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
3395         redirected to FSR0L/FSR0H pair,
3396         * (pic16_get_op, pic16_get_op2): modifications and improvements,
3397         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
3398         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
3399         for immediates,
3400         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
3401         * (dumpPicOptype): NEW,
3402         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
3403         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
3404         with movff instruction,
3405         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
3406         added pic16_int_regs, some packRegsFor* functions are commented out,
3407         because produce errors,
3408         * src/pic16/NOTES: minor modifications
3409
3410 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3411
3412         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
3413         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
3414         --pack-iram.
3415         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
3416         * as/mcs51/lkaomf51.c: fixed bug #895763
3417
3418 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
3419
3420         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
3421
3422 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3423
3424         * doc/sdccman.lyx: added details about the HC08 storage classes and
3425         interrupts, fixed the register usage info for z80 & gbz80
3426
3427 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
3428
3429         * doc/sdccman.lyx: added more pic16 port documentation
3430         * device/include/pic16/: added header pic18fregs.h
3431
3432 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
3433
3434         * doc/sdccman.lyx: added Vangelis' contribution
3435
3436 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3437
3438         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
3439         extend to the next CALL or PCALL, not just to the next CALL.
3440
3441 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
3442
3443         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
3444
3445 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3446
3447         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
3448         bug #895752 and a better fix for bug #716790
3449
3450 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3451
3452         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
3453
3454 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3455
3456         * doc/sdccman.lyx: minor changes, minor changed
3457
3458 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
3459
3460         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
3461         which can't handle SDCC_NEWONEBYTEOPS,
3462         (geniCodeMultiply): removed conversion from mult to shift for pic14
3463         and pic16
3464
3465 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3466
3467         * src/hc08/gen.h,
3468         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
3469         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
3470         thus fixing bug #895406
3471
3472 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
3473
3474         * device/lib/_modsint.c,
3475         * device/lib/_modslong.c: sign follows divisor only
3476         * src/hc08/gen.c (genMultOneByte): if result size is 1,
3477         signs or signedness can be ignored
3478         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
3479         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
3480         added optimization for IFX,
3481         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
3482         arguments;
3483         reenabled optimization for IFX, which was removed on 2004-01-11
3484         * src/SDCCast.h: added return type IFX
3485         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
3486         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
3487         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
3488         SDCC_OLDONEBYTEOPS selects the old behaviour
3489         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
3490         changed again and commented promotion rule
3491         * src/SDCCval.c (valDiv): promotion no longer necessary
3492         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
3493         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
3494         rewritten
3495         * support/regression/tests/onebyte.c: added
3496
3497 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
3498
3499         * gen.c (genInline): reverted to old code for assemnling inline
3500         code because of bug reported James Chadd
3501
3502 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
3503
3504         * ralloc.h: missing declarations from previous patch,
3505         seems that patch for ralloc.h was never applied, fixed
3506
3507 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
3508            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
3509
3510         * pcode.c,
3511         * pcode.h,
3512         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
3513         indirect addressing. Marked FSR0 as deprecated
3514         * gen.c (pointerCode): commented out, not needed now
3515         (pic16_popGet2p): new MOVFF helper function
3516         (genGenPointerGet),
3517         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
3518         (shiftRLong): removed duplicate debugging info
3519
3520 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3521
3522         * src/ds390/gen.c (genNearPointerGet),
3523         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
3524         optimization with bits, but not bitfields.
3525         * src/ds390/ralloc.c (packRegisters),
3526         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
3527
3528 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
3529
3530         * src/SDCCcse.c (algebraicOpts): copy operands before modification
3531
3532 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3533
3534         * src/SDCCsymt.h,
3535         * src/SDCCicode.c (operandFromSymbol),
3536         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
3537         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
3538         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
3539         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
3540         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
3541         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
3542         bug #892038
3543         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
3544         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
3545         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
3546         * src/SDCCsymt.c (newSymbol),
3547         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
3548         enumerator_list),
3549         * src/SDCCval.h,
3550         * src/SDCCval.c (newiList): fixed bug #885705
3551
3552 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3553
3554         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
3555         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
3556
3557 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3558
3559         * device/include/c8051f120.h,
3560         * device/include/c8051f300.h,
3561         * device/include/c8051f310.h: added/updated header files for Silicon
3562         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
3563         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
3564         in new section Submitting patches
3565
3566 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3567
3568         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
3569         genFarPointerGet, genCodePointerGet, genGenPointerGet,
3570         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
3571         genGenPointerSet),
3572         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
3573         genFarPointerGet, genCodePointerGet, genGenPointerGet,
3574         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
3575         genGenPointerSet),
3576         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
3577         genFarPointerGet, genCodePointerGet, genGenPointerGet,
3578         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
3579         genGenPointerSet),
3580         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
3581         genFarPointerGet, genCodePointerGet, genGenPointerGet,
3582         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
3583         genGenPointerSet): fixed bug #892400
3584         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
3585         to eliminate build warnings.
3586         * src/SDCCast.c (processParms),
3587         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
3588         fixed bug 751859
3589         * support/valdiag/valdiag.py: added GCC to the list of defines active
3590         when compiling with gcc
3591
3592 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3593
3594         * support/Util/SDCCerr.h,
3595         * support/Util/SDCCerr.c,
3596         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
3597         with an incomplete type (fixed bug #883734)
3598         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
3599
3600 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3601
3602         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
3603
3604 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3605
3606         * src/SDCCast.c (decorateType),
3607         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
3608         function pointer implementation
3609         * support/regression/tests/funptrs.c: added tests to verify both forms
3610         of function pointers work correctly. Added tests to verify parameters
3611         are passed in the correct order.
3612
3613 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
3614
3615         * device.c (regCompare): registers are sorted by ascending
3616         address and increasing size,
3617         * main.c (_pic16_finaliseOptions): removed the declaration
3618         of compiler macro MCU. Now a macro of the format pic18fxxxx
3619         will be defined from the command line
3620
3621 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
3622             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
3623
3624         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
3625         PCOP_RLCF was overwritten!
3626         * gen.c (genSkip): commented out calls to pic16_emitcode,
3627         * (genCmpEQ): fixed "long" compares, only high word did get compared,
3628         * (genlshTwo),
3629         * (genRRC): added debugging info,
3630         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
3631         overwritten while shifting,
3632         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
3633         overwritten while shifting,
3634         * (AccLsh),
3635         * (AccRsh),
3636         * (shiftLLeftOrResult),
3637         * (shiftRLeftOrResult),
3638         * (shiftRLong),
3639         * (shiftLLong): Implemented with pic16_emitpcode
3640         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
3641         * (genLeftShift): Fixed bug, operand for shift by variable always
3642         was "and"ed with 0x0f,
3643         * (genLeftShiftLiteral),
3644         * (genrshTwo),
3645         * (genRightShiftLiteral): added debugging info,
3646         * (genrshFour): added comment,
3647         * (genRightShift): determined signedness from operand "left"
3648         instead of "result"
3649
3650 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3651
3652         * src/SDCCicode.c (geniCodeParms),
3653         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
3654         function pointers, fixed function pointer bugs #861242 and #861896
3655
3656 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3657
3658         * device/include/c8051f000.h,
3659         * device/include/c8051f120.h,
3660         * device/include/c8051f300.h: added header files for Silicon
3661         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
3662
3663 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
3664
3665         * src/SDCCast.c (processParams): added new type flow and restructured
3666         (gatherAutoInit): added new type flow
3667         (addCast): cosmetic changes
3668         (getLeftResultType): added new type flow for array indices, patch
3669         provided by Stas, see FR #877103
3670         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
3671         array index patch by Stas
3672         * src/SDCCast.h: added prototype getResultTypeFromType()
3673         * src/SDCCval.h,
3674         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
3675         * src/pic/glue.c (pic14emitStaticSeg),
3676         * src/pic16/glue.c (pic16emitStaticSeg),
3677         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
3678         for initialization of symbols
3679         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
3680         * support/Util/SDCCerr.h:
3681         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
3682         * .version: bumped version number to 2.3.8
3683         * device/include/Makefile.in (install),
3684         * doc/Makefile (install): changed to 'rm `find ...`' construct to
3685         avoid warnings
3686
3687 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
3688
3689         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
3690         Slade Rich fixed an optimization bug
3691         * src/pic/pcodepeep.c,
3692         * src/pic/pcoderegs.c
3693         * doc/Makefile (install): added test for directory
3694
3695 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3696
3697         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
3698         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
3699         * src/pic/ralloc.c (getRegPtr, getRegGpr),
3700         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
3701         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
3702         * as/mcs51/asexpr.c (term),
3703         * as/hc08/asexpr.c (term): fixed bug #887146
3704
3705 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3706
3707         * src/z80/gen.c (genMult): handle single byte result product
3708         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
3709         DUMMY_READ_VOLATILE (fixed bug #886367)
3710
3711 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
3712
3713         * support/regression/tests/libmullong.c: fixed logic, on little endian
3714         hosts we ended without a mullong_wrapper()
3715
3716 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3717
3718         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
3719         virus/worm forged address usage.
3720
3721 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
3722
3723         Fixed promotion, it should be done on AST level:
3724         * src/SDCCast.c (addCast): added promotion to int
3725         (decorateType): updated call to upCast()
3726         * src/SDCCicode.c (geniCodeLeftShift): removed call to
3727         usualUnaryConversions()
3728
3729 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
3730
3731         * support/regression/tests/literalop.c (mulWrapper): Added a
3732         wrapper to remove integer overflow warnings.
3733
3734         * support/regression/tests/float_trans.c: Made work on host.
3735
3736         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
3737         location of sz80.
3738
3739         * support/regression/generate-cases.py (main): Changed from inline
3740         to a main method.
3741
3742         * doc/Makefile (install): Changed to depth first to get rid of
3743         missing directory install warning.
3744
3745         * as/Makefile (install-doc): Made work on Mac.
3746
3747 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
3748
3749         * src/SDCCast.c: added an additional type flow in decorateType() of
3750         opposite direction, see feature request #860006; it's enabled at runtime
3751         by setting the environment variable SDCC_NEWTYPEFLOW
3752         * src/SDCCast.h: changed prototype of decorateType()
3753         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
3754         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
3755         'char' to 'int' can be omitted, if both operands are 'unsigned char';
3756         see feature request #877103
3757         * src/SDCCval.c: updated call of decorateType()
3758         (valBitwise): fixed bug #882876
3759         (valMinus): added promotion
3760         (valLogicAndOr): result is unsigned
3761         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
3762         * src/SDCCsymt.c (computeType),
3763         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
3764         must not cause an unsigned operation
3765         * src/pic/glue (pic14emitRegularMap),
3766         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
3767
3768 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
3769
3770         * src/pic/pcode.c (PCodeID): commented out left over debug code
3771
3772 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
3773
3774         * support/valdiag/tests/overflow.c: added shift tests
3775         * src/pic/device.c,
3776         * src/pic/gen.c,
3777         * src/pic/gen.h,
3778         * src/pic/glue.c,
3779         * src/pic/main.c,
3780         * src/pic/pcode.c,
3781         * src/pic/pcode.h,
3782         * src/pic/pcodepeep.c,
3783         * src/pic/pcoderegs.c,
3784         * src/pic/ralloc.c,
3785         * src/pic/ralloc.h: applied patch from Slade Rich;
3786         added support for multiple code pages and multiple RAM banks on the
3787         PIC 14 port. The ASM files now no longer simply assume all the
3788         code / RAM are in the same page / bank. This means the linker can
3789         safely allocate code/RAM of separate ASM files to different pages/banks.
3790         * doc/sdccman.lyx: added Slade's tips
3791         * src/mcs51/peeph.def: fixed bug #880768
3792
3793 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3794
3795         * src/hc08/ralloc.c (rematStr): fixed bug #879282
3796         * src/SDCCast.c (decorateType): fixed bug #880197
3797
3798 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
3799
3800         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
3801         getopt.h.
3802
3803         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
3804         strtof is not part of C89 and isn't included with Mac OS X.
3805
3806 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3807
3808         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
3809         shiftL2Left2Result): fixed bug #879326
3810         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
3811         (genMultOneByte): fixed bug in signed vs unsigned multiplication
3812         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
3813         address fetch for clr instruction
3814         * device/lib/hc08/_mulint.c: created optimized assembly version
3815         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
3816
3817 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
3818
3819         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
3820         proposed in FR #877103
3821
3822 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
3823
3824         * src/SDCCval.c (cheapestVal): added missing checks
3825         * src/SDCCicode.c (usualBinaryConversions): fixed condition
3826         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
3827
3828 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
3829
3830         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
3831         equal operands
3832
3833 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
3834
3835         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
3836         loaded with the linker search paths (-L arguments) and the libraries
3837         to be linked with the current source (-l arguments). Changes
3838         currently will affect only the pic16 port.
3839         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
3840         include path the port specific paths and port specific libraries,
3841         * gplink command now contains the $3 argument,
3842         * src/pic16/device.h,
3843         * src/pic16/device.c,: structure PIC_device is made public and
3844         renamed to PIC16_device, the same for variable Pics which is renamed
3845         to Pics16. Updated all references to them.
3846         * src/pic16/glue.c (pic16glue): corrected bug with code
3847         initialization which bypassed the variable initializations block.
3848
3849         * device/lib/pic16/Makefile.rules: removed --penable-stack from
3850         COMPILE_FLAGS and added the --nostdinc option
3851
3852 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3853
3854         * device/include/mc68hc908jb8.h: Register defs for another member
3855         of the hc08 family. Contributed by Bjorn Bringert - thanks!
3856
3857 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
3858
3859         Documenting changes from previous commits.
3860         * configure.in (version 1.56),
3861         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
3862         when generating output files to configure the pic16 library,
3863         but now I've commented it out, since gputils aren't installed in the
3864         SF compile farm, so library won't compile
3865
3866         * device/lib/Makefile.in (version 1.56): initially I've added in
3867         target 'all' the prerequestive 'model-pic16' so it compiled the
3868         pic16 library, but now I've commented it out for the same reasons
3869         above,
3870         * added targets 'model-pic16' and 'objects-pic16' to compile the
3871         library
3872         * added target 'port-specific-objects-pic16' to handle the
3873         generated libraries and copy them into the build/ directory
3874         * added target 'clean-intermediate-pic16' to clean intermediate
3875         files into pic16 directory
3876         * in target 'installdirs' added line to create directory pic16 in
3877         the installation path
3878
3879         * device/include/Makefile.in (version 1.11): in target 'install'
3880         added lines to copy all header files to installation path,
3881         * in target 'installdirs' added line create directory for pic16
3882         headers in the installation path
3883
3884 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
3885
3886         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
3887          a function call
3888
3889 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
3890
3891         * configure,
3892         * device/lib/configure.in,
3893         * device/lib/configure: fixed for autoconf 2.57
3894
3895 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3896
3897         * src/z80/main.c (_parseOptions): fixed the portmode= command line
3898         option so that it actually works. Made it specific to the z80, since
3899         the gbz80 doesn't have these kinds of I/O ports.
3900
3901 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3902
3903         * device/include/z180.h,
3904         * device/lib/_memcpy.c,
3905         * device/lib/_memmove.c,
3906         * device/lib/_mulint.c,
3907         * device/lib/ser_ir.c,
3908         * device/lib/ser_ir_cts_rts.c,
3909         * device/lib/_strcmp.c,
3910         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
3911         * src/z80/main.c (_process_pragma): add support for pragmas bank and
3912         portmode; added deprecation warning for bank= and protmode= forms.
3913         Also, guard against buffer overflow.
3914         * src/z80/gen.c (aopGet): generate better code for sfr banked read
3915
3916 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3917
3918         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
3919         changed interrupt vector table generation to only emit declared vectors.
3920         * device/include/Makefile.in: added missing backslash
3921         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
3922
3923 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
3924
3925         Mainly changes to support compilation of the device libraries
3926         * src/pic16/device.c: stack is allocated via symbol and not
3927         via literal number. The symbol is placed in the corresponding
3928         position of the data ram
3929         * (pic16_dump_section): relocatable and absolute uninitialized
3930         data are now emitted in sorted order to reduce section naming,
3931         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
3932         weren't marked as being in the access bank,
3933
3934 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
3935
3936         Added portion of GNU PIC Library under the directory
3937         device/include/pic16 and device/lib/pic16. These files
3938         contain the declarations of SFRs for the PIC18Fxx2 devices.
3939         The directory is initialized via configure from toplevel.
3940
3941 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
3942
3943         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
3944         the spilllocations to be compared correctly
3945
3946 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
3947
3948         * src/SDCCast.c (decorateType): fixed bug introduced today
3949
3950 2004-01-12  Borut Razem <borut.razem AT siol.net>
3951
3952         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
3953         doc/sdccman.lyx: upper case pragmas are deprecated
3954
3955 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
3956
3957         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
3958         in simpler and even better code
3959
3960 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
3961
3962         * src/SDCCicode.c (operandOperation): fixed bug #874819
3963         * src/SDCCast.c (decorateType): fixed
3964         char foo (unsigned long ul) { return ul > 0; }
3965
3966 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3967
3968         * doc/sdccman.lyx: Moved and added some sections, small changes
3969         all over. Telling LaTeX to be less strict with word spacing
3970         to better keep the right margin. Changed some notes about
3971         maintainance of the ports in section 3.2.1 - is it OK like this?
3972
3973 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
3974
3975         SDCC source changes:
3976         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
3977         convilong): modified to inform the pic16 port that builtin functions
3978         are external
3979
3980         PIC16 PORT specific changes:
3981         * src/pic16/device.c pic16_dump_equates() added,
3982         processor registers declared internally by the port are emitted in
3983         the translation as equates,
3984         * src/pic16/gen.c: inline code is passed unprocessed to the
3985         translation,
3986         * (pic16_popGetLit2): fnuction modified to take second operand as
3987         pCodeOp pointer and not as literal,
3988         * (popRegFromIdx): prefixed with pic16_,
3989         * (pic16_popCombine2): modified to receive already allocated pCode
3990         operands,
3991         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
3992         * (genFunction): initializes local stack frame and pushes on stack
3993         all the registers used by this function,
3994         * (genEndFunction): restores all registers from stack and restores
3995         stack frame,
3996         * src/pic16/glue.c (pic16emitRegularMap): various changes and
3997         improvements,
3998         * (pic16glue): changed the program startup sequence,
3999         * added new dbName code 'A' for functions placed in absolute section
4000         * src/pic16/main.c: added function attribute _naked,
4001         * added pragma 'code' to place a fnuction at an absolute address,
4002         * added command line arguments --debug-ralloc and --pcode-verbose,
4003         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
4004         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
4005         * (pic16_newpCodeOpLit2): modified to take the second operand as
4006         pCodeOp pointer,
4007         * (pic16_printpBlock): modified to emit each function in a separate
4008         section,
4009         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
4010         UPPER for immediate operands,
4011         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
4012         instruction,
4013         * src/pic16/peeph.def: all peepholes with movff are commented out,
4014         because there is a problem in the pcode peep optimizer,
4015         * src/pic16/ralloc.c: the register allocator can now reuse local
4016         function symbols for another function. This saves register usage.
4017         * src/pic16/ralloc.h: added flag isLocal in structure regs,
4018
4019         Added file src/pic16/NOTES with information about program writing on
4020         the current port version.
4021
4022 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4023
4024         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
4025         and peephole 252 (array access)
4026
4027 2004-01-09  Borut Razem <borut.razem AT siol.net>
4028
4029         * src/SDCCmain.c : fixed #872250: -l command line defined library
4030           files are scanned before standard library files
4031
4032 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4033
4034         * src/SDCCast.c (decorateType): fixed bug #874046
4035
4036 2004-01-09  Borut Razem <borut.razem AT siol.net>
4037
4038         * support/scripts/sdcc.nsi: remove previous installation
4039
4040 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4041
4042         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
4043         bytes for last interrupt vector (mcs51)
4044         * sdcc.spec: fixed typo
4045
4046 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4047
4048         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
4049         gen51Code): more efficient parameter receive for --model-large
4050         ("bug" #845294)
4051
4052 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4053
4054         * src/ds390/main.c,
4055         * src/z80/main.c: added missed needLinkerScript flags (more than
4056         one port structure defined in these file)
4057         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
4058         bug #795325
4059
4060 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
4061
4062         * src/SDCCmain.c: removed various references to DEFAULT_PORT
4063         * src/port.h: added flag needLinkerScript in port->linker
4064         structure to inform whether to create a .lnk file or not,
4065         * src/avr/main.c,
4066         * src/ds390/main.c,
4067         * src/hc08/main.c,
4068         * src/mcs51/main.c,
4069         * src/pic/main.c,
4070         * src/pic16/main.c,
4071         * src/xa51/main.c,
4072         * src/z80/main.c: changed appropriately to configure
4073         needLinkerScript flag
4074         * src/pic/gen.c,
4075         * src/pic16/gen.c (genAddrOf): fixed bug #863624
4076         * src/pic/glue.c: added variable udata_section_name to
4077         override default uninitialized data segment definition for
4078         devices only with SHAREBANK memory (reported from Erik Epetrich)
4079         * (pic14emitOverlay): modified to emit a commented overlay segment
4080         directive when no overlay data exist
4081         * (picglue): modified to emit uninitialized data segment
4082         according to udata_section_name
4083         * src/pic/main.c (_pic14_parseOptions): added command line
4084         options --udata-section-name=[name] to override default
4085         udata definition name
4086         * modified _linkCmd and _asmCmd to include compiler passed
4087         arguments via -W option
4088         * src/pic16/main.c: added $l in _asmCmd, changed extension for
4089         object file from '.rel' to '.o' in port->linker structure,
4090         changed size of fptr from 2 to 3 in port structure
4091
4092 2004-01-07  Borut Razem <borut.razem AT siol.net>
4093
4094         * support/scripts/sdcc.nsi: update PATH
4095         * support/scripts/sdcc.ico: craeted
4096
4097 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
4098
4099         * device/include/Makefile.in: fix install
4100         * doc/Makefile: fix install
4101
4102 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4103
4104         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
4105         in bug #860505
4106         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
4107         how the function variable allocation summary is displayed; also
4108         include information about variables allocated to the overlay
4109         segment
4110
4111 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4112
4113         * as/mcs51/lkmain.c: Help about -Y option
4114         * as/mcs51/lkarea.c: Fixed gcc warnings
4115
4116 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
4117
4118         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
4119         fixed warning
4120         * support/valdiag/tests/overflow.c: added
4121         * src/SDCCast.c (decorateType),
4122         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
4123         LEFT_OP (left shift)
4124
4125 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4126
4127         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
4128         (default behaviour).
4129
4130 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4131
4132         A python script to validate compiler diagnostic messages. It can be
4133         used to verify that sdcc complains about bad c source code and
4134         gives a good location of the error.
4135         * support/valdiag/Makefile,
4136         * support/valdiag/valdiag.py,
4137         * support/valdiag/tests/*
4138
4139 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4140
4141         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
4142         * src/SDCCsymt.c (newEnumType),
4143         * src/SDCCsymt.h
4144         * support/Util/SDCCerr.c,
4145         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
4146         enum related bugs.
4147         * support/regression/tests/enum.c: added test for enum values that
4148         require at least 2 bytes of storage.
4149
4150 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
4151
4152         * src/common.h: added ifndef/define/endif macros
4153         around the header file.
4154         Bug reported from Jesus Calvino-Fraga
4155
4156 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
4157
4158         * sdcc.spec: updated
4159         * device/include/Makefile.in: don't install CVS directories
4160         * device/lib/Makefile.in: added removal of CVS directories after install
4161         * doc/Makefile: fixed install, added local_icons
4162         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
4163         * src/mcs51/gen.c (genRightShift): fixed bug #870788
4164         * src/ds390/gen.c (genRightShift): fixed bug #870788
4165         * src/SDCCast.c (decorateType): fixed bug #870781
4166
4167 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
4168
4169         PIC16 port related changes:
4170         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
4171         added variable stackPos,
4172
4173         * gen.c: genCall, assignResultValue: added support for
4174         pushing/retrieving function parameters to/from stack,
4175         genFunction,genEndFunction: setup stack frame for the
4176         generated function,
4177         genAddrOf: will be changed according to bug 863624
4178
4179         * added files genutils.c and genutils.h which contain gen*
4180         debugged and optimised functions extracted from gen.c
4181
4182         * glue.c: added variable 'externs' which holds extern symbols,
4183         pic16emitRegularMap: is modified to properly handle relocatable
4184          symbols under the new scheme,
4185         pic16createInterruptVect: is modified
4186         pic16printPublics: is modified to emit 'global' assembler directives,
4187         added pic16_printExterns to print extern symbols,
4188         pic16glue: initializes stack/frame pointer in the beginning of
4189         the assembly output. Temporary hack, will be corrected later,
4190         because gplink yet does not support stack and SDCC does not
4191         yet support a type of crt0.o object to create the final binary.
4192
4193         * Removed many lines that contain 8051 legacy code.
4194         * The code is finally placed under a 'code' directive.
4195         * Added port specific options.
4196
4197         * _process_pragma: simplified since now we do not need *special*
4198         include file to define SFR registers. But a separate header
4199         will be needed. This will be developed later.
4200         * _pic16_parseOptions: added, parses port specific options:
4201         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
4202         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
4203         --preplace-udata-with=
4204
4205         * _pic16_setDefaultOptions: modified to initialize section names,
4206         but hack is temporarly out of order since it needs improvement.
4207         * _pic16_genAssemblerPreamble: configuration words are emitted by
4208         their address instead of their name. This part is incomplete and
4209         supports only the 18Fxx2 devices. Other devices will emit an error
4210         during assembly since they do not contain the same set of config
4211         registers
4212         * _pic16_genIVT: is modified,
4213
4214         * pcode.c: added definitions for some hardware registers that are needed
4215         for stack support
4216         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
4217         All PCI entries are updated. Now LFSR is supported.
4218         * Removed pic16_pciTRIS is mentioned by mdubuc in source
4219         * added pic16_newpCodeOpLit2 to support instructions with
4220         two literal arguments
4221         * pic16_pCode2str: corrected code that emits assembler instructions
4222         with two literal operands and those that have an access bit modifier
4223         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
4224         this fixes a bug which caused some labels to be lost, when an
4225         assembler directive was added, i.e. banksel,
4226         * pic16_FixRegisterBanking: improved logic that causes the insertion
4227         of bank switching,
4228         * InlineFunction: functions that are called once, are not any more
4229         inlined. This can be a port option in the future,
4230
4231         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
4232
4233         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
4234         hold the corresponding uninitialized symbols,
4235         * pic16_allocProcessorRegister: registers have explicit marked the
4236         accessBank field,
4237         * pic16_allocInternalRegister: registers are explicit marked as
4238         not used,
4239         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
4240         processing list, so bit registers were lost,
4241         *
4242
4243         * ralloc.h: added field 'accessBank' and original symbol operand
4244         in register definition,
4245         * removed the field isMapped from register definition,
4246
4247         ** Several functions have been removed from various sources:
4248         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
4249         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
4250         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
4251         pic16_assignRelocatableRegisters
4252
4253         ** others have been introduced:
4254         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
4255         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
4256
4257 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
4258
4259         * support/scripts/inc2h.pl: changed definition of BIT_AT
4260         to emit 'sbit at' instead of 'bit at'. This was a request.
4261
4262         PIC16 port related preliminary changes:
4263         * gen.c: prefixed function popRegFromString with
4264         pic16_ and all references to it corrected
4265         * pcode.c: all pic16_pc_* hardware registers prefixed
4266         with underscore (_),
4267         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
4268         * ralloc.c: newReg(): when register is REG_SFR then
4269         set address to rIdx,
4270         pic16_allocProcessorRegister(): marks register wasUsed=0
4271         pic16_writeUsedRegs(): added a call to assign processor
4272         registers via pic16_assignFixedRegisters
4273
4274 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4275
4276         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
4277         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
4278         variables in unused register banks.  Also the SSEG is placed
4279         wherever there is enough space for it, and IDATA can be anywhere
4280         in internal RAM.  For now compile using -Wl-Y[stack_size].
4281         The mem file is different for this option as well, since it
4282         makes no sense of talking about DSEG lenght.
4283
4284 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
4285
4286         * src/SDCClrange.c: fixed bug 869095 that caused segfault
4287         in certain cases, e.g. when ROM assignment, patch provided
4288         from Albert den Haan.
4289
4290 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
4291
4292         Many signedness and type propagation fixes:
4293         * src/SDCCicode.c: made geniCodeCast() static
4294         replaced SPEC_ by IS_ (cosmetic)
4295         (operandOperation): fixed div and mod operation
4296         (usualBinaryConversions): added support for promotion of char
4297         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
4298         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
4299         (geniCodeAdd): an array index will stay unsigned, even if promoted
4300         from char to int
4301         (geniCodeArray): ditto
4302         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
4303         * src/SDCCsymt.c (computeType): added more support for char;
4304         promotion of char is selectable by promoteCharToInt, fixed signedness
4305         for all cases
4306         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
4307         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
4308         * src/SDCCval (val*): replaced signedness calculation by
4309         computeType()
4310         rearranged if-branches (cosmetic)
4311         (valShift): added warning W_SHIFT_CHANGED
4312         (valCompare): fixed problem with different types
4313         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
4314         * support/regression/tests/literalop.c: added many cases
4315         * support/regression/tests/ast_constant_folding.c: changed finally to
4316         'unsigned int'
4317         * .version: new year, new version: 2.3.7
4318         * src/SDCCmain.c (main): applied patch #866468
4319         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
4320         provided by Scott Bronson
4321         * doc/sdccman.lyx: updated documentation for sdcdb
4322         updated and added chapter tips
4323
4324 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4325
4326         * src/SDCCsymt.h: missing from yesterday's commits
4327
4328 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4329
4330         * src/SDCC.y (struct_or_union_specifier),
4331         * support/Util/SDCCerr.c,
4332         * support/Util/SDCCerr.h: verify that struct & union tags are used
4333         as declared.
4334
4335 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4336
4337         * src/SDCCglobl.h: missing from yesterday's commits
4338
4339 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4340
4341         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
4342         sft_attributes, struct_declaration, parameter_declaration,
4343         type_name, start_block, declaration_list),
4344         * src/SDCC.lex (check_type): support redefinition of typedef names
4345
4346 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4347
4348         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
4349         aligned xdata arrays. Erik helped me with the if clause.
4350
4351 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4352
4353         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
4354         warning
4355
4356 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4357
4358         * src/SDCCast.h,
4359         * src/SDCCast.c (newAst_),
4360         * src/SDCCicode.h,
4361         * src/SDCCicode.c (ast2iCode, newiCode),
4362         * src/SDCCglobl.h,
4363         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
4364         expr, statement, expression_statement, selection_statement,
4365         iteration_statement, expr_opt, jump_statement): foundation for tracking
4366         sequence points
4367         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
4368         point code too)
4369
4370 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4371
4372         * support/Util/SDCCerr.c,
4373         * src/SDCCast.h,
4374         * src/SDCCast.c (createCase, createDefault, decorateType),
4375         * src/SDCClabel.c (labelUnreach),
4376         * src/SDCC.y (labeled_statement, jump_statement): More improvements
4377         to error messages.
4378         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
4379         (with thanks to Stas Sergeev)
4380         * device/include/time.h,
4381         * device/lib/time.c (CheckTime): suppress unreachable code warning
4382
4383 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4384
4385         * src/SDCCast.c (createIvalCharPtr),
4386         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
4387         bug #753752)
4388         * support/regression/tests/nullstring.c: tests for these two bugs
4389
4390 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4391
4392         * support/Util/SDCCerr.h,
4393         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
4394         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
4395         about storage class and 'at' used inside struct or union
4396         * src/SDCCBBlock.c (iCodeFromeBBlock),
4397         * src/SDCCcse.c (ifxOptimize),
4398         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
4399         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
4400         printIval, emitStaticSeg, emitOverlay),
4401         * src/SDCClabel.c (deleteIfx),
4402         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
4403         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
4404         gatherAutoInit, processParms),
4405         * support/Util/SDCCerr.h,
4406         * support/Util/SDCCerr.c (werrorfl): Support for better error location
4407         reporting for post-parse errors.
4408
4409 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4410
4411         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
4412         implicit casts via union; they don't work on big endian systems
4413         (possible fix for bug #861138)
4414
4415 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4416
4417         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
4418         * src/mcs51/main.c: fixed the fix for bug #737001
4419
4420 2003-12-15  Borut Razem <borut.razem AT siol.net>
4421
4422         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
4423
4424 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4425
4426         * support/makebin/makebin.c: put output in binary mode
4427
4428 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4429
4430         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
4431         xdata and data memory on startup. Set the environment variable
4432         SDCC_NOGENRAMCLEAR to disable this.
4433         * src/mcs51/peephole.def,
4434         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
4435         (allows non-interrupt and interrupt code to safely compete for a resource
4436         without the non-interrupt code having to disable interrupts)
4437
4438 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4439
4440         * src/SDCCicode.c (geniCodeAdd),
4441         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
4442         with valFromType if type might be a pointer and host is big endian).
4443         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
4444         types, not just integer types.
4445         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
4446         multiply defined with mismatching "at" address.
4447
4448 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4449
4450         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
4451         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
4452         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
4453         with embedded nulls (fixed bug #753752)
4454
4455 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4456
4457         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
4458         Apparently this did not see much testing (endless loop)
4459
4460 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4461
4462         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
4463
4464 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4465
4466         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
4467         gracefully handle NULL memmap pointers
4468
4469 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4470
4471         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
4472         instead of deleting the iCode when an operand is volatile
4473         * src/z80/gen.c (genDummyRead),
4474         * src/mcs51/gen.c (genDummyRead),
4475         * src/ds390/gen.c (genDummyRead),
4476         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
4477         not just IC_RIGHT
4478         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
4479         * src/SDCC.y: fixed bug #850420
4480
4481 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4482
4483         Applied z80 i/o port patch from Peter Townson and fixed some operators
4484         to better handle operands in A register.
4485         * device/include/z180.h
4486         * src/SDCC.y
4487         * src/SDCCglue.c
4488         * src/z80/gen.c
4489         * src/z80/gen.h
4490         * src/z80/main.c
4491         * src/z80/peeph-z80.def
4492         * src/z80/peeph.def
4493         * src/z80/z80.h
4494
4495 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4496
4497         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
4498
4499 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4500
4501         * device/lib/hc08/_mullong.c: Removed extra #endif
4502
4503 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4504
4505         * sim/ucsim/hc08.src/inst.cc,
4506         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
4507         carries from x to h
4508         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
4509         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
4510         * device/include/stdarg.h: fixed varargs for hc08
4511         * device/lib/Makefile.in,
4512         * device/lib/hc08/Makefile,
4513         * device/lib/hc08/_mulint.c,
4514         * device/lib/hc08/_mullong.c: fixed some endian problems
4515
4516 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4517
4518         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
4519         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
4520         * device/lib/_gptrget.c,
4521         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
4522
4523 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4524
4525         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
4526         * src/SDCCast.c (astErrors): fixed bug #846007
4527         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
4528
4529 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4530
4531         * src/SDCCast.c (decorateType): disabled a transformation I added in
4532         revision 1.188 (access to fields of a structure at an absolute address);
4533         it breaks with bitfields, extern declarations, and gcse analysis.
4534         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
4535         could be assigned through a pointer, so don't complain.
4536         * src/SDCCast.c (astErrors),
4537         * src/SDCCast.h,
4538         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
4539
4540 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
4541
4542         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
4543         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
4544         output of __config directives, since gpasm now supports them
4545         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
4546         pre-processor macro, i.e. -DMCU=p18f452
4547         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
4548         and modified to handle 'cast' icode similarly to '=' icode
4549         * src/pic16/device.h (typedef struct PIC_device): added field
4550         'extMIface' to indicate that chip has external memory interface
4551         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
4552         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
4553         18F8720
4554
4555 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4556
4557         * src/SDCC.y (pointer): fixed bug #846006
4558         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
4559         * src/SDCCast.c (decorateType): fixed bug #846009
4560         * src/ds390/peeph.def,
4561         * src/ds390/gen.c (genAnd, genOr),
4562         * src/mcs51/peeph.def,
4563         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
4564
4565 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4566
4567         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
4568         * src/SDCCdflow.c
4569         * src/SDCCcse.c
4570         * src/SDCCcse.h
4571         * src/SDCCBBlock.h
4572         * src/SDCCBBlock.c
4573
4574 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
4575
4576         fixed bug #845089
4577         * src/SDCCbitv.h,
4578         * src/SDCCbitv.c: added function to free a bitvector
4579         * src/SDCClrange.h,
4580         * src/SDCClrange.c: added function to recompute the liveranges
4581         * src/avr/ralloc.c,
4582         * src/ds390/ralloc.c,
4583         * src/hc08/ralloc.c,
4584         * src/mcs51/ralloc.c,
4585         * src/pic/ralloc.c,
4586         * src/pic16/ralloc.c,
4587         * src/xa51/ralloc.c,
4588         * src/z80/ralloc.c: recompute the liveranges after register packing
4589
4590 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
4591
4592         * src/SDCCloop.c (newInduction): fixed bug #845630
4593
4594 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4595
4596         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
4597         inadvertantly left behind from my 2003-11-12 change
4598
4599 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4600
4601         Updated headers I neglected to commit yesterday.
4602         * src/SDCClrange.h,
4603         * src/SDCCicode.h
4604
4605 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4606
4607         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
4608         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
4609         * src/SDCCopt.c (eBBlockFromiCode),
4610         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
4611         the creation of the key hash table from the sequencing so it can be used
4612         earlier (for some GCSE bug fixes still pending)
4613
4614 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4615
4616         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
4617         * support/regression/tests/addsub.c: testing genPlus shortcut
4618
4619 2003-11-15  Borut Razem <borut.razem AT siol.net>
4620
4621         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
4622
4623 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4624
4625         * src/SDCCcse.c (cseBBlock): fixed bug #527779
4626         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
4627         ordering is immaterial.
4628         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
4629
4630 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4631
4632         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
4633         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
4634         (SIGSEV) of bug #840381
4635         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
4636         unlink new file before rename if new and old filenames are the same)
4637
4638 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4639
4640         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
4641         uninitialized variables) for the mcs51. Set environment variable
4642         SDCC_GENRAMCLEAR to test.
4643         xdata initialization slightly shorter
4644
4645 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4646
4647         * src/SDCCsymt.h,
4648         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
4649         #838241 & 780691 (basicly the same bug)
4650         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
4651         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
4652
4653 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
4654
4655         * src/SDCCmain.c (linkEdit): "fix" #834252
4656
4657 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4658
4659         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
4660         * src/SDCCast.h,
4661         * src/SDCC.y: fixed bug #819403
4662
4663 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4664
4665         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
4666         the reentrant attribute.
4667         * src/hc08/gen.c (genPackBits): added missing stack readjustment
4668         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
4669         simulation
4670         * src/SDCCast.c (decorateType): fixed bug with storage class not being
4671         updated during pointer dereference; f.e. ~(((char *)1)*) was being
4672         erroneously reduced to a literal.
4673         * src/hc08/ralloc.c (packRegisters, rematStr),
4674         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
4675         some cases
4676
4677 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4678
4679         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
4680         * doc/sdccman.lyx: changed from 'article' to 'book'
4681         * doc/Makefile: readded test_suite_spec and cdbfileformat
4682
4683 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
4684
4685         * device/include/stdlib.h: include malloc.h to comply with ANSI
4686         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
4687
4688 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4689
4690         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
4691         * doc/clean.mk: also remove *.out files
4692         * doc/sdccman.lyx: some additions, larger top/bottom margins
4693
4694 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4695
4696         * src/SDCC.y: fixed bug #837365
4697         * support/regression/tests/bitopcse.c
4698         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
4699         a symbol (might be valop instead)
4700         * device/lib/Makefile.in: added errno.c to HC08SOURCES
4701         * device/lib/clean.mk: added hc08 to the cleaning list
4702
4703 2003-11-04  Borut Razem <borut.razem AT siol.net>
4704
4705         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
4706           made 2003-11-04
4707         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
4708           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
4709           malloc is declared in standard stdlib.h
4710
4711 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4712
4713         * device/lib/hc08/Makefile: need to clean .rel not .o files
4714         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
4715
4716 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4717
4718         * src/port.h,
4719         * src/hc08/main.c,
4720         * src/mcs51/main.c,
4721         * src/ds390/main.c,
4722         * src/z80/main.c,
4723         * src/avr/main.c,
4724         * src/pic/main.c,
4725         * src/pic16/main.c,
4726         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
4727         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
4728         tests (which uses the port's oclsExpense function)
4729         * src/SDCC.y,
4730         * src/SDCCast.c,
4731         * src/SDCCicode.c,
4732         * src/hc08/gen.c,
4733         * src/ds390/gen.c,
4734         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
4735
4736 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4737
4738         * src/SDCCcse.c (ifxOptimize),
4739         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
4740         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
4741         deleting the IFX iCode.
4742         * src/hc08/ralloc.c: reduced unneeded slocs
4743         * src/hc08/gen.c: fixed bug in asmopToBoolean
4744
4745 2003-11-04  Borut Razem <borut.razem AT siol.net>
4746
4747         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
4748           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
4749           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
4750           transferred to configure
4751
4752 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
4753
4754         Use headers defined in the C[++] standards:
4755         * sim/ucsim/gui.src/serio.src/fileio.cc
4756         * sim/ucsim/gui.src/serio.src/frontend.cc
4757         * sim/ucsim/gui.src/serio.src/main.cc
4758         * sim/ucsim/gui.src/serio.src/posix_signal.cc
4759         * support/Util/NewAlloc.c
4760         * as/hc08/lklibr.c
4761         * as/mcs51/lklibr.c
4762         * as/z80/aslist.c
4763         * as/z80/assym.c
4764
4765 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4766
4767         * Added MSVC projects for hc08 assembler and linker:
4768         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
4769         /as/hc08/link_hc08.dsp
4770
4771 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
4772
4773         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
4774
4775 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
4776
4777         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
4778
4779 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4780
4781         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
4782
4783 2003-10-31  Borut Razem <borut.razem AT siol.net>
4784
4785         * support/cpp2/cpplib.h,
4786           support/cpp2/cpplib.c,
4787           support/cpp2/cpplex.c,
4788           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
4789           to switch _asm block preprocessing on / off. Default is
4790           #pragma preproc_asm +
4791
4792 2003-10-31  Borut Razem <borut.razem AT siol.net>
4793
4794         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
4795           when outputting comment blocks (when executed with -C option) and
4796           _asm (SDCPP specific) blocks
4797
4798 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4799
4800         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
4801
4802 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
4803
4804         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
4805
4806 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
4807
4808         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
4809         * src/SDCCast.c (decorateType): fixed bug #832664
4810
4811 2003-10-31  Borut Razem <borut.razem AT siol.net>
4812
4813         * support\cpp2\cpplex.c: fixed for SDCPP:
4814           comments(when executed with -C option) and _asm blocks
4815           were included even if they where in skipped #if block.
4816           Applied solution from GCC cpp 3.3.2
4817
4818 2003-10-31  Borut Razem <borut.razem AT siol.net>
4819
4820         * src/SDCC.lex: sdcc now understands both formats:
4821           '# <line_number> <file_name>' and
4822           '#line <line_number> <file_name>'
4823         * support/cpp2/cppmain.c: sdcpp now generates the standard
4824           '# <line_number> <file_name>' instead of former
4825           '#line <line_number> <file_name>'
4826
4827 2003-10-30  Borut Razem <borut.razem AT siol.net>
4828
4829         * support/cpp2/cpphash.h,
4830         * support/cpp2/cpplib.h
4831         * support/cpp2/cpplex.c,
4832         * support/cpp2/cppmain.c,
4833         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
4834
4835 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4836
4837         Fixed a number of problems revealed by bug #827883.
4838         * src/SDCCloop.c (loopInvariants): Spill location of the
4839         result operand should be recomputed if extracted from
4840         a loop. Also, don't extract assignments of an iTemp
4841         from a literal.
4842         * src/SDCCast.c (isConformingBody): loop reversal should
4843         not occur if the control variable is involved with a
4844         relational operator.
4845
4846 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
4847
4848         * .version: bumped to 2.3.6 to reflect the big improvements
4849         made by Erik and Klaus. Thanks!
4850
4851 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
4852
4853         Replaced the livrange code.
4854         * src/SDCClrange.c: added new LR code
4855         * src/SDCCloop.c,
4856         * src/SDCCBBlock.h: removed remainig parts from old LR code
4857         * src/ds390/ralloc.c,
4858         * src/ds390/gen.c: minor fixes to make it work with new code
4859
4860 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4861
4862         * as/hc08/asm.h,
4863         * as/hc08/lkrloc.c,
4864         * src/hc08/gen.c,
4865         * src/hc08/ralloc.c: Fix various warnings related to the hc08
4866         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
4867         (tweaked fix for bug #818696)
4868
4869 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4870
4871         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
4872
4873 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4874
4875         * src/SDCCmain.c,
4876         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
4877         * src/mcs51/gen.c (gencjneshort),
4878         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
4879         more efficient (per Scott Bronson's suggestion)
4880
4881 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4882
4883         Extended the semantics of the critical keyword to include
4884         individual statements. See RFE #827755 and #799831
4885         * src/SDCC.y
4886         * src/SDCCicode.c
4887         * src/SDCCopt.c
4888         * src/SDCCast.c
4889         * support/Util/SDCCerr.c
4890         * support/Util/SDCCerr.h
4891         * src/mcs51/gen.c
4892         * src/ds390/gen.c
4893         * src/hc08/gen.c
4894
4895 2003-10-19  Borut Razem <borut.razem AT siol.net>
4896
4897         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
4898
4899 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4900
4901         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
4902         Fixed bug #818696
4903         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
4904         and predecrement operand is displayed
4905
4906 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
4907
4908         * src/SDCCval.c (valMinus): fixed bug #826041
4909
4910 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4911
4912         Some hc08 related updates that I missed earlier
4913         * sim/ucsim/stypes.h
4914         * support/regression/ports/hc08/spec.mk
4915
4916 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4917
4918         New target "hc08" for the Motorola 68hc08 family of micros
4919
4920         * configure
4921         * configure.in
4922         * Makefile
4923         * src/hc08/*
4924         * src/SDCCmain.c
4925         * src/port.h
4926         * sim/ucsim/hc08.src/*
4927         * sim/ucsim/configure.in
4928         * src/ucsim/configure
4929         * sim/ucsim/packages_in.mk
4930         * as/hc08/*
4931         * as/Makefile
4932         * device/include/mc68hc908qy.h
4933         * device/lib/hc08/*
4934         * device/lib/Makefile.in
4935         * support/regression/ports/hc08/*
4936         * support/regression/Makefile
4937
4938 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4939
4940         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
4941         regression test
4942         * src/ds390/gen.c (genCast): fixed bug #821957
4943
4944 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
4945
4946         * device/lib/logf.c: "fixed" overlay bug
4947         * support/regression/ports/host/spec.mk: added m library
4948         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
4949         * support/regression/tests/float_trans: added (for Eric)
4950
4951 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
4952
4953         * src/mcs51/gen.c (genCpl): fixed bug
4954         http://sf.net/mailarchive/message.php?msg_id=6263915
4955
4956 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
4957
4958         * src/SDCCast.c (decorateType): added extended constant folding
4959         * src/SDCCsymt.c (computeType): cleanup
4960         * src/SDCCval.c (valShift): minor optimization
4961         * support/regression/tests/ast_constant_folding.c: added
4962
4963 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4964
4965         * src/SDCCmain.c: removed some unintended changes
4966
4967 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4968
4969         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
4970         * src/z80/gen.c: fixed part of bug #817589
4971         * src/SDCCsymt.c (checkFunction): fixed bug #817895
4972
4973 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
4974
4975         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
4976         * src/SDCCcflow.c
4977         * src/SDCCcse.c
4978         * src/SDCCdflow.c
4979         * src/SDCClabel.c
4980         * src/SDCClrange.c
4981         * src/SDCCmem.c
4982         * src/SDCCopt.c
4983         * src/SDCCpeeph.c
4984         * src/SDCCset.c
4985         * src/avr/ralloc.c
4986         * src/ds390/ralloc.c
4987         * src/izt/ralloc.c
4988         * src/mcs51/ralloc.c
4989         * src/pic/ralloc.c
4990         * src/pic16/ralloc.c
4991         * src/xa51/ralloc.c
4992         * src/z80/ralloc.c
4993         * src/z80/gen.c: removed unused label "release:"
4994
4995 2003-10-06  Borut Razem <borut.razem AT siol.net>
4996
4997         * src/SDCC.lex: removed definition of unused variables
4998           save_optimize and save_options
4999
5000 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
5001
5002         * clean.mk: removed '=' in "-maxdepth=1"
5003         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
5004         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
5005
5006 2003-10-06  Borut Razem <borut.razem AT siol.net>
5007
5008         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
5009           my_unput() replaced by unput()
5010
5011 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
5012
5013         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
5014         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
5015         type-punned pointer will break strict-aliasing rules"
5016         Old LR behaviour is again default; Klaus' LR can be choosen by
5017         defining the environment variable LRKLAUS
5018         * src/SDCCBBlock.h
5019         * src/SDCCloop.c
5020         * src/SDCClrange.c
5021         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
5022         * clean.mk: fixed removal of files in bin/CVS/
5023         * device/lib/clean.mk: fixed removal of directories small and large
5024         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
5025         * src/SDCCicode.c,
5026         * src/SDCCval.c: removed superflous test for pedantic
5027
5028 2003-10-05  Borut Razem <borut.razem AT siol.net>
5029
5030         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
5031           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
5032           message "unmatched #pragma SAVE and #pragma RESTORE"
5033
5034 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5035
5036         * doc/sdccman.lyx: various additions and updates (interrupts, inline
5037           assembly, critical functions, atomic, nojtbound)
5038
5039 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
5040
5041         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
5042         * src/SDCCBBlock.h
5043         * src/SDCCloop.c
5044         * src/SDCCloop.h
5045         * src/SDCClrange.c
5046
5047 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5048
5049         * src/z80/gen.h,
5050         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
5051         * src/mcs51/gen.h
5052         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
5053         * src/ds390/gen.h
5054         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
5055         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
5056         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
5057
5058 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5059
5060         * src/z80/gen.c (genRet): fixed bug #524753
5061         * src/z80/gen.c (genCast): fixed internal error on cast from
5062         pointer to long
5063         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
5064         fix for bug #477835 to the z80
5065         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
5066         for tracking iCodes in the peephole optimizer for z80
5067
5068 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5069
5070         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
5071         the other part of bug #814548
5072         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
5073
5074 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
5075
5076         * src/SDCCcse.c: fixed part of bug #814548
5077
5078 2003-09-28  Borut Razem <borut.razem AT siol.net>
5079
5080         * src/asm.c: rewrite of printILine() to use temporary file instead
5081           a pipe
5082         * src/xa51/main.c: commented out declaration of int rewinds
5083
5084 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5085
5086         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
5087
5088 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5089
5090         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
5091         * src/asm.c (printILine): Fixed bug #811015
5092
5093 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5094
5095         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
5096         freeing.
5097
5098 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5099
5100         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
5101         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
5102         to correctly handle general case of AOP_PAIRPTR
5103         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
5104
5105 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5106
5107         * src/mcs51/ralloc.c (fillGaps),
5108         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
5109         register positioning bug)
5110
5111 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
5112
5113         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
5114
5115 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5116
5117         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
5118         genCodePointerGet, genGenPointerGet, genFarPointerSet,
5119         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
5120         (ralloc doesn't intentionally do this now, but perhaps later)
5121         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
5122         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
5123         register positioning bugs (Fixed bug #762602 and #795325)
5124         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
5125         (Fixed bug #808779)
5126         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
5127         lines that --i-code-in-asm generates
5128
5129 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5130
5131         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
5132         trying to fclose a FILE* that was already closed.
5133
5134 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5135
5136         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
5137         of const struct should be treated as if const themselves)
5138
5139 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
5140
5141         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
5142
5143 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5144
5145         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
5146         Unix (/n) and DOS (/r/n) line terminations.
5147
5148 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5149
5150         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
5151         bug #613775
5152
5153 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5154
5155         * src/mcs51/gen.c (genFunction, genEndFunction),
5156         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
5157         and restore of EA so that stack offsets to parameters are
5158         correct when using both critical and reentrant/stack-auto.
5159         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
5160         size (can be triggered in error if sloc is shared between
5161         different sized objects)
5162         * device/include/float.h: fixed macros to explicitly use
5163         unsigned long where needed
5164
5165 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
5166
5167         Feature req. 799831: added code to allow nesting of critical functions
5168         * src/mcs51/gen.c (genFunction, genEndFunction)
5169         * src/ds390/gen.c (genFunction, genEndFunction)
5170
5171 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5172
5173         * src/SDCCsymt.c (sclsFromPtr),
5174         * src/SDCCsymt.h,
5175         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
5176         support for standard C idiom of memory mapped variables; for
5177         example, *((xdata int*)0x1234) = 1 is now internally equivalent
5178         to xdata int at 0x1234 tempvar = 1.
5179         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
5180         provided by Akiya ISHIDA
5181
5182 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
5183
5184         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
5185         * src/SDCCval.c (constVal): added reduction from int to char
5186         * src/SDCCval.c (valMult, valDiv): fixed sign handling
5187         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
5188         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
5189         to ignore the sign
5190         * support/regression/tests/shifts.c: fixed
5191
5192 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5193
5194         * src/z80/gen.c (genXor): Fixed bug #805445
5195
5196 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5197
5198         Fixed bug #621531 (const & volatile confusion in the type chain).
5199         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
5200         refer to the const or volatile state of the pointer itself.
5201
5202         * src/SDCCast.c
5203         * src/SDCCglue.c
5204         * src/SDCCicode.c
5205         * src/SDCCsymt.c
5206         * src/SDCCval.c
5207         * src/SDCC.y
5208         * src/SDCCsymt.h
5209         * src/pic/gen.c
5210         * src/pic/ralloc.c
5211         * src/pic16/gen.c
5212         * src/pic16/ralloc.c
5213         * support/regression/tests/const.c
5214
5215 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5216
5217         When checking for duplicated modules, use absolute paths
5218         instead of relative paths.  Files changed:
5219
5220         * as/mcs51/lklib.c
5221         * link/z80/lklib.c
5222
5223 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5224
5225         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
5226
5227 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5228
5229         * device/include/string.h: added size_t typedef, changed
5230         prototypes to use size_t, eliminated separate reentrant and
5231         non-reentrant declarations, added _memmove declaration
5232         * device/lib/_memcpy.c: changed to use size_t instead of int,
5233         changed /4 to >>2 to avoid division library call
5234         * device/lib/_memcmp.c,
5235         * device/lib/_memset.c,
5236         * device/lib/_strncat.c,
5237         * device/lib/_strncpy.c,
5238         * device/lib/_strncmp.c: changed to use size_t instead of int
5239         * device/lib/_memmove.c: new file (fixed bug #772294)
5240         * device/lib/Makefile.in: added _memmove.c
5241         * device/lib/z80/asm_strings.s: fixed bug #772290
5242         * support/regression/tests/bitfields.c: attempt to fix host assertion
5243         failure on amd64-unknown-linux2.2
5244
5245 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5246
5247         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
5248         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
5249         * as/z80/asmain.c (main): fixed bug #801766
5250
5251 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
5252
5253         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
5254         compilers
5255
5256 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5257
5258         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
5259         reported in bug #800609
5260
5261 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
5262
5263         * Top header beautifications in src/pic16 directory:
5264           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
5265           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
5266           pcoderegs.h, ralloc.c, ralloc.h
5267         * main.c: added top header and GPL license notice
5268         * pcode.c: fixed the if-conditional warning
5269
5270 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
5271
5272         * device/lib/_mullong.c: replaced int by short for gcc
5273
5274 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5275
5276         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
5277         and JUMPTABLE iCodes properly now (worked by accident before)
5278         * src/mcs51/gen.c (leftRightUseAcc),
5279         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
5280         iCode properly now. Use getSize instead of nRegs since a & b
5281         aren't part of the nRegs tally.
5282
5283 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
5284
5285         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
5286         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
5287           before instructions that use the _STATUS register
5288
5289 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
5290
5291         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
5292         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
5293         fetching of the pointer
5294         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
5295         copied from genNearPointerSet()
5296         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
5297         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
5298         If they pop r0/r1 they must be called in the opposite order than aopOp().
5299         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
5300         (resp. --stack-auto), prepared for --xstack
5301
5302 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5303
5304         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
5305
5306 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
5307
5308         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
5309         these ports have their own __sdcc_external_start()
5310
5311 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
5312
5313         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
5314         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
5315         type for bits was changed. It resulted in bit variables becoming
5316         global, which is not permitted in PIC 14 assembly output.
5317
5318 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5319
5320         * doc/sdccman.lyx: various additions and updates. Rearranged sections
5321
5322 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5323
5324         Z80 and MCS51 linkers complaint if a public symbol is defined
5325         in more than one library module:
5326
5327         * as/mcs51/lklib.c
5328         * link/z80/lklib.c
5329         * as/mcs51/Makefile.in
5330
5331 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5332
5333         A few small changes that speed up the peephole optimizer.
5334
5335         * src/SDCCpeeph.c
5336
5337 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5338
5339         Try to make the peephole optimizer smarter by maintaining
5340         an association between the assembly source code and the
5341         iCodes that originated them. Put this information to use
5342         with a new peephole rule condition "notVolatile" so that
5343         the rules can be aggressive yet still safe.
5344
5345         * src/SDCCpeeph.c
5346         * src/SDCCpeeph.h
5347         * src/mcs51/gen.c
5348         * src/mcs51/peeph.def
5349
5350 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5351
5352         Fixed bug #741761
5353
5354         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
5355         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
5356         if the left or right operand symbols have the accuse flag set.
5357
5358 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5359
5360         Changed the type of the result of the ! (NOT) operator to char;
5361         previously it returned the same type as the source. This allows
5362         us to eliminate all the genFloatNot functions (all of its target
5363         implementations were very buggy) since !float can use the same
5364         code as !long now.
5365
5366         * src/SDCCicode.c (ast2iCode): ! returns char
5367         * src/mcs51/gen.c (genNot, genNotFloat),
5368         * src/ds390/gen.c (genNot, genNotFloat),
5369         * src/z80/gen.c (genNot, genNotFloat),
5370         * src/pic/gen.c (genNot, genNotFloat),
5371         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
5372
5373 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
5374
5375         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
5376         1. Interrupt would not compile properly. Ensure PCLATH register is saved
5377            during interrupts. Ensure WSAVE is located at a shared bank address.
5378         2. Fixed page selection in some places
5379         3. Fixed BTFSS/C to where necessary use registers directly and not simply
5380            the registers name strings.
5381         4. Fixed "signed / unsigned compare" compiler warnings.
5382         5. The PIC port manages its own allocation of the general purpose
5383            registers, but makes no attempt to reuse them. As a result when
5384            compiling it soon runs out of general purpose registers. Some
5385            additional code was added to the files pcode.c and device.c to walk
5386            through the function call tree and rename the registers so that they
5387            get reused.
5388
5389         * src/pic/device.c
5390         * src/pic/gen.c
5391         * src/pic/glue.c
5392         * src/pic/pcode.c
5393         * src/pic/pcode.h
5394         * src/pic/ralloc.c
5395         * src/pic/ralloc.h
5396         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
5397         genPlus() & genMinus() when the result is the same as left or right
5398
5399 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5400
5401         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
5402
5403 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5404
5405         Made bitfield a distinct type from bit so that bitfields
5406         convert as per ANSI C and bits retain their traditional
5407         boolean style behaviour. Implemented bitfield support in
5408         the z80 port.
5409
5410         * src/SDCCsymt.h,
5411         * src/SDCCsymt.c,
5412         * src/SDCCast.c,
5413         * src/cdbFile.c,
5414         * src/mcs51/gen.c,
5415         * src/ds390/gen.c: bit v bitfield split
5416         * src/z80/gen.c: New support for bitfields
5417         * support/regression/tests/bitfields.c: reenabled z80,
5418         added more tests
5419
5420 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5421
5422         Rules 246.x, 247.x relate to bitfields, the others speed up
5423         access to xdata mapped I/O devices.
5424
5425         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
5426
5427 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5428
5429         Cleaned up genPackBits and genUnpackBits and added two helper
5430         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
5431         for literal assignments in genPackBits (thanks to Frieder for
5432         reminding me).
5433
5434         * src/mcs51/gen.c
5435         * src/ds390/gen.c
5436
5437 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5438
5439         Fixed bug #748310 (pointer to function type mishandled when the
5440         function name is omitted). Also fixed a SIGSEGV when a function
5441         attribute (reentrant, etc) is used on a non-function or on a
5442         function but misplaced before the parameter list.
5443
5444         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
5445         bug #748310
5446         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
5447         * support/Util/SDCCerr.h,
5448         * support/Util/SDCCerr.c: Added func attr misuse error msg
5449
5450 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
5451
5452         Fixed bug #787649 by anonymous
5453         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
5454         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
5455
5456 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5457
5458         Fixed numerous bitfield problems.
5459
5460         * src/SDCC.y: More bitfield related error checking
5461         * src/SDCCsymt.h,
5462         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
5463         * support/Util/SDCCerr.h,
5464         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
5465         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
5466         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
5467         * support/regression/tests/bitfields.c: tests added
5468
5469 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5470
5471         Made the constant following the "interrupt" keyword optional. If
5472         omitted, the function will not automatically be given an entry
5473         in the interrupt vector table (similar to #pragma NOIV, but
5474         less syntacticly kludgy). The interrupt number is also now
5475         range checked. Also fixed a bug in the high order bit example
5476         in the manual.
5477
5478         * src/SDCC.y
5479         * src/SDCCmem.c
5480         * src/SDCCglue.c
5481         * src/SDCCsymt.h
5482         * support/Util/SDCCerr.c
5483         * support/Util/SDCCerr.h
5484         * doc/sdccman.lyx
5485
5486 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
5487
5488         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
5489         * src/SDCCicode.c (operandOperation): rewritten some ops
5490         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
5491         * src/SDCCsymt.c (computeType): literals are handled the same way as any
5492         other type
5493         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
5494         be re-activated by defining REDUCE_LITERALS)
5495         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
5496         unsigned, but are signed by default
5497         * src/SDCCval.c (constVal): rearranged
5498         * src/SDCCval.c (valMod): preliminary fix
5499         * src/SDCCval.c (valCastLiteral): use TYPE_* types
5500         * support/regression/literalop.c: added, work in progress
5501
5502 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5503
5504         Generate warnings for useless declarations like "char data;"
5505         that don't do what new users expect.
5506
5507         * src/SDCC.y
5508         * support/Util/SDCCerr.h
5509         * support/Util/SDCCerr.c
5510
5511 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
5512
5513         * src/SDCCval.c (valMult): fix overflow detection of negative int
5514
5515 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5516
5517         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
5518
5519         Changes to support big endian targets:
5520
5521         * src/ports.h
5522         * src/SDCCglue.c
5523         * src/avr/main.c
5524         * src/ds390/main.c
5525         * src/izt/i186.c
5526         * src/mcs51/main.c
5527         * src/pic/main.c
5528         * src/pic16/main.c
5529         * src/xa51/main.c
5530         * src/z80/main.c
5531
5532 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
5533
5534         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
5535         * device/lib/time.c: fixed warning "integer overflow in expression"
5536
5537 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
5538
5539         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
5540         * src/SDCCval.c (constVal): changed default to signed; hex and octal
5541         constants are unsigned; added recognition of "u" flag for unsigned
5542         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
5543         * src/SDCCval.c (valDiv, valMod): fixed signdness
5544         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
5545         signedness of modulo, left and right shift
5546         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
5547         * support/Util/SDCCerr.h: added warning W_INT_OVL
5548         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
5549         * src/SDCCast.c (ast_print): improved output of constants
5550
5551 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5552
5553         Fixed some warnings when building with MSVC:
5554
5555         * as\mcs51\asdata.c
5556         * as\z80\asdata.c
5557         * as\mcs51\asm.h
5558         * as\z80\asm.h
5559         * link\z80\aslink.h
5560         * link\z80\lkdata.c
5561         * link\z80\lkeval.c
5562         * link\z80\lkgb.c
5563         * link\z80\lkihx.c
5564         * link\z80\lks19.c
5565         * link\z80\lksym.c
5566         * support\cpp2\cpplib.c
5567         * src\ds390\gen.c
5568         * src\mcs51\gen.c
5569
5570 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
5571
5572         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
5573
5574 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5575
5576         * support\librarian\clean.mk: Do not remove Makefile.
5577         * support\librarian\Makefile: added.
5578
5579 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5580
5581         Added librarian to MSVC build:
5582         * all.dsp
5583         * sdcc.dsw
5584         * support\librarian\librarian.dsp
5585
5586         'configure' not needed for librarian, removed:
5587         * support\librarian\configure
5588         * support\librarian\configure.in
5589         * support\librarian\config_in.h
5590         * support\librarian\Makefile.in
5591
5592         Hopefully these ones built the librarian and the rest of sdcc properly:
5593         * Makefile
5594         * Makefile.common.in
5595
5596         Messed up 'configure', so revert to previous version:
5597         * configure
5598         * configure.in
5599
5600 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
5601
5602         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
5603         there, while the mantissa of a double is "only" 53 bits wide.
5604
5605 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5606
5607         Adding sdcclib to the build.  MSVC project coming soon.
5608         Files added/changed:
5609
5610         * support\librarian\clean.mk
5611         * support\librarian\configure
5612         * support\librarian\configure.in
5613         * support\librarian\config_in.h
5614         * support\librarian\Makefile.bcc
5615         * support\librarian\Makefile.in
5616         * support\librarian\sdcclib.c
5617         * Makefile.bcc
5618         * Makefile
5619         * Makefile.common.in
5620         * configure
5621         * configure.in
5622
5623 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5624
5625         Linker now complaints if linked modules have conflicting options, for
5626         example, one compiled using --model-large and another one compiled with
5627         --model-small.  The following files were modified:
5628
5629         * as\mcs51\asdata.c
5630         * as\mcs51\aslink.h
5631         * as\mcs51\asm.h
5632         * as\mcs51\asmain.c
5633         * as\mcs51\asout.c
5634         * as\mcs51\i51pst.c
5635         * as\mcs51\lkdata.c
5636         * as\mcs51\lklibr.c
5637         * as\mcs51\lkmain.c
5638         * as\z80\asdata.c
5639         * as\z80\asm.h
5640         * as\z80\asmain.c
5641         * as\z80\asout.c
5642         * as\z80\z80pst.c
5643         * link\z80\aslink.h
5644         * link\z80\lkdata.c
5645         * link\z80\lklibr.c
5646         * link\z80\lkmain.c
5647         * src\SDCCglue.c
5648
5649 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5650
5651         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
5652         as/mcs51/lklibr.c: Generate a warning when a library is not found.
5653
5654 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
5655
5656         * src/z80/mappings.i: fix _mul[us][int,long] entries
5657
5658 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5659
5660         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
5661
5662 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
5663
5664         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
5665         * support/regression/tests/bitopcse.c: added
5666         fixed warning:
5667         * src/avr/gen.c:
5668         * src/pic/gen.c:
5669         * src/pic16/gen.c:
5670         * src/z80/gen.c:
5671         * src/xa51/gen.c:
5672
5673 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5674
5675         added support for new library format to z80, gbz80 linkers:
5676         *link/z80/aslink.h
5677         *link/z80/lklex.c
5678         *link/z80/lklib.c
5679         *link/z80/lklist.c
5680
5681 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
5682
5683         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
5684         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
5685
5686 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
5687
5688         added DUMMY_READ_VOLATILE:
5689         * src/SDCC.y:
5690         * src/avr/gen.c:
5691         * src/xa51/gen.c:
5692         * src/z80/gen.c:
5693         * src/pic/gen.c:
5694         * src/pic16/gen.c:
5695         * src/mcs51/gen.c:
5696         * src/ds390/gen.c:
5697         * src/SDCCcse.c (algebraicOpts): many improvements
5698         * src/SDCCcse.h: removed algebraicOpts()
5699         * src/SDCCicode.c (picDummyRead): added
5700
5701 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5702
5703         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
5704         "Insufficient space in data memory".
5705
5706 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5707
5708         * src/mcs51/gen.c: fixed bug #771358
5709         * src/z80/gen.c: fixed bug #759087
5710
5711 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
5712
5713         * src/pic16/glue.c: minor cleanup by Vangelis
5714
5715 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5716
5717         * device/include/regc515c.h: fixed #758477
5718         * device/lib/_gptrget.c: saving some cycles in generic pointer get
5719         * device/lib/_gptrput.c: saved a few bytes
5720         * my tab spacing is 8, yours too?)
5721         * device/lib/_ser.c: process RX bytes earlier than TX bytes
5722         * device/lib/serial.c: process RX bytes earlier than TX bytes
5723         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
5724
5725 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5726
5727         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
5728
5729 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5730
5731     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
5732
5733 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
5734
5735         * device/lib/Makefile.in: bad fix, reverted to 1.43
5736
5737 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
5738
5739         * device/lib/Makefile.in: added missing z80 object files
5740
5741 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
5742
5743         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
5744         pic16 progress by Vangelis:
5745         * src/SDCCglobl.h:
5746         * src/SDCCmain.c:
5747         * src/pic/Makefile:
5748         * src/pic:
5749         * pic/Makefile:
5750         * pic16/device.c:
5751         * pic16/device.h:
5752         * pic16/gen.c:
5753         * pic16/gen.h:
5754         * pic16/genarith.c:
5755         * pic16/glue.c:
5756         * pic16/main.c:
5757         * pic16/pcode.c:
5758         * pic16/pcode.h:
5759         * pic16/pcodepeep.c:
5760         * pic16/peeph.def:
5761
5762 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5763
5764     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
5765
5766 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5767
5768     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
5769     added gbz80 build to MSVC project.
5770     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
5771     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
5772     from 8051 stuff and setup so it links using a .lnk file.
5773
5774 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5775
5776     * support/librarian/sdcclib.c: sdcc librarian.
5777     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
5778     with sdcclib.
5779
5780 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5781
5782     * as/mcs51/lkmain.c: properly handle extensions in function afile.
5783
5784 2003-07-02  Borut Razem <borut.razem AT siol.net>
5785
5786         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
5787         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
5788         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
5789         src/xa51/main.c, src/z80/main.c:
5790         virtualization of glue() function: each port has it's own glue function,
5791         which is accessed by do_glue function pointer in PORT.general structure
5792
5793 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
5794
5795         * DS800C400 fun, improved ROM interface and tinibios.
5796
5797 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
5798
5799         * More support for DS80C400. Now includes beginning of interface to ROM.
5800
5801 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
5802
5803         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
5804
5805 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5806
5807         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
5808
5809 2003-06-19  Borut Razem <borut.razem AT siol.net>
5810
5811         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
5812
5813 2003-06-19  Borut Razem <borut.razem AT siol.net>
5814
5815         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
5816         fixed Z80 port - crt0.o: cannot open.
5817
5818 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
5819
5820         * support/Util/MySystem.c (merge_command): revert bad fix
5821
5822 2003-06-18  Borut Razem <borut.razem AT siol.net>
5823
5824         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
5825
5826 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5827
5828         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
5829         option --use-stdout sends errors to stdout instead of stderr.
5830
5831 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
5832
5833         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
5834
5835 2003-06-15  Borut Razem <borut.razem AT siol.net>
5836
5837         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
5838         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
5839         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
5840         fixed width array of pointers replaced with sets;
5841         multiple include and lib paths ared transferred to preprocessor and linker
5842         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
5843         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
5844         fixed width array of pointers
5845         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
5846         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
5847         fixupPath(), getPathDifference()
5848         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
5849         fixed width array of pointers
5850
5851 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
5852
5853         * src/pic16/ralloc.c: fix warnings
5854         * src/pic16/pcode.c: fix warning
5855
5856 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
5857
5858          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
5859         know all the details, but essentially this set of changes enable
5860         the pic16 port to generate movff instructions and generate assembler
5861         directives,
5862         * src/SDCCmain.c:
5863         * src/pic16/gen.c:
5864         * src/pic16/glue.c:
5865         * src/pic16/pcode.c:
5866         * src/pic16/device.c:
5867         * src/pic16/main.c:
5868         * src/pic16/pcode.h:
5869         * src/pic16/pcoderegs.c:
5870         * src/pic16/ralloc.c:
5871         * src/pic16/ralloc.h:
5872
5873 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5874
5875         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
5876         added option --vc, so sdcc errors and warnings are compatible with
5877         Microsoft Visual Studio.
5878
5879 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5880
5881         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
5882           device/lib/libfloat.lib: added atof function.
5883
5884 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
5885
5886         * doc/sdccman.lyx: updated to Lyx 1.3
5887         * doc/cdbfileformat.lyx: updated to Lyx 1.3
5888         * doc/test_suite_spec.lyx: updated to Lyx 1.3
5889         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
5890
5891 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
5892
5893         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
5894
5895 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5896
5897         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
5898           additions to the "related tools/documentation" section
5899
5900 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
5901
5902         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
5903
5904 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
5905
5906         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
5907         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
5908
5909 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
5910
5911         * doc/sdccman.lyx: fix double dash and other minor things
5912         * doc/Makefile: fix double dash
5913
5914 2003-05-28  Karl Bongers(patches from Martin Helmling)
5915         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
5916           condition and ignore commands.
5917
5918 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5919
5920         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
5921           is in parts still quite out of date, I did changes as far as I felt makes sense
5922           for a non-native english speaker.
5923           Please feel free to add to the manual or to correct my changes.
5924         * doc/Makefile: undid touching the date of intermediate tex files.
5925
5926 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5927
5928         * doc/sdccman.lyx: Manual has an index now
5929
5930 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
5931
5932         Finalize muluint/mulsint and mululong/mulslong merging:
5933         * device/lib/_mulint.c
5934         * device/lib/_mullong.c
5935         * device/lib/gbz80/mul.s
5936         * device/lib/gbz80/stubs.s
5937         * device/lib/z80/mul.s
5938         * device/lib/z80/stubs.s
5939         * src/SDCCsymt.c (initCSupport)
5940
5941 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5942
5943         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
5944         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
5945           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
5946           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
5947           instead of /Zm500.
5948
5949 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5950
5951         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
5952           the regression tests I'm not brave enough to enable 245.b, 245.c
5953         * doc/sdccman.lyx: added latex preamble for hyperref package.
5954           Using pdflatex this will give you a hyperlinked pdf file with
5955           bookmarks. (prepend '%' before /usepackage if this breaks something)
5956
5957 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5958
5959          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
5960
5961 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
5962
5963         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
5964
5965 2003-05-21    <johan AT balder>
5966
5967         * src/SDCCglue.c (printIval): fixed bug #739934
5968
5969 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
5970
5971         Applied patch from bug 737905 (renamed yylineo to mylineno):
5972         * src/altlex.c
5973         * src/SDCCast.c
5974         * src/SDCglobl.h
5975         * src/SDCC.lex
5976         * src/SDCCsymt.c
5977         * src/SDCCval.c
5978         * src/pic16/pcode.c: Cleaned warnings
5979         * src/pic16/pcodeflow.c: Cleaned warnings
5980         * src/pic16/pcoderegs.c: Cleaned warnings
5981
5982 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
5983
5984         * src/pic16/pcode.c: Cleaned warnings
5985         * src/pic16/pcodepeep.c: Cleaned warnings
5986         * src/pic16/ralloc.c: Cleaned warnings
5987
5988 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
5989
5990         * doc/sdccman.lyx: fixed bug 739745
5991         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
5992
5993 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
5994
5995         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
5996         it can be defined with CFLAGS when running configure
5997         * src/SDCCmain.c: fixed compiling + linking with object files
5998
5999 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
6000
6001         * configure.in: configure for pic16 port,
6002             added --disable-pic16-port
6003         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
6004         * src/SDCCmain.c: linkOptions is changed to set *,
6005             added if/endif conditional macros to remove options help
6006             messages from optionsTable when a port is not configured, added
6007             support for the PIc16 port in the ports table, when executing
6008             the compiler with no port specified on command line, a default
6009             port is selected with the new macro DEFAULT_PORT which is
6010             defined in port.h, in setDefaultOptions() linkOptions is removed
6011             from initialization assignment, since now it is a set,
6012             parseCmdLine uses setParseWithComma for linkOptions, in
6013             linkEdit() linkOptions are accessed with new function indexSet()
6014             which returns the i'th item of a set variable. See SDCCset.c, in
6015             linkEdit() when calling buildCmdLine(), added linkOptions as
6016             last argument. Now users can pass arguments to gplink via the
6017             -Wl option, main() uses pic16glue() to glue up pic16 programs
6018         * src/SDCCpeeph.c: various changes to support pic16
6019         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
6020             return the i'th item of the set
6021         * src/SDCCset.h: added function prototype for indexSet()
6022         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
6023         * src/clean.mk: added pic16 in CLEANALLPORTS variable
6024         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
6025             added macro DEFAULT_PORT
6026         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
6027         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
6028             generated
6029         * src/pic16/glue.c: commented out some error producing lines
6030         * src/pic16/main.c: __config directives are commented out to stop
6031             gpasm complaining and test the linkage with gplink, _linkCmd and
6032             _asmCmd changed to be more gplink and gpasm friendly
6033         * src/pic16/peeph.def: peep rule 3 is commented out, since it
6034             produced an error when parsed, peep rule 12 is added to utilize
6035             movff, but it is commented out since the pCode does not support
6036             yet a command with 2 address arguments
6037
6038 2003-05-18    <johan AT balder>
6039
6040         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
6041         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
6042 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
6043
6044         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
6045   Added feature to script commands from file.
6046
6047 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
6048
6049         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
6050         * src/SDCCutil.c: include ctype.h for win32
6051
6052 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
6053
6054         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
6055
6056 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
6057
6058         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
6059   Fixed so you can set breakpoints prior to run, run does not stop
6060   on entry now.  Add tbreak.  Other enhancements and fixes for use
6061   with ddd.
6062
6063 2003-05-12  Borut Razem <borut.razem AT siol.net>
6064
6065         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
6066
6067 2003-05-11  Borut Razem <borut.razem AT siol.net>
6068
6069         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
6070         the path of bin directory, so that PATH is the only env. variable, which has to be set
6071         in case of standard installation.
6072         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
6073         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
6074         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
6075
6076 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
6077
6078         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
6079         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
6080         temp files are in the port dir; clean the gen/test directory when
6081         generating new test.c
6082         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
6083         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
6084         * support/regression/tests/zeropad.c: added
6085
6086 2003-05-09    <johan AT balder>
6087
6088         * src/SDCCglue.c: fixed bug #597940
6089
6090 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
6091
6092         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
6093   cache sfr, optimize next,step, fix off by one sourceline,
6094   support ddd list function.
6095         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
6096
6097 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
6098
6099         * support/regression/HTMLgen.py: added compare_s2f()
6100         * support/regression/Makefile: redo 1.27
6101         * support/regression/generate-cases.py: redo 1.5
6102
6103 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
6104
6105         * support/regression/tests/float.c: workaround 33 bit hex constant
6106         * support/regression/tests/simplefloat.c: fix division for host
6107
6108 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
6109
6110         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
6111         that tame's the PIC's over-aggressive optimizer.
6112
6113 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6114
6115          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
6116          support for MSVC.
6117
6118 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
6119
6120         Initial support for DS80C400. "Hello world" runs on TINIm400
6121         (with polled I/O).
6122
6123 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
6124
6125          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
6126          * Some notes on ddd usage added in debugger/README
6127          Martin Helmling adding more features and fixes for ddd GUI debugger.
6128          Code added for nexti, stepi, up, down, and other adjustments.
6129
6130 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
6131
6132         * src/pic/pCodepeep.c non-wildcard asmops are now handled
6133         * src/pic/peeph.def Added two rules to optimize carry manipulation
6134         * src/pic/* removed debug printfs
6135
6136 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
6137
6138         * debugger/mcs51/cmd.c: added header newalloc.h
6139
6140 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
6141
6142         * as/Makefile: new EXEEXT
6143         * as/z80/Makefile: remove trailing slash of BUILDIR
6144         * as/z80/clean.mk: new EXEEXT
6145         * Makefile.common.in: add to CFLAGS (and others), don't replace it
6146         * support/cpp2/Makefile.in: new EXEEXT
6147         * src/pic/glue.c (pic14emitRegularMap): fixed warning
6148
6149 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
6150
6151         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
6152         EXEEXT was introduced to fix all related problems with targets
6153         "clean", "install" and "uninstall"; a couple of further flaws
6154         especially with "clean" have been fixed too
6155         * as/mcs51/Makefile.in
6156         * as/mcs51/clean.mk
6157         * as/z80/Makefile
6158         * Makefile
6159         * clean.mk
6160         * debugger/mcs51/Makefile.in
6161         * debugger/mcs51/clean.mk
6162         * link/z80/Makefile
6163         * link/z80/Makefile.in
6164         * link/z80/clean.mk
6165         * link/Makefile
6166         * packihx/Makefile.in
6167         * packihx/clean.mk
6168         * sim/ucsim/Makefile
6169         * sim/ucsim/clean.mk
6170         * sim/ucsim/avr.src/Makefile.in
6171         * sim/ucsim/avr.src/clean.mk
6172         * sim/ucsim/s51.src/Makefile.in
6173         * sim/ucsim/s51.src/clean.mk
6174         * sim/ucsim/xa.src/Makefile.in
6175         * sim/ucsim/xa.src/clean.mk
6176         * sim/ucsim/z80.src/Makefile.in
6177         * sim/ucsim/z80.src/clean.mk
6178         * sim/ucsim/main_in.mk
6179         * sim/ucsim/packages_in.mk
6180         * sim/ucsim/gui.src/Makefile.in
6181         * sim/ucsim/gui.src/serio.src/Makefile.in
6182         * sim/ucsim/gui.src/serio.src/clean.mk
6183         * src/Makefile.in
6184         * src/clean.mk
6185         * support/cpp2/Makefile.in
6186         * support/cpp2/clean.mk
6187         * support/makebin/Makefile
6188         * support/makebin/clean.mk
6189         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
6190         * doc/sdccman.lyx: --program-suffix no longer needed
6191
6192 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
6193
6194          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
6195          Martin Helmling added support for ddd GUI debugger.
6196          Code added to display assembly, set variables, and other commands
6197          to interface to ddd.
6198
6199 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
6200
6201         * as/Makefile: fix target clean
6202         * as/clean.mk: fix target clean
6203         * as/z80/clean.mk: fix target clean
6204
6205 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
6206
6207         * Makefile.common.in: added  AT EXEEXT AT
6208         * configure.in: removed all mingw32 stuff
6209         * configure: rebuilt from configure.in
6210         * doc/sdccman.lyx: updated section "installation"
6211         * support/scripts/sdcc_mingw32: adapted to configure
6212         * support/scripts/sdcc_cygwin_mingw32: added
6213
6214 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
6215
6216         * src/pic Added object file support for the PIC port
6217         * src/pic Applied patch from Craig Franklin (this started the object file support)
6218         * src/regression Updated the PIC regression tests for object files
6219
6220 2003-04-20  Borut Razem <borut.razem AT siol.net>
6221
6222         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
6223           lklex.c: In function `getfid':
6224           lklex.c:203: warning: array subscript has type `char'
6225         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
6226           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
6227         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
6228           stack handling macros
6229
6230 2003-04-19  Borut Razem <borut.razem AT siol.net>
6231
6232         * "handling space characters in file path" task:
6233         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
6234         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
6235         * support/Util/MySystem.h: make it self-sufficient
6236         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
6237           src/z80/main.c, sdcc/as/mcs51/lklex.c:
6238           handling space characters in file path
6239         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
6240           (it will be used by assemblers, which have their own includes, e.g. gpasm)
6241         * support/Util/MySystem.c: handling space characters in executable's path
6242
6243 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
6244
6245         * as/z80/Makefile: fix permanent rebuild of z80
6246         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
6247         * support/regression/tests/bitfields.c: added Johan's bitfields.c
6248
6249 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
6250
6251         * src/SDCCopt.c: add special case optimization to replace modulo by
6252           a power of two with a bitwise AND.
6253
6254 2003-04-18    <johan AT balder>
6255
6256         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
6257
6258 2003-04-17    <johan AT balder>
6259
6260         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
6261         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
6262
6263 2003-04-13  Borut Razem <borut.razem AT siol.net>
6264
6265         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
6266         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
6267           fixed mingw problem in adl_NORMALIZE_PATH
6268
6269 2003-04-12  Borut Razem <borut.razem AT siol.net>
6270
6271         * fixed "#pragma SAVE/RESTORE can not be nested":
6272         * src/SDCC.lex: reworked pragma handling functions
6273         * sdcc/src/SDCCglobl.h: reworked stack handling macros
6274         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
6275
6276 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
6277
6278         * src/SDCCutil.c (pathEquivalent): defined but not used
6279         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
6280         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
6281         * configure: rebuilt from configure.in
6282         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
6283         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
6284         * device/include/Makefile.in: replace sdcc_datadir
6285         * device/lib/Makefile.in: replace sdcc_datadir
6286         * Makefile.common.in: add LDFLAGS from configure
6287         * packihx/Makefile.in: use LDFLAGS
6288         * src/Makefile.in: use LDFLAGS
6289         * support/cpp2/Makefile.in: add LDFLAGS from configure
6290         * support/makebin/Makefile: use LDFLAGS
6291         * .version: bumped version number to 2.3.5
6292
6293 2003-04-12  Borut Razem <borut.razem AT siol.net>
6294
6295         * completed "different paths" task:
6296         * src/SDCCmacro.c: fixed bug in handling quotes
6297         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
6298         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
6299
6300 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
6301
6302         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
6303
6304 2003-04-11 kevin Vigor <kevin AT vigor.nu>
6305
6306         * ds390/gen.c ds390/peeph.def: fix bug 706781
6307
6308 2003-04-11  Borut Razem <borut.razem AT siol.net>
6309
6310         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
6311
6312 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
6313
6314         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
6315         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
6316          set - this bit used to not be set...).
6317         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
6318           bad code in PIC Port
6319         * src/regression/and2.c added to test bug 609268
6320         * src/regression/Makefile added and2.c to regression test
6321
6322
6323 2003-04-08    <johan AT CP255758-A>
6324
6325         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
6326         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
6327         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
6328
6329 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
6330
6331         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
6332         fix bug #487815
6333         * support/cpp2/Makefile.in: fix bug #487815
6334         * configure: rebuilt from configure.in
6335         * Makefile.common.in: docdir changed, new path suffixes
6336         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
6337         * sdcc_vc_in.h: reflect changes from sdccconf.h
6338         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
6339         * src/SDCCutil.h: remove BINDIR hack
6340         * doc/sdccman.lyx: update new path hierarchy
6341
6342 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
6343
6344         * src/SDCCpeeph.c: added okToRemoveSLOC test
6345
6346 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
6347
6348         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
6349
6350 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
6351
6352         * src/SDCCpeeph.c: added labelIsReturnOnly test
6353         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
6354
6355 2003-04-05    <johan AT balder>
6356
6357         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
6358         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
6359         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
6360         * src/SDCCast.c: fixed a warning
6361         * src/SDCCast.h: fixed a warning
6362         * src/SDCCicode.c (operandFromAst): fixed a warning
6363
6364 2003-04-04    <johan AT balder>
6365
6366         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
6367         * src/SDCCast.c (decorateType): fixed bug #715076
6368         * src/SDCC.y: fixed bug #702907
6369
6370 2003-04-03    <johan AT balder>
6371
6372         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
6373         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
6374         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
6375         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
6376         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
6377
6378 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
6379
6380         * _decdptr.c: fix return values
6381         * _gptrget.c: fix return values
6382         * _gptrgetc.c: fix return values
6383         * _gptrput.c: fix return values
6384         * _mulint.c: fix return values
6385         * as/z80/Makefile: fix 'make -j' problem
6386
6387 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
6388
6389         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
6390         * configure.in: big cleanup, updated to autoconf 2.5x
6391         * configure: rebuilt from configure.in
6392         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
6393         * sdcc_vc_in.h: reflect changes from sdccconf.h
6394         * doc/Makefile: fixed a flaw in "make install"
6395
6396 2003-04-02    <johan AT balder>
6397
6398         * src/ds390/gen.c (genCmp): no comments
6399         * src/mcs51/gen.c (genCmp): no comments
6400         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
6401         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
6402
6403 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
6404
6405         * support/regression/generate-cases.py: place generated file in given sub directory
6406         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
6407         * support/regression/Makefile: improvements for 'make -j';
6408         side effect: it's simpler and faster now
6409
6410 2003-03-31  Borut Razem <borut.razem AT siol.net>
6411
6412         * src/z80/main.c: link-{port} and as-{port} defined without path
6413         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
6414
6415 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
6416
6417         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
6418
6419 2003-03-30  Borut Razem <borut.razem AT siol.net>
6420
6421         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
6422           changed type of list parameter to set
6423         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
6424         * src/port.h: changed type of do_assemble() parameter to set
6425         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
6426           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
6427           definition of "cppoutfilename" macro with NULL value in preProcess()
6428         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
6429         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
6430         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
6431           replaced with set *binPathSet
6432         * shash_add() deallocates the item, if allready exsists, before adding the new one
6433         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
6434
6435 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
6436
6437         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
6438           a nested for loop bug in the PIC port
6439         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
6440           for loops
6441
6442 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
6443
6444         * support/Util/dbuf.h: remove C++ stuff to make it portable
6445
6446 2003-03-28  Borut Razem <borut.razem AT siol.net>
6447
6448         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
6449           literal strings in stringLiteral()
6450         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
6451         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
6452           to the project
6453
6454 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
6455
6456         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
6457
6458 2003-03-26    <johan AT balder>
6459
6460         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
6461         * src/ds390/gen.c (saveRegisters): catched symbol abuse
6462         * src/SDCCast.c (decorateType): fixed " -v < 3"
6463
6464 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
6465
6466         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
6467         Added Lenny Story's debug infrastructure changes:
6468         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
6469         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
6470         * src/cdbFile.c: added
6471         * src/SDCCdebug.c: added
6472         * src/SDCCdebug.h: added
6473         * src/SDCCast.c (createFunction)
6474         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
6475         * src/SDCCmain.c (parseCmdLine, main)
6476         * src/SDCCmem.c (redoStackOffsets)
6477         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
6478         * src/SDCCsymt.h
6479         * src/common.h
6480         * src/avr/gen.c (genAVRCode)
6481         * src/ds390/gen.c (gen390Code)
6482         * src/mcs51/gen.c (gen51Code)
6483         * src/pic/gen.c (genpic14Code)
6484         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
6485         * src/xa51/gen.c (genXA51Code)
6486         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
6487
6488 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6489
6490         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
6491         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
6492
6493 2003-03-22    <johan AT balder>
6494
6495         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
6496
6497 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
6498
6499         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
6500         * doc/cdbfileformat.lyx: added, written by Lenny Story
6501         * doc/Makefile: added cdbfileformat.lyx
6502         * doc/clean.mk: added cdbfileformat.lyx
6503
6504 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
6505
6506         * src/mcs51/peeph.def: fix bug #705773
6507
6508 2003-03-20    <johan AT balder>
6509
6510         An sfr/sbit can have an "at #" AND an initializer
6511         * src/SDCCsymt.c (checkSClass):
6512         * src/SDCCmem.c (allocGlobal):
6513         * src/SDCCmem.c (allocLocal):
6514         * src/SDCCast.c (createBlock):
6515
6516 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
6517
6518         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
6519
6520 2003-03-16    <johan AT balder>
6521
6522         Undid the hackup of const and volatile, the problem is much bigger
6523         * src/SDCC.y:1.65
6524         * src/SDCCast.c:1.171
6525         * src/SDCCglue.c:1.138
6526         * src/SDCCicode.c:1.146
6527         * src/SDCCsymt.c:1.150
6528         * src/SDCCval.c:1.65
6529
6530 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
6531
6532         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
6533         * src/ds390/gen.c (genAddrOf): fixed bug #704087
6534
6535 2003-03-13    <johan AT balder>
6536
6537         Hackup const and volatile modifiers in type chains a bit:
6538         * src/SDCC.y:1.63
6539         * src/SDCCast.c:1.169
6540         * src/SDCCglue.c:1.136
6541         * src/SDCCicode.c:1.143
6542         * src/SDCCsymt.c1.146
6543         * src/SDCCsymt.h1.59
6544         * src/SDCCval.c:1.63
6545
6546 2003-03-12    <johan AT balder>
6547
6548         * src/SDCCBBlock.h: more LRH debugging junk
6549         * src/SDCCcflow.h: more LRH debugging junk
6550         * src/SDCCloop.c: more LRH debugging junk
6551         * src/SDCC.y (struct_declaration): fixed bug #697590
6552         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
6553         * src/ds390/gen.c (aopForRemat): fixed bug #700031
6554         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
6555
6556 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
6557         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
6558         test function names must now match exactly).
6559         * src/SDCCcse.c: added special case in findCheaperOp to allow
6560         extending a short integer. Makes less awful code for bug 700121 test case.
6561
6562 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6563
6564         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
6565         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
6566
6567 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
6568
6569         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
6570         actually called (operandsNotEqual() was called for all
6571         operandsNotEqualX tests).
6572
6573 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
6574
6575         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
6576         with shorter literals. Fixes bug 700121.
6577
6578 2003-03-11    <johan AT balder>
6579
6580         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
6581
6582 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
6583
6584         * src/SDCCloop.c (mergeRegions): an evil beast is dead
6585         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
6586
6587 2003-03-10  Borut Razem <borut.razem AT siol.net>
6588
6589         * src/SDCCmain.c: pipe preprocessor's output
6590         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
6591         * sdcc_vc_in.h: define pclose as _pclose for WIN32
6592         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
6593         which closes all pipes in pipeSet set
6594         * src/SDCCset.c: free deleted item in function deleteSetItem()
6595         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
6596         moved from z80 to src subproject
6597         * .version: increased version number to 2.3.4
6598
6599 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
6600
6601         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
6602         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
6603         * support/regression/ports/xa51/spec.mk: fix typo
6604
6605 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
6606
6607         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
6608
6609 2003-03-09  Borut Razem <borut.razem AT siol.net>
6610
6611         * src/SDCCmain.c: pipe preprocessor's output
6612         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
6613         * sdcc_vc_in.h: define pclose as _pclose for WIN32
6614         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
6615         which closes all pipes in pipeSet set
6616         * src/SDCCset.c: free deleted item in function deleteSetItem()
6617         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
6618         moved from z80 to src subproject
6619
6620 2003-03-09  Borut Razem <borut.razem AT siol.net>
6621
6622         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
6623         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
6624         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
6625         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
6626         * src/SDCCglobl.h: unification of WIN32 native definitions
6627
6628 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6629
6630         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
6631
6632 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
6633
6634         * src/configure.in:   check for endianess (even while cross-compiling)
6635         * src/configure:      check for endianess (even while cross-compiling)
6636         * src/configure_in.h: check for endianess (even while cross-compiling)
6637         * src/avr/gen.c:        remove old endianess stuff
6638         * src/mcs51/gen.c:      remove old endianess stuff
6639         * src/ds390/gen.c:      remove old endianess stuff
6640         * src/pic/gen.c:        remove old endianess stuff
6641         * src/pic/genarith.c:   remove old endianess stuff
6642         * src/pic/glue.c:       fix endianess check
6643         * src/pic16/gen.c:      remove old endianess stuff
6644         * src/pic16/genarith.c: remove old endianess stuff
6645         * src/pic16/glue.c:     fix endianess check
6646         * src/xa51/gen.c:       remove old endianess stuff
6647         * src/z80/gen.c:        fix endianess check
6648         * src/SDCCglue.c:       fix endianess check
6649         * src/ds390/peeph.def: fix bug 700036
6650
6651 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
6652
6653         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
6654         * src/configure: find appropriate data-types on host for SDCC's int and long
6655         * src/configure.in: find appropriate data-types on host for SDCC's int and long
6656         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
6657         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
6658
6659 2003-03-07    <johan AT balder>
6660
6661         Just a big NOOP:
6662                 some minor cleanups before the big shot
6663                 OP_DEFS and OP_USES now use Kevin's protection
6664                 new option --nolabelopt
6665
6666         * src/SDCCBBlock.c:
6667         * src/SDCCast.c,:
6668         * src/SDCCcflow.c:
6669         * src/SDCCcse.c:
6670         * src/SDCCicode.c:
6671         * src/SDCCicode.h:
6672         * src/SDCClabel.c:
6673         * src/SDCCloop.c:
6674         * src/SDCCmain.c:
6675         * src/ds390/ralloc.c:
6676         * src/mcs51/ralloc.c:
6677         * src/pic/ralloc.c:
6678         * src/xa51/ralloc.c:
6679         * src/z80/ralloc.c:
6680
6681 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
6682
6683         * src/pic/pcode.c (get_op): fix 64 bit warnings
6684         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
6685         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
6686         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
6687         * support/regression/tests/malloc.c: fix 64 bit warnings
6688
6689 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
6690
6691         * src/mcs51/gen.c (genMinus): fixed bug 696436
6692
6693 2003-03-02  Borut Razem <borut.razem AT siol.net>
6694
6695         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
6696
6697 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
6698
6699         * configure.in: test for mkstemp
6700         * sdccconf_in.h: add HAVE_MKSTEMP
6701
6702 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
6703
6704         * device/include/ctype.h: removed warning while using --stack-auto
6705         * device/include/malloc.h: removed warning while using --stack-auto
6706         * device/include/string.h: removed warning while using --stack-auto
6707
6708 2003-02-23  Borut Razem <borut.razem AT siol.net>
6709
6710         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
6711         because NDEBUG is defined (see man assert)
6712         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
6713
6714 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6715
6716         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
6717         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
6718
6719 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6720
6721         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
6722         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
6723
6724 2003-02-18    <johan AT balder>
6725
6726         * as/mcs51/asmain.c (asmbl): module can start with a digit
6727         * as/z80/asmain.c (asmbl): module can start with a digit
6728
6729 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
6730
6731         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
6732         * src/asm.c: fix pipe() for Mingw32
6733
6734 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
6735
6736         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
6737         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
6738         make -V work again; --c1mode reads now from stdin
6739         * doc/sdccman.lyx: added --c1mode
6740         * support/Util/SDCCerr.c: new messages for c1 mode
6741         * support/Util/SDCCerr.h: new messages for c1 mode
6742         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
6743
6744 2003-02-15    <johan AT balder>
6745
6746         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
6747
6748 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
6749
6750         * doc/sdccman.lyx: Environment variables, -o and other minor things
6751
6752 2003-02-14    <johan AT balder>
6753
6754         * src/xa51/main.c: before anyone really tries to use it :)
6755
6756         * Install doc's in share/sdcc/doc
6757         * removed some obsolete files
6758         * Do a proper make distclean and uninstall
6759         M Makefile.common.in
6760         R sdccbuild.sh
6761         M as/Makefile
6762         M device/include/Makefile.in
6763         M device/lib/Makefile.in
6764         M doc/sdccman.lyx
6765         M link/Makefile
6766         M sim/ucsim/doc/Makefile.in
6767         M src/clean.mk
6768         R src/avr/peeph.rul
6769         R src/xa51/peeph.rul
6770         M support/cpp2/Makefile.in
6771         M support/makebin/Makefile
6772
6773
6774 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
6775
6776         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
6777
6778 2003-02-10  Borut Razem <borut.razem AT siol.net>
6779
6780         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
6781         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
6782         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
6783         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
6784         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
6785         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
6786         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
6787         src/z80/Makefile.bcc: Borland Makefile cleanup
6788         * as/z80/Makefile.bcc: Added Borland Makefile
6789         * support/cpp2/borland.h: Removed
6790
6791 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
6792
6793         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
6794         * src/SDCC.lex: new pragma NOIV
6795         * src/SDCCglobl.h: new pragma NOIV
6796         * src/SDCCmem.c: new pragma NOIV
6797
6798 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
6799
6800         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
6801
6802 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
6803
6804         * src/SDCCmain.c: signal handling is switched off by --debug
6805         * doc/Makefile: small fix for install; use clean.mk again
6806         * doc/clean.mk: clean *.pdf and *.html too
6807
6808 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
6809
6810         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
6811         * device/lib/printfl.c: fix a ds390 bug by making it portable
6812         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
6813         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
6814         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
6815         * debugger/mcs51/cmd.c: converted multi-line string literals
6816         * sim/ucsim/globals.cc: converted multi-line string literals
6817         * src/SDCCmain.c: introduced signal handler to remove temp files
6818         * doc/Makefile: small tweaks, implement clean
6819         * doc: removed generated files
6820
6821 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6822
6823         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
6824         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
6825         Address Record is not correctly generated for DS390."
6826
6827 2003-02-02  Borut Razem <borut.razem AT siol.net>
6828
6829         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
6830         * as/mcs51/asm.h: fixed compilation with Borland C
6831         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
6832         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
6833         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
6834         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
6835         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
6836         src/z80/Makefile.bcc: delete $(LIB) only if exist
6837         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
6838
6839 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
6840
6841         * device/include/malloc.h: introduced NULL
6842         * device/include/string.h: introduced NULL
6843         * device/include/stdlib.h: introduced NULL
6844         * device/lib/_memcpy.c: removed NULL
6845         * device/lib/_strcat.c: removed NULL
6846         * device/lib/_strchr.c: removed NULL
6847         * device/lib/_strcmp.c: removed NULL
6848         * device/lib/_strcpy.c: removed NULL
6849         * device/lib/_strcspn.c: removed NULL
6850         * device/lib/_strlen.c: removed NULL
6851         * device/lib/_strncat.c: removed NULL
6852         * device/lib/_strncmp.c: removed NULL
6853         * device/lib/_strncpy.c: removed NULL
6854         * device/lib/_strpbrk.c: removed NULL
6855         * device/lib/_strrchr.c: removed NULL
6856         * device/lib/_strspn.c: removed NULL
6857         * device/lib/_strstr.c: removed NULL
6858         * device/lib/_strtok.c: removed NULL
6859         * device/lib/malloc.c: removed NULL, include own header
6860
6861 2003-02-02    <johan AT balder>
6862
6863         * 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
6864         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
6865         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
6866         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
6867         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
6868         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
6869
6870 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6871
6872         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
6873         area 'DATA'"
6874
6875 2003-02-01    <johan AT balder>
6876
6877         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
6878
6879 2003-01-31    <johan AT CP255758-A>
6880
6881         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
6882
6883 2003-01-30    <johan AT balder>
6884
6885         * src/SDCCBBlock.c: automatic bug detection
6886         * src/SDCCicode.c: automatic bug detection
6887
6888 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6889
6890         * src/SDCCglobl.h:   now --xram-size 0 works
6891         * src/SDCCmain.c:    now --xram-size 0 works
6892
6893 2003-01-29    <johan AT balder>
6894
6895         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
6896
6897 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6898
6899         * as/mcs51/aslink.h: Added options --xram-size and --code-size
6900         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
6901         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
6902         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
6903         * src/SDCCglobl.h:   Added options --xram-size and --code-size
6904         * src/SDCCmain.c:    Added options --xram-size and --code-size
6905
6906 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
6907
6908         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
6909         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
6910
6911 2003-01-27    <johan AT balder>
6912
6913         * src/SDCC.y: fixed bug #613764
6914
6915 2003-01-26    <johan AT balder>
6916
6917         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
6918         * src/SDCCsymt.h: fixed bug #673374
6919         * src/SDCCglue.c: fixed bug #661910
6920         * src/SDCCast.c: fixed bug #458099 and 673374
6921
6922 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
6923
6924         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
6925         * as/mcs51/strcmpi.h: added
6926         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
6927         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
6928         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
6929         * as/mcs51/assym.c: strcmpi -> as_strcmpi
6930         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
6931         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
6932         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
6933         * as/mcs51/Makefile.aslink: new module strcmpi
6934         * as/mcs51/Makefile.asx8051: new module strcmpi
6935         * as/mcs51/Makefil.bcc: new module strcmpi
6936         * as/mcs51/Makefile.in: new module strcmpi
6937         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
6938
6939 2003-01-26    <johan AT balder>
6940
6941         * src/SDCCglue.c: reverted back to 1.124
6942         * src/SDCCast.c: reverted back to 1.156
6943         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
6944
6945 2003-01-25    <johan AT balder>
6946
6947         * src/SDCCglue.c: A better fix for bug #661910
6948         * src/SDCCast.c: A better fix for bug #661910
6949         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
6950
6951 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
6952
6953         * src/Makefile.in: remove spawn.o
6954         * src/SDCCmain.c: remove spawn.h
6955         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
6956         * src/spawn.c: removed
6957         * src/spawn.h: removed
6958         * support/regression/ports/ds390/spec.mk: link with -r
6959
6960 2003-01-24    <johan AT CP255758-A>
6961
6962         * src/ds390/gen.c (aopOp): fixed bug #667458
6963         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
6964         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
6965         (createIvalCharPtr): an ival doesn't always have a storage class anymore
6966
6967 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
6968
6969         * src/mcs51/peeph.def: better assembler identation by Frieder
6970         * src/mcs51/gen.c: better assembler identation by Frieder
6971
6972 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
6973
6974         * as/z80/string.h: removed for gcc 3.2
6975         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
6976         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
6977
6978 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
6979
6980         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
6981         * src/SDCCpeeph.c (replaceRule): fix bug #663503
6982         * support/regression/Makefile: separate temp files for ports
6983         * support/regression/generate-cases.py: separate temp files for ports
6984         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
6985         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
6986
6987 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
6988
6989         * moved tinitalk to device/examples/ds390
6990
6991 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
6992
6993         * as/mcs51/lkmem.c: rflag is for DS390
6994         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
6995         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
6996                          (linkEdit): move mem- and map-files the same way as ihx-files
6997         * src/z80/main.c (_setDefaultOptions): removed --generic
6998         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
6999         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
7000         * src/pic/glue.c (picglue): --c1mode works again
7001         * src/pic16/glue.c (pic16glue): --c1mode works again
7002         * src/asm.c (printCLine): fix #660034
7003
7004 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
7005
7006         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
7007         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
7008         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
7009         * as/mcs51/lkmem (summary): better fix for sp problem
7010         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
7011         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
7012         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
7013                                               remove --stack-after-data
7014
7015 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
7016
7017         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
7018         * src/SDCCutil.c (join): ugly bug: missing '\0'
7019         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
7020
7021 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
7022
7023         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
7024         * src/port.h: typo
7025         * src/pic/main.c (_asmCmd): gpasm supports -o
7026         * src/z80/main.c: more general macros
7027         * device/lib/Makefile.in: remove intermediate files
7028
7029 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
7030
7031         * .version: Bumped version number to 2.3.3
7032         * src/SDCCBBlock.c: new option -o
7033         * src/SDCCglobl.h: new option -o
7034         * src/SDCCglue.c: new option -o
7035         * src/SDCCmain.c: new option -o
7036         * src/asm.c: new option -o
7037         * src/ds390/main.c: new option -o
7038         * src/pic/glue.c: new option -o
7039         * src/pic/pcode.c: new option -o
7040         * src/pic/ralloc.c: new option -o
7041         * src/pic16/glue.c: new option -o
7042         * src/pic16/pcode.c: new option -o
7043         * src/pic16/ralloc.c: new option -o
7044         * src/z80/main.c: new option -o
7045         * device/lib/Makefile.in: use -o
7046         * support/regression/ports/ds390/spec.mk: use -o
7047         * support/regression/ports/gbz80/spec.mk: use -o
7048         * support/regression/ports/mcs51/spec.mk: use -o
7049         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
7050         * support/regression/ports/z80/spec.mk: use -o
7051         * support/regression/ports/ucz80/spec.mk: use -o
7052         * support/regression/ports/xa51/spec.mk: use -o
7053         * support/regression/fwk/lib/timeout.c: fix usage string
7054
7055 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
7056         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
7057
7058 2003-01-07    <johan AT balder>
7059
7060         * src/SDCCast.c (decorateType): fixed bug #600035
7061
7062 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
7063         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
7064         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
7065         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
7066         * src/pic/pcode.c: outcommented unused variable to remove warnings
7067         * src/pic/ralloc.c: outcommented unused variable to remove warnings
7068
7069 2003-01-06    <karl AT turbobit.com>
7070         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
7071    regression tests.
7072
7073 2003-01-06    <johan AT balder>
7074
7075         * src/SDCCicode.c: fixed array add
7076
7077 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
7078         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
7079         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
7080
7081 2003-01-04    <johan AT balder>
7082
7083         * src/SDCCval.c (getNelements): fixed the initialized array of structures
7084
7085 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7086         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
7087
7088 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
7089         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
7090         * support/regression/tests/bug-524697.c: fit mem usage into 8032
7091
7092 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
7093         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
7094
7095 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
7096         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
7097
7098 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
7099         * src/mcs51/main.c: removed {bindir}{sep} from aslink
7100
7101 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7102
7103     * in \sdcc\as\mcs51\ changed these files in order to create an
7104     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
7105     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
7106     following files to include the previous two files: aslink.dsp,
7107     Makefile.aslink, Makefile.bcc, and Makefile.in.
7108
7109     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
7110     .adb instead of .cdb
7111
7112 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7113
7114         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
7115         value from option --iram-size.
7116
7117 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7118
7119         * \sdcc\as\mcs51\lklist.c: added boundary check before using
7120         dram[] array.
7121
7122 2002-09-18    <wiml AT hhhh.org>
7123
7124         * SDCClrange.h: exposed setFromRange() and setToRange()
7125         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
7126           packRegsForAccUse() (bug 542397)
7127         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
7128           multiple times and emitting the fetch operations more than once
7129           added aopGetUsesAcc() function to allow binary operators to
7130           fetch their operands in the correct order; made genMinus() emit
7131           compact code for X = LITERAL - Y
7132
7133 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7134         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
7135         sprintf() in line 1267.
7136
7137 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7138         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
7139         like ports.
7140
7141 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7142         Changes to aslink (All the changes are marked with 'JCF'):
7143
7144         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
7145         summary().
7146
7147         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
7148         area BSEG.  Also moves, if possible, the DATA area down into the internal
7149         ram so more space is available.
7150
7151         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
7152         sflag.
7153
7154         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
7155         not bytes.  Function summary() which creates a memory usage summary
7156         file with extension .mem.  Reports of overlaping stack and small stack
7157         size.  If the space for the stack is less than 16 bytes aslink trows a
7158         warning.
7159
7160         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
7161         the 8051.  Option 'y' for memory summary output file.
7162
7163         Changes to sdcc (All the changes are marked with 'JCF'):
7164
7165         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
7166
7167         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
7168         overlaying area for it (uses RegBankUsed[4]).
7169
7170         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
7171         bank zero as used by default.  By default aslink locates the stack
7172         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
7173         the creation of the .mem file.  Delegates the allocation of data area
7174         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
7175         the begining of the stack area to aslink.
7176
7177         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
7178         glue() in SDCCglue.c creates an area for it.
7179
7180 2002-09-03  Borut Razem <borut.razem AT siol.net>
7181         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
7182         sdcc/src/pic/glue.c:
7183         introduced atexit() handler for teporay files removal in case of
7184         errors, assertions, ...
7185
7186 2002-08-29  Borut Razem <borut.razem AT siol.net>
7187         * sdcc/support/cpp2/auto-host_vc_in.h:
7188         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
7189         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
7190         Maybe there is a similar problem with BORLANDC? It should be checked!
7191
7192         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
7193         corrected improper use of assert: the assignment to clr variable was done inside the assert.
7194         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
7195         was not executed, and the compiler (cl) launched a warning:
7196         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
7197
7198 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
7199         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
7200
7201 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
7202         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
7203
7204         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
7205           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
7206           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
7207           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
7208           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
7209           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
7210           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
7211         - added Release configuration in VS projects
7212         - review of compiler an linker options
7213         - VC .exe files are generated in bin_vc directory, not to interfere
7214           with binaries generated from other projects (cygwin, mingw, bcc ...)
7215
7216         * sdcc/src/yacc.dsp: added
7217
7218         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
7219         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
7220         and insert the version number definitions from .version
7221
7222         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
7223
7224         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
7225         added - genarate auto-host.h using auto-host_vc_in.h as template
7226
7227         * sdcc/sdcc_vc.h,
7228         removed from CVS, generated automatically
7229
7230 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
7231         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
7232
7233 2002-08-11  Borut Razem <borut.razem AT siol.net>
7234         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
7235
7236 2002-08-10  Borut Razem <borut.razem AT siol.net>
7237         * src/SDCCmain.c (main):
7238         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
7239         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
7240         The consequence was that some temporary files were not removed.
7241
7242         * src/SDCCglue.c:
7243         unification of code in functions tempfilename() and tempfile():
7244         function tempnam() is defined in Visual Studio 6.0 and .NET
7245
7246         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
7247
7248         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
7249           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
7250         - removed compiler command line option /WX: Treats all warnings as errors
7251         - update a list of source files, included into the project
7252
7253         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
7254           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
7255         changed project type to Generic Project so that can be correcly converted to VS.NET project
7256
7257         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
7258
7259         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
7260
7261         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
7262
7263         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
7264         added return 0 statements after assert() to make compiler happy
7265
7266         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
7267         added newline in the def file to keep MSC compiler satisfied
7268
7269         * sdcc/src/z80/gen.c:
7270         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
7271           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
7272         - solved MSC error in function aopDump()
7273
7274         * sdcc_vc.h: define PREFIX as "\\sdcc"
7275
7276 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
7277         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
7278
7279 2002-06-22  Scott Dattalo <scott AT dattalo.com>
7280         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
7281         - Rewrote the register banking algorithm.
7282         - Added pCode live-range analysis to registers (for now, only non-used and
7283         singly-used registers optimized away)
7284
7285         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
7286
7287         * 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.
7288
7289 2002-05-10  Scott Dattalo <scott AT dattalo.com>
7290         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
7291
7292 2002-04-22  Michael Hope  <michaelh AT vroom>
7293
7294         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
7295
7296         * configure.in (DD_COPT): Added include support required for gbdk.
7297
7298         * .version: Bumped version number just to increase it.
7299
7300         * src/SDCCmain.c: Added -nostdinc to the default options.
7301
7302 2002-04-15  Michael Hope  <michaelh AT vroom>
7303
7304         * device/lib/z80/printf.c (sprintf): Added.
7305
7306         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
7307
7308         * src/z80/peeph.def: Added transpose redundent load rule.
7309
7310         * src/z80/main.c: Added force callee saves for jaune.
7311
7312         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
7313
7314         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
7315
7316 2002-03-28  Johan Knol  <johan AT balder>
7317
7318         * src/SDCCval.c: fixed bug #532436
7319
7320 2002-03-14  Scott Dattalo <scott AT dattalo.com>
7321         * /src/port.h:
7322         Added "char *Processor" field to the port structure.
7323
7324         * /src/SDCCmain.c:
7325         Added -p option. Allows port dependent processor to be specified.
7326
7327         * all ports:
7328         Initialized the new field char *Processor field to NULL in all ports
7329
7330         * /src/pic/*:
7331         Compiler generated registers for interrupt context saving
7332         were not getting allocated.
7333
7334 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
7335
7336         * /src/SDCCast.c:
7337         Fixed left shift. Will promote the left side of a left shift
7338         if a) left shifting more than size of operand or b) when assigned
7339         to something size > size of left side
7340
7341 2002-03-14  Scott Dattalo <scott AT dattalo.com>
7342         * src/pic/*
7343         tons of changes. Register allocation has been
7344         rewritten. Added customization for the various PICs. Flow
7345         analysis is restructured. ...
7346
7347         * src/pic/device.h:
7348         Added
7349
7350         * src/pic/device.c:
7351         Added. device.c is a PIC port hack to accomodate variations
7352         in PIC devices.
7353
7354 2002-03-13  Michael Hope  <michaelh AT vroom>
7355
7356         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
7357
7358 2002-03-04  johanknol  <johanknol AT manik>
7359
7360         * /src/SDCCval.c: fixed
7361
7362         const unsigned char arr[][2] = { { 0, 1 } };
7363         t18.c:1: error: Initializer element is not constant
7364
7365 2002-03-04  bela  <bela AT manik>
7366
7367         * /device/include/mcs51reg.h:
7368         ds89c420 register definition update
7369
7370 2002-03-03    <johan AT FRIJA>
7371
7372         * support/Util/SDCCerr.c: did something, but don't no why anymore
7373
7374         * support/regression/tests/bug-524691.c: made it a little less shy
7375
7376         * src/SDCCast.c (decorateType): fixed bug #524697
7377
7378         * src/SDCCast.c: made some lineno improvements
7379
7380         * src/SDCCval.c (getNelements): changed warning to error
7381
7382         * src/SDCCglue.c (printIvalArray): changed warning to error
7383
7384         * src/SDCCicode.c: fixed a warning for mingw
7385
7386         * src/SDCCast.c (decorateType): fixed the << promotion for ops
7387
7388         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
7389
7390 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
7391
7392         * src/ds390/peeph.def:
7393         Added some more peephole rules
7394
7395         * src/ds390/gen.c: Various fixes & enhancements
7396
7397         * src/SDCClrange.c, src/SDCClrange.h:
7398         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
7399
7400         * src/ds390/ralloc.c:
7401         various fixes & enhancements (ds390) specific
7402
7403         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
7404         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
7405         from rallocs.
7406
7407         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
7408
7409 2002-03-02    <johan AT FRIJA>
7410
7411         * src/SDCCast.c (decorateType): fixed bug #524708
7412
7413         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
7414
7415         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
7416
7417 2002-03-01  Michael Hope  <michaelh AT vroom>
7418
7419         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
7420
7421         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
7422
7423 2002-03-01    <johan AT FRIJA>
7424
7425         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
7426
7427         * src/SDCCast.c (decorateType): fixed bug #524209
7428
7429         * src/SDCCval.c (valNot): fixed bug #524195
7430
7431 2002-02-26    <johan AT balder>
7432
7433         * src/xa51/gen.c: fixed a warning
7434
7435         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
7436
7437         * src/SDCCast.c (decorateType): fixed bug #522534
7438
7439 2002-02-23    <johan AT balder>
7440
7441         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
7442
7443 2002-02-22    <johan AT balder>
7444
7445         * src/SDCCast.c: fixed bug #514865
7446
7447         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
7448
7449 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
7450
7451         * sdcc/src/SDCCloop.c:
7452         Previous fix was not good. basic blocks that have "break" or "return" are
7453         not really partof a loop , but live ranges used in these blocks should
7454         be live thru the entire loop, so set partOfLoop but don't add them to
7455         loop region
7456
7457 2002-02-21    <johan AT FRIJA>
7458
7459         * src/SDCCcse.c: fixed bug #514308
7460
7461 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
7462
7463         * src/SDCCloop.c:
7464         Fixed BUG #519583. If a conditional block ended in a return/break
7465         statement inside a loop, it was not being considered part of the loop.
7466
7467         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
7468
7469 2002-02-10  Karl Bongers <karl AT turbobit.com>
7470
7471         * debugger/*:
7472         Fixed up SDCDB debugger somewhat.  Updated debugger/README
7473         with lots of comments and notes.
7474
7475         * device/examples/test2.c:
7476         Fix bug, "red" variable not being initialized(compiler complained).
7477
7478         * device/examples/Makefile, examples/test3.c:
7479         Add Makefile in device/examples folder, compiles test3.c
7480         for use as a multiple module SDCDB test case.
7481
7482         * sim/ucsim/cmd.src/cmdset.cc:
7483         Took out debug printfs in ucsim "next" command.
7484
7485         * sim/ucsim/xa.src:
7486         Karl and Johan start ucsim XA support.  Most dissassembly working,
7487         about 75% emulation done(plenty of work remaining).
7488
7489         * sim/ucsim/z80.src:
7490         Add Z80 support to ucsim, add test-ucz80 regression test,
7491         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
7492         Notice z80 compiler fails on examples/test3.c/crc code.
7493
7494 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
7495
7496         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
7497         Added support for --parms-in-bank1
7498
7499         * src/ds390/peeph.def:
7500         added a few more peephole optimzations
7501
7502         * src/ds390/main.c:
7503         1) added __builtin_inp & __builtin_outp used to read in data of given length
7504            from a memory mapped port
7505         2) added __builtin_memcmp
7506         3) added __builtin_swapw swap bytes of a short
7507
7508         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
7509         1) handle multiple send & receives from register bank1
7510         2) ralloc can now allocate DPTR1 to some liveRanges
7511
7512         * src/SDCCsymt.c, src/SDCCsymt.h:
7513         changes to handle multiple sends & receives
7514
7515         * src/SDCCptropt.h:
7516         added some pointer arithmetic optimization
7517
7518         * src/SDCCptropt.c:
7519         added some pointer arithmetic optimizations but not stable yet so not
7520         called from anywhere (will get this working shortly)
7521
7522         * src/SDCCopt.c: fixed for multiple sends & receives
7523
7524         * src/SDCCmain.c:
7525         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
7526         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
7527            set preprocessor defines (depending on options)
7528
7529         * src/SDCCicode.c, src/SDCCicode.h:
7530         changes made to handle multiple sends & receives
7531
7532         * src/SDCCglobl.h:
7533         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
7534
7535         * src/SDCCcse.c, src/SDCCcse.h:
7536         added function findbackward def (to be used in upcoming optimization)
7537
7538         * src/SDCCcflow.c, src/SDCCcflow.h:
7539         added function returnAtEnd - to determine if a basic block terminates with
7540         a RETURN iCode
7541
7542         * src/SDCCast.c, src/SDCCast.h:
7543         added option parms-in-bank1
7544
7545         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
7546         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
7547         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
7548         adjusted for --parms-in-bank1 option
7549
7550         * device/include/string.h:
7551         donot redefine "reentrant" keyword
7552
7553         * device/include/ds80c390.h: Added some more SFRs
7554
7555 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
7556
7557         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
7558
7559 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
7560
7561         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
7562
7563 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
7564
7565         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
7566
7567 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
7568
7569         * Added --xram-movc option
7570
7571 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
7572
7573         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
7574
7575 2002-01-11  Johan Knol
7576
7577         * Added math lib of Jesus Calvino-Fraga
7578
7579 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
7580
7581         * src/SDCCmain.c (processFile): fix processing of ../../src.c
7582         * support/regression/Makefile: new target test-mcs51-stack-auto
7583         * support/regression/ports/mcs51-stack-auto/spec.mk: added
7584
7585 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
7586
7587         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
7588
7589 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
7590
7591         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
7592
7593 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
7594
7595         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
7596
7597         * src/SDCCglue.h: add definition for printIvalChar()
7598
7599 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
7600
7601         * src/SDCCast.c: fix #498138 by Johan
7602
7603         * src/SDCCglue.c: fix #498138 by Johan
7604
7605 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
7606
7607         * support/regression/Makefile: fix clean
7608
7609         * support/regression/ports/ds390/support.c: fix transmission of last character
7610
7611 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
7612
7613         * /sdcc/src/ds390/gen.c:
7614         a) improved computing address of stack variable
7615         b) took out some #if 0 code
7616         c) improved parmBytes adjustment
7617         d) improved genPlusIncr & genMinusIncr
7618         e) genCmp could generate bad code (when left assigned to DPTR)
7619         f) Fixed bug in hasInc
7620
7621         * /sdcc/src/ds390/ralloc.c:
7622         a) packRegsForSupport could mess up live information (Fixed)
7623         b) packRegsDPTRuse could be incorrect for left & right shift
7624
7625         * /sdcc/src/mcs51/ralloc.c:
7626         packRegsForSupport could mess up the live information (Fixed)
7627
7628         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
7629
7630         * /sdcc/src/SDCCast.c:
7631         can reverse a loop even if function call is present as long
7632         as the loop control variable is local & is not passed as parameter
7633
7634 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
7635
7636         * /sdcc/ChangeLog: *** empty log message ***
7637
7638         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
7639         More builtin function additions for TININative
7640
7641         * /sdcc/src/ds390/ralloc.c:
7642         Had broken the regression testsuite
7643
7644         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
7645
7646         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
7647         Added funcattr hasStackParms will be set for reentrant functions when there
7648         are paramteres on the stack, this helps in minimizing frame pointer generation
7649         typeFromStr can handle function pointers now
7650
7651         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
7652         *** empty log message ***
7653
7654 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
7655
7656         * /src/ds390/gen.c, /src/ds390/main.c:
7657         More builtin function additions for TININative
7658
7659         * /src/ds390/ralloc.c:
7660         Had broken the regression testsuite
7661
7662         * /src/SDCCast.c: Fixed a bug in dumptree
7663
7664         * /src/SDCCsymt.c, /src/SDCCsymt.h:
7665         Added funcattr hasStackParms will be set for reentrant functions when there
7666         are paramteres on the stack, this helps in minimizing frame pointer generation
7667         typeFromStr can handle function pointers now
7668
7669         * /doc/builtins.txt, /doc/TININative.txt:
7670         *** empty log message ***
7671
7672
7673 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
7674
7675         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
7676         ALPHA version for -mTININative
7677
7678         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
7679         updated to reflect changes in the port structure
7680
7681         * /src/port.h:
7682         added function do_assemble (similar to do_link) if non-null this function
7683         will be called to do assembly (-mTININative) requires a multi command
7684         assembly
7685         added function genAssemblerEnd will be called to generate assembler Epilogue
7686
7687         * /src/SDCCsymt.c:
7688         added _JavaNative to debug info printing
7689
7690         * /src/SDCCmain.c: added option --tini-libid
7691         added port->do_assemble function (-mTININative) has a multi command assemble
7692
7693         * /src/SDCCglue.c: Disabled "constExpr" check
7694         added port->genAssemblerEnd function
7695
7696         * /src/SDCCglobl.h: Added option --tini-libid value
7697
7698         * /src/SDCCast.h:
7699         tookout optimizeCompare from the header (has no external references)
7700
7701         * /src/SDCCast.c: made one more function "static"
7702
7703 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
7704
7705         * src/z80/mappings.i: Added z80asm support.
7706
7707         * src/z80/main.c: Added z80asm support on --asm=z80asm
7708
7709         * src/z80/gen.c: Fixed asm portability issues.
7710
7711         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
7712
7713         * src/SDCCglue.c (printExterns): Added global/extern split.
7714
7715 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
7716
7717         * support/regression/Makefile: added test for mcs51 model large
7718
7719         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
7720
7721         * support/regression/ports/gbz80/spec.mk: added -mgbz80
7722
7723 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
7724
7725         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
7726
7727 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
7728
7729         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
7730
7731         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
7732
7733 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
7734
7735         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
7736
7737         * support/regression/tests/simplefloat.c: Port to mcs51.
7738
7739 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
7740         * support/regression/tests/bug-485362.c: Added.
7741
7742         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
7743
7744         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
7745
7746         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
7747
7748         * src/z80/gen.c (aopDump): Added a dump function.
7749
7750 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
7751         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
7752
7753         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
7754
7755         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
7756
7757         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
7758
7759         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
7760
7761         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
7762
7763         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
7764
7765         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
7766
7767         * support/regression/ports/ds390/support.c: Use tinibios.
7768
7769         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
7770
7771 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
7772
7773         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
7774         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
7775
7776         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
7777
7778         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
7779
7780 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
7781
7782         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
7783
7784         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
7785         (packRegsForIYUse): Created and optimised.
7786
7787 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
7788
7789         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
7790 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
7791
7792         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
7793
7794         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
7795
7796         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
7797
7798 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
7799
7800         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
7801
7802         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
7803
7804 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
7805
7806         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
7807
7808         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
7809
7810         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
7811
7812 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
7813
7814         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
7815         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
7816         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
7817
7818         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
7819
7820         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
7821         (genNotFloat): Added.
7822         (genUminusFloat): Added.
7823
7824         * device/lib/z80/Makefile: Added floating pt stubs.
7825
7826         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
7827
7828         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
7829
7830         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
7831
7832 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
7833
7834         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
7835
7836         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
7837
7838         * sdcc/support/regression/Makefile: Add port ds390.
7839
7840         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
7841
7842         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
7843
7844         * sdcc/support/regression/ports/ds390/spec.mk: Added.
7845
7846         * sdcc/support/regression/ports/ds390/support.c: Added.
7847
7848         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
7849
7850         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
7851
7852         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
7853
7854 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
7855
7856         * device/include/malloc.h: Added z80 and gbz80 support.
7857
7858         * device/lib/gbz80/heap.s: Added.
7859
7860         * device/lib/z80/heap.s: Added.
7861
7862         * device/lib/malloc.c: Added z80 and gbz80 support.
7863
7864         * support/regression/tests/malloc.c (testMalloc): Added.
7865
7866         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
7867
7868         * support/regression/tests/bug-478094.c: Added.
7869
7870         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
7871
7872 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
7873
7874         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
7875
7876         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
7877
7878         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
7879
7880         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
7881
7882         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
7883
7884 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
7885
7886         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
7887
7888 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
7889
7890         * support/regression/tests/bug-477927.c: Added.
7891
7892         * src/z80/peeph.def: Added minor rules.
7893
7894         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
7895
7896         * src/z80/peeph.def: Added jump optimisation modification.
7897
7898 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
7899
7900         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
7901
7902 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
7903
7904         * support/regression/tests/funptrs.c: Added.
7905
7906 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
7907
7908         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
7909
7910 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
7911
7912         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
7913
7914         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
7915
7916         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
7917         (movLeft2ResultLong): Created.
7918
7919         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
7920         (joinPushes): Added.  Joins two char pushes into a word push.
7921
7922 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
7923
7924         * support/cpp2/Makefile.in (install): Added creation of dest dir.
7925
7926         * support/makebin/Makefile (install): Added creation of dest dir.
7927
7928 2001-10-24 Karl Bongers <karl AT turbobit.com>
7929
7930         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
7931
7932 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
7933
7934         * src/z80/ralloc.c: Turned off faulty pack for one use.
7935
7936         * src/z80/peeph-gbz80.def: Removed redundent restart options.
7937
7938         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
7939
7940 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
7941
7942         * support/regression/Makefile: Improved clean
7943
7944         * support/regression/ports/gbz80/spec.mk: Added clean
7945
7946         * support/regression/ports/host/spec.mk: Added clean
7947
7948         * support/regression/ports/z80/spec.mk: Added clean
7949
7950         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
7951
7952         * support/regression/ports/mcs51/timeout.c: little improvements
7953
7954 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
7955
7956         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
7957
7958         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
7959
7960         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
7961
7962 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
7963
7964         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
7965
7966         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
7967
7968 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
7969         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
7970
7971         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
7972
7973         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
7974
7975         * src/mcs51/main.c (_linkCmd): Added bin path to command.
7976
7977         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
7978
7979         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
7980
7981         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
7982
7983         * support/regression/tests/longor.c: Added.
7984
7985 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
7986
7987         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
7988
7989         * as/mcs51/aslink.h: define PATH_MAX
7990
7991         * as/mcs51/asm.h: define PATH_MAX
7992
7993         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
7994
7995         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
7996
7997         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
7998
7999         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
8000
8001         * src/SDCCglobl.h: define PATH_MAX
8002
8003         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
8004
8005         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
8006
8007 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
8008
8009         * src/z80/gen.c (gencjneshort): Fixed
8010
8011         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
8012
8013 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
8014
8015         * support/regression/tests/bug-469671.c: Added.
8016
8017         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
8018
8019 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
8020
8021         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
8022
8023         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
8024
8025 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
8026
8027         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
8028
8029         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
8030
8031         * src/device/lib/_mullong.c : removed hint: nooverlay bug
8032
8033         * src/device/lib/_divuint.c : removed hint: nooverlay bug
8034
8035         * src/device/lib/_divulong.c: removed hint: nooverlay bug
8036
8037         * src/device/lib/_moduint.c : removed hint: nooverlay bug
8038
8039         * src/device/lib/_modulong.c: removed hint: nooverlay bug
8040
8041 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
8042
8043         * 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.
8044
8045         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
8046
8047         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
8048
8049 2001-10-07    <johan AT FRIJA>
8050
8051         * device/lib/gets.c (gets): fixed the return value.
8052
8053 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
8054         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
8055
8056         * 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.
8057
8058         * 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.
8059
8060         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
8061
8062         * src/pic/gen.c: Removed Safe_strdup.
8063
8064         * configure.in: Added option to enable libgc support.
8065
8066         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
8067         (bitVectUnion): Optimised.
8068         (bitVectIntersect): Optimised.
8069         (bitVectBitsInCommon): Optimised.
8070         (bitVectCplAnd): Optimised.
8071
8072         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
8073
8074 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
8075
8076         * src/SDCCmain.c: distinguish between assembler debug and plain options
8077
8078         * src/avr/main.c:   remove standard assembler options
8079
8080         * src/ds390/main.c: remove standard assembler options
8081
8082         * src/mcs51/main.c: remove standard assembler options
8083
8084         * src/port.h: removed "PENDING" comment
8085
8086 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
8087
8088         * src/device/lib/_mulint.c  : new, with assember functions
8089
8090         * src/device/lib/_mullong.c : new, with assember functions
8091
8092         * src/device/lib/_divuint.c : with assember functions
8093
8094         * src/device/lib/_divsint.c : with assember functions
8095
8096         * src/device/lib/_divulong.c: with assember functions
8097
8098         * src/device/lib/_divslong.c: with assember functions
8099
8100         * src/device/lib/_moduint.c : with assember functions
8101
8102         * src/device/lib/_modsint.c : with assember functions
8103
8104         * src/device/lib/_modulong.c: with assember functions
8105
8106         * src/device/lib/_modslong.c: with assember functions
8107
8108         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
8109
8110         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
8111
8112         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
8113                                       replaced _mululong.c and _mulslong.c by _mullong.c
8114
8115 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
8116
8117         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
8118
8119 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
8120
8121         * src/SDCCglue.c: test, if win32api is available for MINGW
8122
8123 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
8124
8125         * src/SDCCsymt.c: no more _modifier in printTypeChain()
8126         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
8127         * support/regression/ports/gbz80/spec.mk: removed GENERIC
8128         * support/regression/ports/host/spec.mk: removed GENERIC
8129         * support/regression/ports/mcs51/spec.mk: removed GENERIC
8130         * support/regression/ports/z80/spec.mk: removed GENERIC
8131
8132 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
8133
8134         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
8135
8136         * support/regression/tests/bug-467035.c: Created.
8137
8138 2001-10-01    <johan AT FRIJA>
8139
8140         * src/SDCC.y: fixed bug #466586 part 1
8141
8142 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
8143
8144         * SDCCicode.c: z80 has no generic pointers
8145         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
8146
8147 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
8148
8149         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
8150
8151 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
8152
8153         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
8154
8155         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
8156
8157 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
8158
8159         * configure.in: Fixed up so that ucsim is only configured once.
8160
8161         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
8162
8163         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
8164         (getPathDifference): As above.
8165
8166         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
8167
8168         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
8169
8170 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
8171         * .version: Updated to 2.3.1
8172
8173         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
8174         Added copyright header.
8175
8176         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
8177         (assemble): Added support for macro based assembler commands.
8178         (linkEdit): Added support for macro based linker commands.
8179         (preProcess): Changed the pre-processor to use macros.
8180         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
8181         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
8182
8183         * device/lib/z80/crt0.s: Added module name for debugging.
8184
8185 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
8186
8187         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
8188
8189         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
8190
8191         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
8192
8193         * src/Makefile.in: Added SDCCmacro and SDCCutil
8194
8195 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
8196
8197         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
8198
8199 2001-09-16    <johan AT FRIJA>
8200
8201         * 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.
8202
8203 2001-09-15    <johan AT FRIJA>
8204
8205         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
8206         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
8207
8208 2001-09-11    <johan AT FRIJA>
8209
8210         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
8211
8212 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
8213
8214         * support/regression/tests/bug-460444.c: Added test case.
8215
8216         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
8217         (genCast): Added justification for all of the asserts.
8218
8219 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
8220
8221         * support/regression/support.c: _xdata replaced by xdata
8222
8223         * support/regression/spec.mk: removed _generic
8224
8225 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
8226
8227         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
8228
8229         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
8230         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
8231
8232         * src/z80/peeph.def: Added a rule to optimise shift then compare.
8233
8234         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
8235
8236         * support/regression/tests/bug-460010.c: Added test case.
8237
8238         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
8239
8240 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
8241
8242         * support/regression/Makefile: inter-port-clean adjusted for mcs51
8243
8244         * support/regression/testfwk.c: removed workaround for bug #436344
8245
8246         * support/regression/tests/bp.c: use less memory with mcs51
8247
8248         * support/regression/tests/bug-441448.c: use less memory
8249
8250         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
8251
8252         * support/regression/collate-results.py: typo
8253
8254 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
8255
8256         * support/regression/tests/fetchoverlap.c: Added new test case.
8257
8258         * support/regression/tests/bp.c: Added new test case.
8259
8260         * support/regression/tests/bug-448984.c: Added new test case.
8261
8262         * support/regression/tests/pow2shifts.c: Added new test case.
8263
8264         * src/z80/gen.c: Turned off the noise it normally generates for the release.
8265         (genlshTwo): Fixed right shift for count > 8.
8266
8267         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
8268
8269 2001-09-08    <johan AT FRIJA>
8270
8271         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
8272
8273 2001-09-07    <johan AT FRIJA>
8274
8275         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
8276
8277         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
8278
8279 2001-09-06    <johan AT FRIJA>
8280
8281         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
8282         * bernhard noted me at this: "() equals to (void)" (1.38)
8283
8284 2001-09-05    <johan AT FRIJA>
8285
8286         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
8287
8288 2001-09-04    <johan AT FRIJA>
8289
8290         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
8291
8292
8293 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
8294
8295         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
8296
8297 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
8298
8299         * link/z80/aslink.h: Fixed path for PATH_MAX
8300
8301 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
8302
8303         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
8304
8305         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
8306
8307         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
8308
8309         * 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.
8310
8311 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
8312
8313         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
8314         (genCmp): Fixed up genCmp for the GB with longs.
8315
8316         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
8317
8318         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
8319
8320         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
8321
8322         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
8323
8324 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
8325
8326         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
8327
8328 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
8329
8330         * 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.
8331
8332         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
8333
8334 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
8335
8336         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
8337
8338         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
8339
8340 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
8341
8342   * sim/ucsim/configure:    little improvement of Cygwin-detection
8343   * sim/ucsim/configure.in: little improvement of Cygwin-detection
8344   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
8345   * support/regression/tests/bug-221100.c: small changes for mcs51
8346   * support/regression/tests/bug-221168.c: small changes for mcs51
8347   * support/regression/tests/bug-227710.c: small changes for mcs51
8348   * support/regression/tests/staticinit.c: small changes for mcs51
8349   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
8350   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
8351   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
8352
8353 $Revision$