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