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