1 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3 * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
4 (the missing "if"s prohibited removal of redundant labels)
6 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8 * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
9 Properly convert floats between -1.0 and 0.0 to long, int, and char
10 types (max integer value of negative floats tends to zero).
11 * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
12 Removed changes made so to work properly with floats between
13 -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
16 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
18 * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
19 * src/mcs51/gen.c (genUnpackBits): better code and a fix,
20 (genCast) cosmetic change
21 * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
22 * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
24 * support/regression/tests/bitfields (testSignedBitfields): added
26 2005-11-18 Borut Razem <borut.razem AT siol.net>
28 * sdcc/device/lib/Makefile.in: remove all unnecessary files
29 * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
30 introduced SILENT option to make building of pic16 libraries less
32 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
34 * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
35 Now they work properly with floats between -1.0 and 0.0
36 * device/lib/printf_large.c: Removed temporary patch for bug 1358192
38 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
40 * src/SDCCicode.c (printOperand): added missing else
42 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
44 * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
45 reformatted for better readability
46 * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
49 2005-11-17 Borut Razem <borut.razem AT siol.net>
51 * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
52 introduced SILENT option to make building of pic16 libraries less
53 verbose - used for nightly snapshot build
54 * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
55 available on Win32 platforms.
56 * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
57 medium, large, pic and pic16
59 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
61 * device/lib/printf_large.c: Temporary patch for bug 1358192:
62 printf("%f"...) sets fraction to zero.
64 2005-11-16 Raphael Neider <rneider AT web.de>
66 * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
68 * src/pic/gen.c (genIfx): implemented for CARRY bit
69 * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
70 to generic pointers, fixes #1357332,
71 (pic16_movLit2f): NEW,
72 (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
74 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
76 * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
78 2005-11-11 Raphael Neider <rneider AT web.de>
80 * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
81 * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
82 compute pointer's type from operand,
83 (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
84 improved single bit reads, fixes bug #1353379
86 2005-11-09 Borut Razem <borut.razem AT siol.net>
88 * support/scripts/sdcc.nsi: added lib/pic to the package
90 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
92 * src/SDCCval.c (valUnaryPM): fixed bug 1350699
94 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
96 * support/regression/tests/bug1348008.c: added
97 * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
98 * support/regression/tests/bug1337835.c: updated comment
100 2005-11-06 Borut Razem <borut.razem AT siol.net>
102 * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
103 sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
104 sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
105 sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
106 sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
107 dynamic construction of cl_error_class and derivates - 2.nd try
109 2005-11-05 Borut Razem <borut.razem AT siol.net>
111 * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
112 bug, which caused Bus Errors on sparc solaris
114 2005-11-04 Borut Razem <borut.razem AT siol.net>
116 * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
117 sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
118 sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
119 sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
120 sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
121 and derivates to resolve the initialization problem on OSX
123 2005-11-02 Borut Razem <borut.razem AT siol.net>
125 * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
126 corrected typo - #include <winsock2.h>
128 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
130 * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
131 (_asxxxx_mapping): added org directive for future enhancements
133 2005-11-01 Borut Razem <borut.razem AT siol.net>
135 * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
136 enabled sockets on WIN32
137 * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
139 2005-10-31 Borut Razem <borut.razem AT siol.net>
141 * support/regression/generate-cases.py: escape backslashes in {testcase}:
142 WIN32 backslash path delimiters should be escaped when used in C strings
143 * support/regression/tests/bitfields.c: exclude failing assertions for
144 __CYGWIN32__ and __MINGW32__ hosts
146 2005-10-30 Borut Razem <borut.razem AT siol.net>
148 * src/SDCCutil.c: corrected double comparison typo
150 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
152 * device/lib/medium/Makefile: added for new memory model medium
153 * device/include/asm/mcs51/features.h: updated for medium/pdata
154 * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
155 added Multiply & Accumulate sbit's and MAC0_PAGE define
156 * device/include/mcs51/c8051f300.h: added sfr16 definitions
157 * device/include/mcs51/c8051f310.h: added sfr16 definitions
158 * device/lib/_mullong.c: update for medium model
159 * device/lib/incl.mk: added medium model
160 * doc/sdccman.lyx: documented medium model
161 * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
162 * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
163 * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
164 * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
165 (allocParms): set SCLS and OCLS to pdata for medium model
166 * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
168 (powof2): return <0 if not power of 2
169 * src/avr/gen.c (genBitWise): use updated powof2
170 * src/mcs51/gen.c (genMinusDec): use acc if necessary,
171 (shiftR2Left2Result): small optimization in setup, save acc when storing,
172 (shiftLLeftOrResult): use B if necessary
173 * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
174 * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
175 * src/pic/main.c (_pic14_do_link): made void parameter list explicit
176 * support/regression/Makefile.in: added test-mcs51-medium
177 * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
179 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
181 * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
183 * device/lib/time.c (mktime): fixed bug 1334315
185 2005-10-28 Raphael Neider <rneider AT web.de>
187 * device/include/pic/p16f_common.inc: added common declarations
188 * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
190 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
192 * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
193 (aopPutUsesAcc): added to predict accumulator use,
194 (assignResultValue): save acc if necessary,
195 (genMinusDec): store result if indirectly addressed,
196 (genDivOneByte): save acc if necessary,
197 (movLeft2Result): bugfix if left already in acc,
198 (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
199 attention to accumulator use (esp. pdata),
200 (genReceive): receive pdata correctly
201 * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
202 * src/SDCCicode.h: added isOperandInPagedSpace prototype
204 2005-10-27 Raphael Neider <rneider AT web.de>
206 * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
208 2005-10-27 Raphael Neider <rneider AT web.de>
210 * .version: changed version to 2.5.4
211 * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
212 * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
213 (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
214 arithmetics support routines
215 * device/lib/pic/Makefile.rules: have assembler sources preprocessed
216 * device/lib/Makefile.in: also create installdir for pic
218 * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
220 * src/pic/device.c (dump_sfr): rewritten to delegate register
221 placement to the linker (use `extern sym' rather than sym EQU addr),
222 (validAddress): fixed to check last specified address
223 * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
224 (popGetLit): truncate literal value to 8 bit,
225 (popGet): moved assert to more appropriate place
226 (popGetExternal): create pCode operand from and mark the according
227 symbol as being `extern'
228 (popGetAddr): added sanity check on immediate's offset, provide
229 GPOINTER tag on demand
230 (aopPut): fixed for immediates,
231 (mov2w_op): move operand's address or contents to WREG (depending on
232 operand type), safer variant of mov2w,
233 (movwf,call_libraryfunc): NEW, handy abbreviations,
234 (get_argument_pcop,get_return_val_pcop,pass_argument,
235 get_returnvalue): interface for accessing function parameters and
237 (assignResultValuei,genRet): use new parameter/return value interface
238 (pic14_getDataSize): back to old version handling generic pointers,
239 (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
240 provided implementation and/or fixed old one,
241 (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
242 calls, removed legacy 8051 reference code
243 (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
244 (loadSignToC): NEW, move the operands sign bit to CARRY,
245 (genGenericShift): NEW, replaces genLeftShift, genRightShift and
246 genRightShiftSigned, accepts negative shift counts,
247 (setup_fsr): load FSR and adjust IRP (indirect memory access),
248 (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
249 generic pointers, __data pointers and __code pointers,
250 (genUnpackBits,genPackBits): rewritten to work with generic pointers
251 and signed bitfields, limit bitfields to 8 bit,
252 (genDataPointerGet): fixed number of bytes read,
253 (genGenPointerGet,genConstPointerGet): fixed bitfield access,
254 (genPointerGet,genPointerSet): fixed handling of __code pointers,
255 pointers to constant data are no longer assumed to point to __code
256 space, removed invalid pointer types,
257 (bitpatternFromVal): retrieve the PICs representation of an integer
259 (genDataPointerSet): fixed assigning to po_immediate operands,
260 (genGenPointerSet): implemented as library call,
261 (genIfx): fixed incorrect condition,
262 (genAddrOf): limit generic pointers' addresses to 2 bytes,
263 provide GPOINTER tag according to destination's storage class,
264 (genCast): added code to handle casting to generic pointers, added
265 sign-/zero extension of the result
266 (aop_isLitLike,op_isLitLike): fixed handling of immediates
267 * src/pic/gen.h: added macros to access IRP bit in STATUS register
268 * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
270 * src/pic/glue.c (is_shared_address,is_shared): check whether a given
271 address/register resides in the shared banks
272 (emitSymbolToFile): improved to handle global and `pinned' symbols,
273 put all variables into separate sections (have the linker arrange
275 (picglue): put init code and interrupt handlers in separate sections
276 * src/pic/main.c: added port specific options table, modified to PORT
277 structure to make GPOINTERs 3 byte, added pic14_options
278 (_pic14_do_link): private linking routine (update paths to libraries,
279 add libsdcc.lib by default)
280 * src/pic/main.h: declare pic14_options
281 * src/pic/pcode.c: fixed instructions i/o relations,
282 (RegCond): reverted to correct version,
283 (newpCodeOpLit): truncate literals to 8 bit,
284 (genericPrint): added debug output,
285 (getRegFromInstruction): fixed for various operand types, simplified
286 (BuildFlow): fixed broken handling of isntructions with labels
287 (LinkFlow): start at last instruction in flow (skip trailing comments),
288 pass the flow on to the next instruction after CALL
289 (pCodeReplace): NEW, replace a pCode and move meta data to the new one
290 (insertPCodeInstruction): fixed inserting after a skip instruction,
291 (DoBankSelect): fixed for labeled instructions
292 (OptimizepBlock): honor --nopeep switch
293 (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
294 * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
295 * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
296 (pCodeOptime2pCodes): allow disabling this optimization via
297 --no-pcode-opt due seldomly occuring bugs, fixed some conditions
298 but is still buggy), started implementation of a dataflow based
299 pCode optimization (CSE + dead code elimination)
300 (pCodeRegMapLiveRangesInFlow): removed bogus inCond
301 * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
302 names are independant of the stack location and therefore portable across
305 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
307 * src/mcs51/ralloc.c (bitType): added to detect bit variables,
308 (selectSpil): fixed bug 1337835 by not spilling bit variables
309 * support/regression/tests/bug1337835.c: added test for this bug
310 * src/mcs51/peeph.def: restart after rule 3.c,
311 addded rules 263.x to optimize loading constants
313 2005-10-26 Raphael Neider <rneider AT web.de>
315 * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
316 * src/pic16/gen.c (genUnpackBits): support signed bitfields,
317 (genAssign): emit warning when casting literals to generic pointer
318 type, also applies when taking the address of a fixed variable,
319 (genCast): improved casting to generic pointers
320 * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
321 extern variables, added verbose error message
322 * device/include/pic16/{string.h,errno.h}: added #pragma library c
324 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
326 * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
327 carry must be complemented too
328 * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
329 could be emitted by genMinus
330 * src/SDCCval.c (constVal): fixed bug 1305065
332 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
334 * src/SDCCast.c (addCast): added promotion for bit variables
335 (decorateType): emit W_COMPLEMENT before the problem vanishes behind
336 promotion casts + optimisation
337 (optimizeGetWord): fix warning 'i' might be used uninitialized
338 * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
339 * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
341 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
343 * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
344 all chars are promoted to int; promotion should be handled in SDCCast.c
346 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
348 * device/lib/_strcmp.c: Fixed bug 1326457
350 2005-10-11 Raphael Neider <rneider AT web.de>
352 * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
353 * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
355 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
357 * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
358 * support/regression/tests/sfr16.c: added test for the sfr32 bug
360 2005-10-04 Raphael Neider <rneider AT web.de>
362 * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
363 device/lib/pic16/pics.all: added pic18f1320
364 * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
366 2005-09-30 Raphael Neider <rneider AT web.de>
368 * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
369 * src/pic16/devices.inc: NEW, provides device descriptions
370 * src/pic16/gen.c (genInline): fixed handling of ';'-comments
372 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
374 * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
377 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
379 * doc/sdccman.lyx: updated Highest Order Bit documentation,
380 documented Any Order Bit, Higher Order Byte and Higher Order Word
381 * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
382 * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
383 (optimizeGetAbit): new, to get any bit, not only the high bit,
384 (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
385 (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
386 (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
387 (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
388 RIGHT_OP: also try GETBYTE, GETWORD optimization,
389 GETABIT, GETBYTE, GETWORD: decorate them,
390 (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
391 (ast_print): added GETABIT, GETBYTE, GETWORD
392 * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
393 * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
394 (geniCodeBinary): new generic binary icode,
395 (ast2iCode): added GETABIT, GETBYTE, GETWORD
396 * src/port.h: updated comment for PORT.hasExtBitOp
397 * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
398 (genGetByte): new, to get a single byte,
399 (genGetWord): new, to get a word from a long,
400 (gen51Code): added GETABIT, GETBYTE, GETWORD
401 * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
403 2005-09-23 Raphael Neider <rneider AT web.de>
405 * configure.in, configure: have device/lib/pic configured
406 * device/lib/Makefile.in: added model-pic14
407 * device/lib/clean.mk: added pic/ to clean rule
408 * device/lib/pic: added rudimentary pic14 library providing support
409 functions for multiplication/division/generic pointer access
410 * src/SDCCopt.c (convilong): mark support functions as extern
411 for pic14 port as well
412 * src/pic/gen.c (genMult): added assertions,
413 (genpic14Code): emit warning on unhandled iCodes
414 * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
415 * src/pic/pcode.c (pCodeOpCopy),
416 * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
417 pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
418 SFR_REGISTER}), made safe for future extensions
419 * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
420 instructions even if preceeded by SKIP instructions (also remove
421 them); removed unused code
422 * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
423 prevents leaving parts of the structure uninitialized after copying
425 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
427 * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
429 * support/regression/tests/addsub.c: added test for the bug
431 2005-09-21 Raphael Neider <rneider AT web.de>
433 * device/include/pic16/pic18f1220.h,
434 device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
435 * device/lib/pic16/Makefile.rules: added missing opening paren
436 * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
437 are provided in genutils.c,
438 (genUminusFloat,genUminus,genCmpEq): added asserts on different
439 operand/result sizes,
440 (genCmp): assert on NULL pointers first, then check deref'ed values
441 * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
444 2005-09-18 Raphael Neider <rneider AT web.de>
446 * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
447 as these are now unused,
448 (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
449 * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
450 local, avoids uninitialized pointer dereference on r->name
451 * src/pic16/ralloc.c (newReg): fixed indentation
453 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
455 * src/SDCCval.c (constVal): fixed bug 730366
456 * support/Util/SDCCerr.c,
457 * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
459 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
461 * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
463 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
465 * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
467 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
469 * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
470 (hex2dec): made hex_digit unsigned char, removed ascii dependance
471 * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
472 (hex2dec): made hex_digit unsigned char, removed ascii dependance
473 * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
474 * packihx/packihx.c (hexDigit): made c unsigned char
475 * as/mcs51/lklibr.c (fndsym),
476 * link/z80/lkgb.c (gb),
477 * link/z80/lklibr.c (fndsym),
478 * link/z80/lkrloc.c (relr),
479 * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
480 * src/SDCC.lex (checkCurrFile, process_pragma),
481 * src/SDCCglue.c (spacesToUnderscores),
482 * src/SDCCmain.c (setParseWithComma, processFile),
483 * src/asm.c (tvsprintf, printCLine),
484 * src/avr/gen.c (emitcode, aopPut),
485 * src/ds390/gen.c (emitcode),
486 * src/hc08/gen.c (emitcode, emitinline),
487 * src/mcs51/gen.c (emitcode, genInline),
488 * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
490 * src/pic/ralloc.c (debugLog),
491 * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
493 * src/pic16/ralloc.c (debugLog),
494 * src/z80/main.c (_process_pragma):
495 made all ctype.h function calls safe
496 * src/SDCCopt.c: include math.h for fabs
497 * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
498 and used them throughout the code to make ctype.h function calls safe
499 * src/ds390/main.c (asmLineNodeFromLineNode),
500 * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
501 * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
503 * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
504 (newpCodeAsmDir): made ctype.h function calls safe
505 * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
506 pic16_emitcode): made lbp unsigned char*
507 * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
508 (pic16_newpCodeAsmDir): made ctype.h function calls safe
509 * src/xa51/gen.c (emitcode),
510 * src/z80/gen.c (_emit2): made lbp unsigned char*
511 * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
514 2005-09-05 Raphael Neider <rneider AT web.de>
516 * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
517 access bank splitpoint
519 2005-09-05 Raphael Neider <rneider AT web.de>
521 * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
523 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
525 * .version: changed to version 2.5.3
526 * doc/sdccman.lyx: changed version to 2.5.3,
527 documented --codeseg and --constseg and pragma codeseg and constseg,
528 documented bit parameters (reentrant) and bit returning
529 * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
530 currFunc->recvSize, but is this ok for all ports?
531 (ast2iCode): result of ~ on unsigned char must be cast to int for
533 * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
534 function pointers in bit space
535 * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
536 (processFuncArgs): call port.reg_parm() with reentrancy info
544 * src/z80/main.c: port.reg_parm prototype extended with
545 "bool reentrant" parameter
546 * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
547 options.stackAuto for allocating bit register parameters
548 * src/mcs51/gen.c (genNot): optimized complementing direct bit,
549 (genSend): set BitBankUsed if it is,
550 (selectRegBank): factored out of genCall for use in genPcall,
551 (genCall): removed redundant dtype assignmen, use selectRegBank,
552 (genPcall): handle returning in Carry properly, save in F0 if needed,
553 (genReceive): handle bit register parameters
554 * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
555 (mcs51_assignRegisters): enable bit registers for all reentrant
556 functions and don't set BitBankUsed unconditionally
557 * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
558 * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
559 * support/regression/tests/funptrs.c: added tests for BOOL and for return
561 2005-08-27 Borut Razem <borut.razem AT siol.net>
563 * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
564 ppc-osx (Darwin) does not support -u option. It seems that it is
565 supported only on Linux - GNU cp
567 2005-08-25 Borut Razem <borut.razem AT siol.net>
569 * sim/ucsim/gui.src/serio.src/Makefile.in,
570 sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
571 sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
572 sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
573 install and strip, since the strip at /usr/ccs/bin should be used
576 2005-08-24 Borut Razem <borut.razem AT siol.net>
578 * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
580 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
582 * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
585 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
587 * as/mcs51/aslink.h: completed lkrloc.c prototypes
588 * as/mcs51/lkmain.c (link_main): fixed warning
589 * device/include/stdbool.h: ds390 has no advanced bit support yet
590 * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
591 * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
592 * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
593 and updated their macros
594 * src/SDCCval.c (constVal): updated comment for renamed b_long
596 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
598 * as/mcs51/asdata.c: changed ctype['['] to BINOP
599 * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
600 (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
601 (oprio): set priority for '['
602 * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
604 * as/mcs51/asm.h: added defines R_BIT and S_BIT
605 * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
606 * as/mcs51/lkdata.c: changed ctype['['] to BINOP
607 * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
608 added overlayable BIT_BANK area
609 * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
610 (summary2): explain 'T' in legenda
611 * as/mcs51/lkrloc.c: replaced old K&R style,
612 (relr): added R_BIT processing,
613 (errmsg): added "Bit-addressable relocation error",
614 (adb_bit): added for converting from byte- to bit-addressable space,
615 (adb_24_bit): added for converting from byte- to bit-addressable space
616 * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
617 used in reentrant functions now even as return value
618 * device/lib/_gptrput.c (_gptrput): removed obsolete code
619 * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
620 (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
621 * src/SDCCglobl.h: added indicator BitBankUsed
622 * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
623 the bit registers b0-b7
624 * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
625 (geniCodeCast): fixed bug 1263853,
626 (geniCodeLogicAndOr): put result in bool or char,
627 (geniCodeReceive): added parameter func for accessing the return type,
628 (geniCodeFunctionBody): pass func to geniCodeReceive
629 * src/SDCCmain.c: added indicator BitBankUsed
630 * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
631 * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
632 (checkSClass): don't put automatic bool/bit on stack,
633 (checkFunction): removed check on function cannot return bit
634 * src/SDCCsymt.h: added newBoolLink prototype
635 * src/mcs51/gen.c (rb1regs): added bit registers,
636 (movc): created for assigning to carry,
637 (pushReg, popReg): created for pushing registers,
638 (sameRegs): check both AOP_REG and AOP_CRY types,
639 (aopOp): handle bit registers,
640 (aopPut): optimization no self-assign,
641 (saveRegisters): push reg->base (bits) only once for bit registers,
643 (unsaveRegisters): pop reg->base only once and use popReg,
644 (assignResultValue): added parameter func and return in carry for bits,
645 (genIpush): optimization no reload in A if not changed,
646 (genSend): bit parameters in reentrant functions are passed in bit
647 registers by first assigning to bits in B, then save registers and
649 (genCall): handle returning in Carry properly, save it in F0 if needed,
650 (genPcall): updated assignResultValue call, this is not safe yet for bit
651 returning function !!!
652 (genFunction): don't generate equ's for bit registers and use pushReg,
653 (genEndFunction): take care of bit returning functions and use popReg,
654 (genRet): return bit in Carry,
655 (genIfx): optimize bit registers and other directly addressable bits,
656 (genReceive): updated assignResultValue call
657 * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
658 (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
659 registers when using stack-auto
660 * src/mcs51/ralloc.c (_G): added allBitregs,
661 (regs8051): added the bit registers,
662 (createStackSpil): use macro IS_BIT,
663 (getRegBit): added to allocate a bit register, else spill,
664 (getRegBitNoSpil): added to allocate a bit register, else a gpr,
665 (updateRegUsage): factored out to ease stepping while debugging,
666 (serialRegAssign): use updateRegUsage, only spill bits if necessary,
667 also allocate bit registers,
668 (fillGaps): handle bit registers,
669 (findAllBitregs): added to create bit vector with all bit registers,
670 (mcs51_allBitregs): returns this bit vector,
671 (mcs51_assignRegisters): when using stack-auto use bit registers for
672 passing parameters and creating local variables
673 * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
675 2005-08-22 Borut Razem <borut.razem AT siol.net>
677 * device/lib/Makefile.in: replaced find option -or with -o
678 to make it run on solaris
680 2005-08-22 Raphael Neider <rneider AT web.de>
682 * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
683 fixes #1265442 (crash on Solaris)
685 2005-08-20 Borut Razem <borut.razem AT siol.net>
687 * configure, configure.in: added tests for libsocket and libnsl libraries,
688 requred by sdcdb on sparc-solaris; generate support/regression/Makefile
689 from support/regression/Makefile.in
690 * support/regression/Makefile.in: added
691 * device/lib/pic16/Makefile.common.in: force make to use bash shell
692 * sim/ucsim/libtool: regenerated on sparc-solaris
693 * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
694 sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
695 sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
696 -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
697 sparc-solaris, which doesn't use GNU ld linker
698 * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
699 * as/Makefile: find on sparc-solaris does not support -maxdepth option
701 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
703 * src/mcs51/peeph.def: updated comments
705 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
707 * device/lib/_gptrget.c,
708 * device/lib/_gptrput.c: slightly shorter
709 * doc/sdccman.lyx: incremented version
710 * src/mcs51/peeph.def: moved peephole comments to the line of first
711 change to better keep line correlation, reanimated 186.e
712 * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
714 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
716 * src/pic/pcode.c : Pasted ".line" assembly directives patch from
717 David Saxton with quotes around file name.
719 2005-08-15 Borut Razem <borut.razem AT siol.net>
721 * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
722 support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
723 support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
724 make tests run on x86_64 platform
726 2005-08-13 Raphael Neider <rneider AT web.de>
728 * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
729 as it might be executed DURING a build (parallel make is wonderful)
731 2005-08-13 Raphael Neider <rneider AT web.de>
733 * device/lib/Makefile.in (port-specific-objects-pic16):
734 revert to cp $(PORT)/bin/*.* $(PORTDIR)
735 * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
737 * device/lib/pic16/Makefile.rules: build subdirs before creating
738 the library, removed builddir rule, create $(builddir) early in
739 recurse rule, use empty recurse rule for leaf directories
740 * device/lib/pic16/Makefile.subdir: added phony targets, ignore
741 mkdir errors (race condition), removed duplicate suffix "hex"
743 * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
744 * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
745 prevents mkdir -p from aborting on Alpha
747 2005-08-12 Raphael Neider <rneider AT web.de>
749 * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
750 db-statements in order to allow for arrays of pointers in code
751 sections to be placed without interspersed 0-padding, fixes
753 * (emitStatistics): fixed division by zero for pic18f1220
754 * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
755 unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
756 * (pic16_emitDS): respect DB_ITEMS_PER_LINE
757 * (pic16_pCodeConstString): keep track of already emitted string
758 literals to prevent "duplicate definitions of symbol _str_NR"
759 * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
761 * device/lib/Makefile.in: ignore failing PIC16 library builds
762 * device/lib/pic16/Makefile: do not build if gputils are missing
763 * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
765 2005-08-10 Raphael Neider <rneider AT web.de>
767 * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
770 2005-08-10 Raphael Neider <rneider AT web.de>
772 * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
773 Rokas' patch to add the new fixed point type "__fixed16x16"
774 * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
775 functions for __fixed16x16 arithmetics
776 * device/lib/pic16: reimplemented the build system to support
777 a separate build directory, better handling of libio (create
778 the library in a separate subdir for each architecture) and
779 easier configuration (centralized in Makefile.common)
781 2005-08-07 Raphael Neider <rneider AT web.de>
783 * src/pic16/gen.c (genrshTwo): fixed sign extension
784 * src/pic16/device.c: added pic18f2320, 4220 and 4320
785 * device/include/pic16/pic18f2220.h: changed some bit definitions,
787 * device/include/pic16/pic18f4220.h: NEW, header for
788 pic18f4220 and pic18f4320
789 * device/include/pic16/pic18fregs.h: added new devices,
790 embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
791 * device/include/pic16/signal.h: resolved name clashes
792 on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
793 to also allow testing for interrupt enable bits, added
794 comments on how to use the macros
795 * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
796 * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
797 register definitions for the devices
798 * device/lib/pic16/pics.all: added new devices
799 * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
801 * device/lib/pic16/libc/stdlib/memfree: do not count
802 the block header as free memory
803 * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
804 simplified and added missing end-of-blocklist-marker
805 (reported by Peter Onion, fixes #1252814)
806 * (_mergeHeapBlock): fixed loop condition
807 * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
808 len==0, restructured code
809 * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
810 up a bit, reduced bitfield accesses, prevent endless loops
811 in case of heap corruption
812 * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
813 "unreferenced arguments/must return a value" warnings
814 * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
815 replaced BAUDREG with SPBRG
816 * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
817 device/lib/pic16/debug/gstack/gstack.c: replaced
818 _naked, _asm, _endasm with __naked, __asm, __endasm
820 2005-08-05 Raphael Neider <rneider AT web.de>
822 * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
823 AOP_PCODE operands, fixes multibyte union-bitfield-accesses
825 2005-08-05 Borut Razem <borut.razem AT siol.net>
827 * device/lib/Makefile.in: added missing ';'
828 * configure: removed ^M characters
830 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
832 * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
833 device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
836 2005-08-04 Borut Razem <borut.razem AT siol.net>
838 * configure.in: pic16 libraries build 2nd try - enable running
839 configure in device/lib/pic16
840 * configure: regenerated from configure.in
841 * device/lib/Makefile.in: create $(PORT)/bin directory
843 2005-08-03 Raphael Neider <rneider AT web.de>
845 * src/pic16/gen.c (pic16_derefPtr): NEW, single place
846 to get/set values via pointers
847 * (genUnpackBits,genPackBits): changed detection of
848 ptr->bitfield vs. sym.bitfield, fixed access via generic
849 pointers, removed dead (wrong) code for multibyte bitfields
850 * (genNearPointerGet, genGenPointerGet): removed useless code,
851 fixed bitfield detection, fixes #1250594
852 * (genNearPointerSet): removed useless code
853 * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
854 and introduced macro pic16_emitpcode that conditionally emits
855 the origin of the following pCode (useful for debugging SDCC)
856 * src/pic16/pcode.c: changed (and disabled) some debug outputs
857 * (createDefmap): fixed handling of LFSR for --optimize-df
859 2005-08-02 Borut Razem <borut.razem AT siol.net>
861 * device/lib/Makefile.in: pic16 libraries build enabled since
862 gputils-0.13.2 are now localy installed at sourceforge's compile farm
864 2005-08-02 Raphael Neider <rneider AT web.de>
866 * src/pic16/gen.c (genPackBits): removed deprecated warning
867 * (genGenPointerSet): fixed bitfield detection
869 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
871 * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
873 2005-07-31 Raphael Neider <rneider AT web.de>
875 * device/lib/pic16/libdev/pic18f458.c,
876 device/include/pic16/pic18f458.h: added missing T0CONbits
878 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
880 * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
882 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
884 * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
886 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
888 * device/include/mcs51/at89c51ed2.h: added.
890 2005-07-23 Raphael Neider <rneider AT web.de>
892 * src/pic/gen.h: added emitpcode macro for debugging
893 * src/pic/gen.c (emitpcode): renamed to emitpcode_real
894 and replace by macro adding debug information on demand
895 * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
896 * (gencjne): tried to fix; replaced with correct (slower) code
897 * (gen{Unp,P}ackBits): fixed single bit access
898 * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
899 * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
901 * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
902 register has to be handled with care (forbidding movement
903 of assignments/uses, removing assignments completely, ...)
904 * (pCodeOptime2pCodes): make use of regIsSpecial
905 * added lots of debugging output (commented out)
906 * src/pic/rallloc.c (deassignLRs): prevent operand registers
907 from being reused as result UNLESS it is known to work
909 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
911 * support/Util/dbuf.h: include <stddef.h> for size_t
912 * .version: changed to version 2.5.2
914 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
916 * src/SDCCloop.c (loopInvariants): fixed bug #1234048
918 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
920 * src/hc08/gen.c (genMinus): fixed bug #1241835,
921 (genModOneByte): removed needless psha/pula
923 2005-07-22 Raphael Neider <rneider AT web.de>
925 * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
926 have PIC14 handled like PIC16, fixes broken pic14 linker calls
927 * src/pic/gen.c (resolveIfx): do not "invent" labels
928 * (genSkipc): changed to positive logic
929 * (genSkipCond): removed as no longer needed
930 * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
932 * (genLeftShift): check operands are in different registers
933 * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
934 INCF does not update CARRY...
935 * src/pic/main.c: fixed _linkCmd
936 * src/pic/pcode.c (unlinkpCode): added inactive code
937 * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
938 alive (do not assign result and operand overlapping registers)
940 2005-07-22 Raphael Neider <rneider AT web.de>
942 * src/pic/device.c (dump_sfr): replaced register declaration with
943 call to emitSymbolToFile() to avoid duplicate symbols
944 * (assignRelocatableRegisters): do not declare external symbols
945 * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
946 right (take size of type, not etype)
947 * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
948 * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
949 * (packRegsForAccUse): disabled assignment of WREG as
950 the result reg to prevent occurence of just fixed #1235003,
952 * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
953 symbols (avoids duplicate symbols in .asm file)
954 * (pic14emitRegularMap): use emitSymbolToFile()
955 * src/pic/gen.c (aopOp): fixed spillLocation handling
956 * (gen{Unp,P}ackBits): fixed acquiring bit-operands
957 * (genDataPointerSet): removed unneccessary variables/output
959 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
961 * as/mcs51/lkarea.c: enlarged codemap for banked memory
962 * device/lib/mcs51/crtbank.asm: added # to 0x0F
964 2005-07-21 Raphael Neider <rneider AT web.de>
966 * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
967 architecture cannot handle them efficiently, fixes bug #1235003
968 * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
969 check for empty sets before using them (fixes bug #1232190)
971 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
973 * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
974 (lnksect2): generate warnings for memory overlap
975 * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
976 constseg to set the name of these segments so you can instruct the linker
977 to place them in banks
978 * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
979 * src/SDCCglobl.h: added MODEL_HUGE to enum,
980 added code_seg and const_seg to options
981 * src/SDCCglue.c (emitMaps): use options.const_seg,
982 (createInterruptVect): put interrupt vectors in segment HOME,
983 (glue): put HOME before static segment and put the main glue in HOME,
984 (glue): use options.code_seg
985 * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
986 * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
987 these segments so you can instruct the linker to place them in banks
988 (linkEdit): use code_loc for HOME segment which should be the first
989 segment in code memory now
990 * src/SDCCmem.c: fixed more stuff like bug 1238386
991 * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
992 (changePointer): don't change function pointers to code pointers for
994 (compareType): added exceptional check for banked function pointers
995 * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
996 * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
997 after static in code memory
998 * src/mcs51/gen.c: added aopLiteralLong prototype,
999 (aopForSym): use getSize for functions,
1000 (genCall): generate banked calls over one trampoline __sdcc_banked_call
1001 in HOME with lsb of address in r0, msb in r1 and bank in r2, use
1002 -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
1004 (genPcall): use call for literal function pointers and generate banked
1005 calls over the one trampoline so there's only one place for the user to
1006 modify according to his/hers hardware,
1007 (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
1008 (genPlusIncr): moved check icount>4 beyond inc dptr optimization
1009 * src/mcs51/main.c: added keyword banked,
1010 (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
1011 * support/Util/SDCCerr.c,
1012 * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
1013 needed for passing the bank and address to the trampoline
1014 * device/lib/mcs51/crtbank.asm: added for bankswitching
1015 * device/lib/mcs51/Makefile: added crtbank
1017 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1019 * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
1020 for fields at offset 0 of a struct or union as reported
1021 on 2005-07-07 in the developer mailing list.
1023 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
1025 * src/SDCCmem.c: fixed bug 1238386
1027 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1029 * src/mcs51/peeph.def: added labelrefcounting for peepholes
1030 (patch #1144962), added peephole 300, enabled 259.x
1031 * doc/sdccman.lyx: removed screenshot and provided link instead
1033 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1035 * doc/sdccman.lyx: added section about debugging with ddd
1036 * doc/figures/ddd_example.eps: screenshot of debugging session
1038 2005-07-04 Raphael Neider <rneider AT web.de>
1040 * src/pic/gen.c (genPointerGet): handle pointers to CONST values
1041 like CODE pointers, fixes #1115683
1042 * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
1043 call, fixes bugs #1232211, #1228110,
1044 fixed wrong casts to pCodeFlow from pCodeInstructions
1046 2005-07-04 Raphael Neider <rneider AT web.de>
1048 * src/pic/gen.c (popGet): changed assert to allow for
1050 * (popGetAddr): changed signature to provide
1051 an additional index, patched all call sites
1052 * (genCmpEq): handle literal-like operands correctly
1053 * (genAddrOf): added sanity checks on __code/__data pointers
1054 * (genAssign): added handling of symbols from __code section
1055 * (gencjne): do not generate code for comparisons whose result
1056 is neither stored nor used, fixes bug #1171114
1057 * (AccLsh, AccRsh): operate on operand instead of WREG
1058 * (shift{Left,Right}_Left2ResultLit): NEW, size independant
1059 replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
1061 * rewrote complete shift-by-literal logic, commented unused
1063 * (genConstPointerGet): get multiple bytes (if result size > 1),
1064 fixed handling of non-immediate addresses
1065 * (genPointerGet): handle CODE pointers like CONST pointers
1066 * (genpic14Code): insert C-SRC lines as Cource-pCodes
1067 * ({aop,op}_isLitLike): NEW, single place to decide whether an
1068 operand is to be treated as a literal or not
1069 * (mov2w,genPcall,genCmpEq),
1070 src/pic/genarith.c: use aop_isLitLike() to decide between
1071 literal/register contents
1072 * (addSign): added missing offset
1073 * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
1074 only emit comment in debug-mode,
1075 use {aop,op}_isLitLike throughout the file
1076 * src/pic/glue.c: fix initializers for pointers (work in progress)
1077 * src/pic/pcode.c (get_op): honor index on _const symbols
1078 * ({reset,dump}pCodeStatistics): NEW, estimate code size
1079 * (dumppBlock): added pCode size estimation
1080 * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
1081 check for IS_SYMOP before OP_SYMBOL'ing
1082 * fixed indentation, compacted switch-statements
1083 * (allocReg): find free register and allocate it instead of
1084 allocating new registers all the time
1085 * (deassignLRs): prevent POINTER_GET's from being assigned the same
1086 registers as its operands (necessary only for multibyte GETs)
1088 2005-07-01 Raphael Neider <rneider AT web.de>
1090 * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
1091 debugging .asm-output macros FENTRY + FEXIT
1092 * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
1094 * (emitpComment): NEW, printf to pCode
1095 * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
1097 * (popGetAddr): NEW, variant of popGet to access an immediates
1098 high(er) bytes instead of the n'th byte of memory they reference,
1099 replaced popGet with popGetAddr where neccessary
1100 * (genDataPointerGet): reactivated and fixed implementation
1101 * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
1103 * (genDataPointerSet): fixed multibyte assignments
1104 * (genpic14Code): fixed --i-code-in-asm handling
1105 * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
1106 * (genPlus): fixed index-out-of-bounds error
1107 * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
1108 * src/pic/ralloc.c: added debugging output macro FENTRY2
1109 * (spillThis): fixed indentation, enbraced for-body for clarity
1110 * (rematStr): commented out as now unused
1111 * (regTypeNum): commented out special spill case (overwrites
1113 * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
1115 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
1117 * doc/sdccman.lyx: documented sfr16/sfr32,
1118 added example for using storage class with function pointers
1119 * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
1121 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
1123 * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
1124 * device/lib/_itoa.c,
1125 * device/lib/_ltoa.c: optimized codesize
1126 * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
1127 but don't know how to suppress the double warning.
1128 * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
1129 * support/Util/SDCCerr.c,
1130 * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
1132 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
1134 * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
1135 fixed old K&R prototypes
1136 * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
1137 * device/lib/_gptrget.c,
1138 * device/lib/_gptrgetc.c,
1139 * device/lib/_gptrput.c: changed versions for new memory indicator values,
1140 also new versions for small generic pointers and banked generic pointers
1141 * src/port.h: added const_name
1142 * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
1143 * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
1144 * src/SDCCcse.c (findPrevIc): check all associative operators
1145 * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
1146 * src/SDCCicode.h: added macro IS_ASSOCIATIVE
1147 * src/SDCCmem.c: updated comments,
1148 set far-space to 0 for pdata, results in optimized code
1149 * src/SDCCmem.h: added macro CONST_NAME
1150 * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
1151 moving the info into the highest bits, see also gptrget/gptrput
1152 * src/src.dsp: added sdcc.ico to project files
1153 * src/avr/gen.c (genCast): fixed bug 0x%d
1154 * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
1155 * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
1156 relation between ptr_type and DCL_TYPE,
1157 (genCast): fixed bug 0x%d
1158 * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
1159 (CODE)" for const_name
1160 * src/hc08/gen.c (genCast): fixed bug 0x%d
1161 * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
1162 (hc08_port): added "CONST (CODE)" for const_name
1163 * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
1164 (aopForRemat, adjustArithmeticResult): disconnected direct relation
1165 between ptr_type and DCL_TYPE,
1166 (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
1167 operand* and took AOP() inside function so sfr-ness can be checked,
1168 (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
1170 (genFunction, genEndFunction): optimized stack setup,
1171 (genMinus): optimized for literals with ending zeroes (in bytes),
1172 (genCast): fixed bug 0x%d
1173 * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
1174 (mcs51_port): added "CONST (CODE)" for const_name
1175 * src/mcs51/peeph.def: made rule 226 more generic
1176 * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
1177 * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
1178 * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
1179 * src/z80/main.c (z80_port): added NULL for const_name,
1180 (gbz80_port): added NULL for const_name
1181 * support/regression/tests/bug663539.c,
1182 * support/regression/tests/sfr16.c: new tests
1184 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1186 * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
1188 2005-06-24 Raphael Neider <rneider AT web.de>
1190 * device/lib/pic16/libdev/pic18f[68][567]20.c:
1192 * device/include/pic16/signal.h: added USBIF
1195 2005-06-24 Raphael Neider <rneider AT web.de>
1197 * device/lib/pic16/libdev/pic18f2455.c,
1198 device/include/pic16/pic18f2455.h: NEW
1199 * device/include/pic16/pic18fregs.h,
1200 device/lib/pic16/pics.all,
1201 src/pic16/device.c: added 18f2455
1202 * device/lib/pic16/libdev/pic18f[68][567]20.c,
1203 device/include/pic16/{pic18f[68][567].h,usart.h}:
1204 replaced MULTIPLE_USARTS define with more relaible
1205 compatibility sfrs (for USART access)
1207 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
1209 * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
1210 and the output asm file line is printed on two lines.
1212 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1214 * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
1215 BGT, BLE, BHI, and BLS instructions
1216 * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
1218 * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
1219 negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
1221 * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
1223 2005-06-15 Raphael Neider <rneider AT web.de>
1225 * src/pic16/NOTES: moved Vangelis from active developers to people to contact
1226 * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
1227 * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
1228 fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
1229 OP_SYM_TYPE() instead of OP_SYM_ETYPE()
1231 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1233 * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
1234 Marcel Telka in bug #1215704
1236 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
1238 * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
1239 located in shared memory bank.
1241 2005-05-31 Raphael Neider <rneider AT web.de>
1243 * src/pic16/{gen.c,genarith.c}: replaced sign-extension
1244 "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
1245 "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
1247 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
1249 * device/lib/_strncpy.c: fixed the fix
1251 2005-05-26 Raphael Neider <rneider AT web.de>
1253 * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
1254 initializers with \0, bug #1208187
1255 * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
1256 intializers with \0, bug #1208187
1258 2005-05-26 Raphael Neider <rneider AT web.de>
1260 * src/pic16/glue.c (pic16_printIvalChar): fixed string
1261 initializers with \0, bug #1208187
1262 * src/pic16/main.c (_process_pragma): added sanity checks
1263 for stack position and size, emit warnings when appropriate
1265 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
1267 * device/lib/_strncpy.c: fixed not filling with \0
1269 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1271 * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
1273 * src/SDCC.y (external_definition, enumerator, parameter_declaration,
1274 compound_statement),
1276 * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
1278 2005-05-24 Raphael Neider <rneider AT web.de>
1280 * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
1282 2005-05-24 Raphael Neider <rneider AT web.de>
1284 * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
1285 TRISE definitions, closes bug #1162453
1287 2005-05-22 Raphael Neider <rneider AT web.de>
1289 * src/pic16/main.c (_process_pragma): check for missing
1290 arguments to pragmas code and udata
1291 * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
1292 consistency fixes to match other headers (thanks to Jim Paris)
1293 * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
1295 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
1297 * src/SDCCicode.c (isOperandEqual): fixed missing ;
1299 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
1301 * support/regression/tests/bug1198642.c: new test
1302 * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
1303 * src/SDCCcse.c (findPrevIc): added comment, please have a look
1304 * support/scripts/resource.h,
1305 * support/scripts/resource.rc,
1306 * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
1307 * support/scripts/sdcc.ico: added 32x32 icon
1309 2005-05-18 Raphael Neider <rneider AT web.de>
1311 * device/lib/pic16/libdev/pic18f*.c,
1312 * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
1313 keywords to "__sfr" and "__at (X)"
1314 * device/include/pic16/pic18fregs.h: added pic18f4520
1315 * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
1316 #1203088 (MPLAB compatibility)
1318 2005-05-17 Raphael Neider <rneider AT web.de>
1320 * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
1321 * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
1322 * device/lib/pic16/pics.all: added new devices
1323 * src/pic16/device.c: added support for pic18f4520
1325 2005-05-16 Raphael Neider <rneider AT web.de>
1326 * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
1327 * src/pic16/genarith.c (genAddLit): fixed bug 1202480
1328 * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
1329 convenience function for bit access
1331 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
1333 * device/lib/printf_large.c: fixed bug 1193299
1334 * support/regression/tests/bug1057979.c: added test %3.3s
1336 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1338 * device/include/mcs51/8051.h,
1339 * device/include/mcs51/8052.h: made parseable with lint
1340 * device/include/mcs51/lint.h: added include file for (sp)lint
1341 * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
1342 * doc/cdbfileformat.lyx,
1343 * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
1345 2005-05-14 Raphael Neider <rneider AT web.de>
1347 * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
1348 * device/lib/pic16/libc/stdlib/itoa.c (new)
1349 * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
1350 * device/lib/pic16/libio/Makefile: exclude subdir according to
1351 ${subdir}.ignore for certain PICs (lacking e.g. i2c)
1352 * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
1353 * src/pic16/gen.c (genFunction): prevent annoying warning
1354 * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
1356 * support/cpp2/cppmain.c (cpp_output_string): new
1357 * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
1360 2005-05-13 Borut Razem <borut.razem AT siol.net>
1362 * src/SDCCmain.c (linkEdit): fixed bug 1195202
1364 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1366 * .version: changed to version 2.5.1; back to bleeding edge development
1368 2005-05-11 Borut Razem <borut.razem AT siol.net>
1370 * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
1371 generate PDF version 1.3 documents
1373 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1375 * .version: changed to version 2.5.0
1377 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1379 * doc/sdccman.lyx: updated weblinks, index and smaller updates
1381 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1383 * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
1384 --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
1385 well as many smaller updates.
1386 * .version: changed to version 2.5.0-pre1
1388 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1390 * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
1392 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
1394 * support/regression/tests/bug1185672.c: added
1395 * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
1397 * src/mcs51/gen.c (genCall): added comments, made it look safer
1398 * src/mcs51/gen.c (genEndFunction): simplified
1400 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
1402 * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
1404 2005-04-14 Borut Razem <borut.razem AT siol.net>
1406 * fixed bug 1045046 - SIGSEGV with really simple code?:
1407 src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
1408 src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
1410 2005-04-14 Borut Razem <borut.razem AT siol.net>
1412 * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
1413 src/pic16/device.h: temporarily disabled experimental #inline pragma
1416 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
1418 * device/include/z80/stdio.h,
1419 * device/include/z80/string.h: removed these highly incomplete files so
1420 SDCC can use the default ones in device/include/
1422 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1424 * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
1426 * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
1429 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
1431 * device/include/malloc.h: removed redundant __reentrant prototypes
1432 * device/lib/_mullong.c: added working xstack variant in asm (C version
1433 doesn't pass regression tests)
1434 * device/lib/bpx.c: used __data and made bpx char for mcs51
1435 * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
1436 (createFunction): fixed bug with xstackPtr
1437 * src/SDCCcse.c: corrected comments
1438 * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
1439 (killDeadCode, eBBlockFromiCode): removed unused code
1440 * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
1442 * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
1443 assignResultValue, genCall, genFunction, genEndFunction, genAnd,
1444 genOr, genXor, genAddrOf): fixed several bugs concerning xstack
1445 (genModOneByte): fixed warning in MSVC
1446 * src/mcs51/main.c (): added comments
1447 * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
1449 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
1451 * src/SDCCmain.c (linkEdit): oops, changed one line too many
1453 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
1455 * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
1457 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
1459 * src/pic16/glue.c (printIvalChar): fixed bug when emitting
1460 characters arrays of larger size than the declared one.
1462 2005-04-10 Borut Razem <borut.razem AT siol.net>
1464 * src/pic/gen.c (genInline),
1465 src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
1466 (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
1467 (findNextInstruction), (findPrevInstruction),
1468 (findInstructionUsingLabel),
1469 src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
1470 * src/pic/pcode.c (findLabel): added missing '\n'
1471 * src/src.dsp: added SDCCdwarf2.c to the project
1473 2005-04-09 Borut Razem <borut.razem AT siol.net>
1475 * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
1477 2005-04-08 Raphael Neider <rneider AT web.de>
1479 * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
1480 into the chain after a given one) and mergeDefmapSymbols (combine
1481 defmap entries for each symbol per pcode)
1482 * (createDefmap): have defmap entries merged in the end
1483 * (defmapReplaceSymRef): split defmap entries covering two accesses to
1484 a symbol before replacing one access type's symbol, merge symbols in
1485 the end (replacement symbol might already have an entry)
1486 * (assignValnums): keep reference to written WREG intact
1488 2005-04-08 Raphael Neider <rneider AT web.de>
1490 * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
1493 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
1495 * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
1498 2005-04-07 Raphael Neider <rneider AT web.de>
1500 * device/include/pic16/usart.h: added compatibility defines for
1501 devices with more than one USART
1502 * device/include/pic16/pic18f[68][567]20.h: activated above defines
1504 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1506 * device/lib/Makefile.in: updated for port specific include
1508 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1510 * support/regression/ports/mcs51/spec.mk: added mcs51 include
1512 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1514 * device/include/8051.h,
1515 * device/include/8052.h,
1516 * device/include/at89S8252.h,
1517 * device/include/at89c55.h,
1518 * device/include/at89x051.h,
1519 * device/include/at89x51.h,
1520 * device/include/at89x52.h,
1521 * device/include/mcs51reg.h,
1522 * device/include/reg51.h,
1523 * device/include/reg764.h,
1524 * device/include/regc515c.h,
1525 * device/include/sab80515.h: (re)moved these 12 files
1526 * device/include/mcs51/8051.h,
1527 * device/include/mcs51/8052.h,
1528 * device/include/mcs51/at89S8252.h,
1529 * device/include/mcs51/at89c55.h,
1530 * device/include/mcs51/at89x051.h,
1531 * device/include/mcs51/at89x51.h,
1532 * device/include/mcs51/at89x52.h,
1533 * device/include/mcs51/mcs51reg.h,
1534 * device/include/mcs51/reg51.h,
1535 * device/include/mcs51/reg764.h,
1536 * device/include/mcs51/regc515c.h,
1537 * device/include/mcs51/sab80515.h: and added them here
1539 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1541 * device/include/stdarg.h: changed SDCC specific keywords to double
1543 * device/include/stdint.h: changed intptr_t and uintptr_t for others than
1545 * device/include/hc08/mc68hc908gp32.h,
1546 * device/include/hc08/mc68hc908jb8.h,
1547 * device/include/hc08/mc68hc908jkjl.h,
1548 * device/include/hc08/mc68hc908qy.h: fixed comments
1549 * device/include/mcs51/README: updated
1550 * device/include/mcs51/c8051f120.h: added PINRSF
1551 * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
1552 * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
1553 amidst code. Also inline is not supported.
1555 2005-04-06 Raphael Neider <rneider AT web.de>
1557 * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
1558 * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
1559 callers stack/frame pointers
1561 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
1563 * device/include/pic16/usart.h: added, missing in previous commit,
1564 * device/include/pic16/adc.h: fixed typo,
1565 * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
1567 * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
1569 * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
1570 uninitialized because a bug appears with gplink
1571 * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
1572 COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
1573 complains for unrecognised option
1575 2005-04-05 Raphael Neider <rneider AT web.de>
1577 * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
1578 structs as well (using memcpy)
1579 * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
1580 on ISRs (GOTO has no label)
1581 * src/pic16/device.h: added OF_OPTIMIZE_DF
1582 * src/pic16/main.c: added compiler switch --optimize-df to enable the
1583 new data flow analysis/optimization
1584 * src/pic16/pcode.c: added (prototypes for and implementation of)
1585 dataflow analysis functions, fixed pCodeInstructions' inCond and
1586 outCond values, made RCALL a branch instruction
1587 * (pic16_unlinkpCode): keep C line if possible
1588 * (pic16_pCodeUnlink): removed cast on left side of assignment, have
1589 C line moved if possible
1590 * (pic16_getRegFrompCodeOp): NEW, improved version of...
1591 * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
1592 to use new pic16_getRegFrompCodeOp (works for more SFRs)
1593 * (pic16_BuildFlow): fixed skip instructions with label (did not start
1595 * (pic16_getJumptabpCode): NEW, needed in...
1596 * (LinkFlow): fixed handling of jumptables, calls and conditional
1598 * (pic16_InsertCommentAfter): NEW
1599 * (pic16_pCodeReplace): made verbose and flow preserving
1600 * (AnalyzeFlow): added call to data flow analysis
1601 * src/pic16/pcode.h: added defmaps to pCodeFlow struct
1602 * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
1603 * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
1605 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1607 * src/SDCCast.c (decorateType): fixed bug #1105626
1609 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
1611 * device/include/asm/pic16/features.h,
1612 * pic18f*.h headers,
1613 * device/include/pic16/adc.h,
1614 * device/include/pic16/delay.h,
1615 * device/include/pic16/i2c.h,
1616 * device/include/pic16/malloc.h,
1617 * device/include/pic16/stdio.h,
1618 * device/include/pic16/stdlib.h,
1619 * device/include/pic16/string.h,
1620 * device/lib/pic16/libc/stdio/printf_tiny.c,
1621 * device/lib/pic16/libc/stdio/printf_small.c,
1622 * device/lib/pic16/libc/stdio/strmgpsim.c,
1623 * device/lib/pic16/libc/stdio/strmmssp.c,
1624 * device/lib/pic16/libc/stdio/strmusart.c,
1625 * device/lib/pic16/libc/stdio/vfprintf.c,
1626 * device/lib/pic16/libc/stdlib/ltoa.c,
1627 * device/lib/pic16/libc/stdlib/putchar.c,
1628 * device/lib/pic16/libc/stdlib/x_ftoa.c,
1629 * device/lib/pic16/libc/stdlib/memchrpgm.c,
1630 * device/lib/pic16/libc/stdlib/memchrram.c,
1631 * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
1632 * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
1633 * device/lib/pic16/libio/adc/adcbusy.c,
1634 * device/lib/pic16/libio/adc/adcread.c,
1635 * device/lib/pic16/libio/adc/adcsetch.c,
1636 * device/lib/pic16/libio/usart/ubaud.c,
1637 * device/lib/pic16/libio/usart/ubusy.c,
1638 * device/lib/pic16/libio/usart/udrdy.c,
1639 * device/lib/pic16/libio/usart/uopen.c,
1640 * device/lib/pic16/libio/usart/uputc.c,
1641 * device/lib/pic16/libsdcc/gptr/gptrget1.c,
1642 * device/lib/pic16/libsdcc/gptr/gptrget2.c,
1643 * device/lib/pic16/libsdcc/gptr/gptrget3.c,
1644 * device/lib/pic16/libsdcc/gptr/gptrget4.c,
1645 * device/lib/pic16/libsdcc/gptr/gptrput1.c,
1646 * device/lib/pic16/libsdcc/gptr/gptrput2.c,
1647 * device/lib/pic16/libsdcc/gptr/gptrput3.c,
1648 * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
1649 specific keywords to double underlined form,
1650 * device/lib/pic16/libc/Makefile.rules,
1651 * device/lib/pic16/libsdcc/Makefile.rules,
1652 * device/lib/pic16/libm/Makefile,
1653 * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
1654 to compile with C standard set in Makefile.common
1655 * device/lib/pic16/libc/stdlib/Makefile: added new C sources
1656 rand.c and crc.c in compilation process,
1657 * device/lib/pic16/libsdcc/int/divuint.c,
1658 * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
1659 `c' from signed to unsigned,
1660 * device/lib/pic16/startup/crt0.c,
1661 * device/lib/pic16/startup/crt0i.c,
1662 * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
1663 keywords to double underlined form, bug fixes in _do_cinit function
1664 which prevented the correct initialization of the .idata segment,
1665 * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
1666 core to enter a infinite loop
1667 * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
1669 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1671 * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
1673 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1675 * device/include/Makefile.in: add support for hc08 subdirectory
1676 * device/include/hc08/: new subdirectory
1677 * device/include/hc08/mc68hc908jkjl.h: new header contributed by
1678 Lucas Loizaga, thanks!
1679 * device/include/hc08/mc68hc908qy.h,
1680 * device/include/hc08/mc68hc908gp32.h,
1681 * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
1682 their own directory. Changed internal macro names to use the compiler
1683 reserved namespace. Changed SDCC specific keywords to double
1685 * device/include/math.h,
1686 * device/include/malloc.h,
1687 * device/include/stdarg.h,
1688 * device/include/stdbool.h
1689 * device/include/string.h,
1690 * device/include/tinibios.h,
1691 * device/include/ds400rom.h,
1692 * device/include/8051.h,
1693 * device/include/8052.h,
1694 * device/include/80c51xa.h,
1695 * device/include/at89c55.h,
1696 * device/include/at89S8252.h,
1697 * device/include/at89x51.h,
1698 * device/include/at89x52.h,
1699 * device/include/ds80c390.h,
1700 * device/include/reg764.h,
1701 * device/include/regc515c.h,
1702 * device/include/sab80515.h,
1703 * device/include/mcs51/c8051f000.h,
1704 * device/include/mcs51/c8051f018.h,
1705 * device/include/mcs51/c8051f020.h,
1706 * device/include/mcs51/c8051f040.h,
1707 * device/include/mcs51/c8051f060.h,
1708 * device/include/mcs51/c8051f120.h,
1709 * device/include/mcs51/c8051f300.h,
1710 * device/include/mcs51/c8051f310.h,
1711 * device/include/mcs51/c8051f320.h,
1712 * device/include/mcs51/c8051f330.h,
1713 * device/include/mcs51/c8051f350.h,
1714 * device/include/z180.h: Changed SDCC specific keywords to double
1717 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
1719 * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
1721 * (pic16_assignConfigWordValue): disable testing of configuration
1722 register value with config mask,
1723 * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
1724 function with port->fun_prefix,
1725 * (genFunction): when generating a naked interrupt function never
1726 create an absolute segment placed in interrupt vector address, place
1727 the actual interrupt function at IVA instead, when an interrupt
1728 function is generated with unspecified interrupt then do not create
1729 the absolute section,
1730 * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
1731 code for generating a call to generic pointer get/put function with
1732 a call to function pic16_callGenericPointer(),
1733 * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
1734 the call to the generic pointer get/put functions with prefixing the
1735 function name with port->fun_prefix,
1736 * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
1737 * src/pic16/main.c (_process_pragma): prefix function with
1739 * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
1740 calling assembler, old 18Fxxxx macro is deprecated,
1741 * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
1742 PC_ASMDIR in while condition,
1743 * (findInstruction): add PC_ASMDIR in while condition,
1744 * (buildCallTree): prefix main with port->fun_prefix,
1745 * (pic16_pCode2str): fixed bug that didn't emit the memory access
1746 identifier for variable with banked access in instructions BTFSS,
1747 BTFSC, BCF, BSF, BTG
1748 * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
1749 * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
1750 * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
1751 perform optimization when enviroment variable NO_REG_OPT is set,
1752 * (insideLRBlock): NEW, return 1 if register is inside an
1753 INF_LOCALREGS block,
1754 * (RemoveRegFromLRBlock): remove a register that is completely
1755 eliminated by register optimization, but it is still left in local
1756 register store/restore in/from stack block,
1757 * (Remove2pcodes): after removing register, check to see if it
1758 should be removed from local register store/restore in/from stack
1760 * src/pic16/ralloc.c (pic16_decodeOp): added decode for
1761 DUMMY_READ_VOLATILE,
1763 * device/include/pic16/adc.h: minor prototype modifications and
1765 * device/include/pic16/malloc.h: added GPL notice various
1767 * device/include/pic16/stdint.h: NEW, standard header for ints
1768 * device/include/pic16/delay.h: NEW, header for delay functions,
1769 delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
1771 * device/include/pic16/signal.h: NEW, header providing helper macros
1772 for implementing signal handlers,
1773 * device/include/pic16/stdio.h: added prototypes for functions,
1774 printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
1775 prototypes for stdin and stdout, added macro PUTCHAR to
1776 automatically implement putchar function prototype,
1777 * device/include/pic16/usart.h: modified and updated USART library,
1778 * device/lib/pic16/libio/adc/,
1779 * device/lib/pic16/libio/i2c: some modifications to improve library
1781 * device/lib/pic16/libc/stdio/: modifications for the new printf*
1782 family of functions,
1783 * device/lib/pic16/libc/stdlib/: various modifications in the malloc
1784 family of functions and other sources,
1785 * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
1786 of the PIC18Fxx[28] devices,
1787 * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
1788 * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
1789 * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
1790 _do_cinit function, because the previous failed when local variables
1791 where not placed in the same memory bank,
1792 * device/lib/pic16/libsdcc/char/: various modifications to improve
1793 library performance,
1794 * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
1795 information on the new functions of the c library and more...
1797 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1799 * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
1801 2005-03-26 Raphael Neider <rneider AT web.de>
1803 * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
1804 if condition == CARRY)
1805 * (genCmp): adapted to new genSkipc semantics
1806 * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
1807 on rIfx (genCmp was broken)
1809 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1811 * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
1812 * src/z80/main.c (_keywords[]),
1813 * src/SDCCglobal.h (struct options),
1815 * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
1816 to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
1817 std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
1818 --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
1819 always available in leading double underscore form. The C99 support is
1820 mostly missing, but it's a start.
1821 * support/regression/tests/bug-227710.c: fixed nonconforming use of
1822 reserved identifier "__data".
1824 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1826 * src/mcs51/peeph.def: fixed bug 1170013
1828 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
1830 * device/include/mcs51reg.h: fixed bug 842007
1832 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1834 * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
1837 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1839 * src/port.h (struct PORT),
1840 * src/avr/ralloc.c (avr_assignRegisters),
1842 * src/ds390/ralloc.c (ds390_assignRegisters),
1844 * src/hc08/ralloc.c (hc08_assignRegisters),
1846 * src/mcs51/ralloc.c (mcs51_assignRegisters),
1848 * src/pic/ralloc.c (pic14_assignRegisters),
1850 * src/pic16/ralloc.c (pic16_assignRegisters),
1852 * src/xa51/ralloc.c (xa51_assignRegisters),
1854 * src/z80/ralloc.c (z80_assignRegisters),
1856 * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
1857 * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
1859 * src/SDCCdflow.c (computeDataFlow),
1861 * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
1863 * src/SDCCcflow.c (*),
1865 * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
1866 * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
1867 of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
1868 immedDom() returning wrong block; probably fixes bug #1160833)
1870 2005-03-20 Borut Razem <borut.razem AT siol.net>
1872 * support/scripts/inc2h.pl: WIN32 port
1874 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
1876 * device/lib/makefile.in: added abs.c and labs.c
1878 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
1880 * device/include/stdint.h: added
1881 * device/lib/abs.c: added
1882 * device/lib/labs.c: added
1883 * device/include/stdlib.h: added abs() and labs() prototypes
1884 * device/lib/libsdcc.lib: added abs and labs
1885 * device/include/float.h,
1886 * device/lib/_fsmul.c,
1887 * device/lib/printf_fast.c,
1888 * device/lib/printf_tiny.c: updated comments
1890 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1892 * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
1895 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1897 * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
1898 * src/SDCCast.c (isLoopCountable): fixed bug #1161985
1900 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
1902 * device/lib/printf_large.c: removed inline assembly for portability and
1903 readability. Use printf_fast if speed or size are more important.
1904 * src/pic16/gen.c: removed conditions around use of DEBUGpc
1905 * src/pic16/genutils.h: added define for DEBUGpc for MSVC
1907 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
1909 * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
1910 prevent compiler warning
1912 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
1914 * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
1915 moved to level 0 and declared as static. Also they are explicit
1916 placed in access bank. This was necessery because some times they
1917 might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
1918 * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
1919 optimizations. Currently only compare to unsigned char is implemented,
1920 * src/pic16/gen.c: added fReturnIdx array,
1921 * (struct resolvedIfx) is moved to gen.h and made public,
1922 * (struct _G): added sregsAlloc and sregsAllocSet fields,
1923 * (aopForSym): added an optimization to directly store in stack of
1924 the operand of a SEND iCode,
1925 * (pic16_aopOp): don't return return registers as strings (AOP_STR)
1926 but as registers instead (AOP_REG) using the fReturnIdx array,
1927 * (pic16_freeAsmop): remove the freed register from the
1928 _G.sregsAlloc field,
1929 * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
1930 a compare of 'WREG',
1931 * (pic16_popGetTempRegCond): changed function prototype, now
1932 function takes also a bitVector argument v which holds the current
1933 set of registers that are allocated for stack access by aopForSym,
1934 registers allocated in aopForSym for accessing stack symbols are not
1935 any more part of the functions usedRegs field,
1936 * (genCall): some times aopOp is called for a stack variable to be
1937 send, aopForSym might perform the push, if this is true make sure
1938 that genCall doesn't push the variable twice by testing _G.resDirect,
1939 * (genFunction): changed testing for unspecified interrupt number
1940 from 256 to INTNO_UNSPEC,
1941 * modified selection scheme of frame pointer generation. Previously
1942 if function did use local registers a frame pointer was generated,
1943 now a frame pointer is generated only if function has arguments
1944 (that need PLUSW2 register access), or has stack arguments, or the
1945 compiler is not instructed to omit the frame pointer,
1946 * (genEndFunction): before restoring local registers that were saved
1947 in the function preamble, also restore the registers that *might*
1948 have been allocated for stack access,
1949 * (genRet): removed some old comments,
1950 * (genCmp, the active (RN's) version): added a call to the
1951 pic16_genCmp_special function to perform the compare with a more
1952 robust and optimized way,
1953 * (genInline): a feature has been added in inline code generation,
1954 which allows a wildcard variable substitution when writing inline
1955 assembly. Code is incomplete and experimental therefore undocumented,
1956 * (genCast): changed order of aopOp for result and right to allow
1957 aopForSym to directly load the result if possible,
1958 * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
1959 perform an optimized compare on some selected special occasions,
1960 * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
1961 * src/pic16/glue.c (pic16createInterrupVect): make sure we never
1962 generate an IVT any more,
1963 * src/pic16/main.c (pic16_optionsTable): added command line option
1965 * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
1966 macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
1968 * src/pic16/NOTES: Raphael Neider added in list of active developers
1969 * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
1970 jumptable_end to prevent bug #,
1971 * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
1972 inCond and outCond fields,
1973 * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
1974 * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
1975 turn off register spilling,
1976 * (packRegsForOneUse): synced with other ports' versions although it
1977 is not used currently,
1978 * (pic16_packRegisters): added an optimization while reading
1979 structure bitfields, some registers may be saved (malloc code is
1980 decreased by 80 bytes)
1982 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
1984 * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
1985 left is a bitfield, if yes, then don't optimize assignment. Perhaps
1986 this can be optimized more?
1988 2005-03-10 Raphael Neider <rneider AT web.de>
1990 * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
1991 genNearPointerGet): (hopefully) fixed access to bitfields via
1992 pointers (p->bitN = x; and x = p->bitN; failed)
1994 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
1996 * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
1998 2005-03-09 Raphael Neider <rneider AT web.de>
2000 * src/SDCCopt.c (killDeadCode): fixed bug #1156016
2002 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
2004 * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
2005 * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
2006 (regTypeNum): set REG_BIT type if necessary
2007 * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
2008 * support/regression/tests/critical.c: check bug 1144613
2010 2005-03-02 Raphael Neider <rneider AT web.de>
2012 * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
2014 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2016 * src/avr/ralloc.c (serialRegAssign),
2017 * src/ds390/ralloc.c (serialRegAssign),
2018 * src/hc08/ralloc.c (serialRegAssign),
2019 * src/mcs51/ralloc.c (serialRegAssign),
2020 * src/pic/ralloc.c (serialRegAssign),
2021 * src/pic16/ralloc.c (serialRegAssign),
2022 * src/xa51/ralloc.c (serialRegAssign),
2023 * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
2025 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
2027 * src/SDCCast.c (decorateType): fixed bug 1124787
2029 2005-02-20 Hubert Sack <sack AT digiplan.de>
2030 committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2032 * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
2035 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2037 * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
2038 to keep the correct label reference count when adding/removing references
2039 to labels. A peephole file using this is appended to patch #1144962.
2041 2005-02-14 Raphael Neider <rneider AT web.de>
2043 * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
2044 * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
2045 * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
2046 retrievals of result operand's value on assignment
2048 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
2050 * device/include/pic16/string.h: modified prototype for memccpy()
2051 to memccpy(void *, void *, char, size_t)
2052 * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
2053 check whether to omit frame pointer or not,
2054 * (genInline): convert all occurences of "\n" to LF in inline
2055 assembler blocks, this helps formatting the inline text,
2056 * (pic16_loadFSR0): modified prototype,
2057 * (genNearPointerGet, genNearPointerSet): reorganization of code,
2058 removed some 8051 legacy code,
2059 * (genPackBits): enabled handling bitfields exceeding one byte in size,
2060 * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
2061 before allocating temporary registers in functions,
2063 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
2065 * support/regression/tests/bitvars.c: corrected the "fix"
2067 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
2069 * support/regression/tests/bitvars.c,
2070 * support/regression/tests/bitwise.c,
2071 * support/regression/tests/rotate.c: "fixed" problems on Alpha
2073 2005-02-10 Raphael Neider <rneider AT web.de>
2075 * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
2076 different size for Alpha
2077 * src/pic16/gen.c (genCmpEq) : improved compare with 0
2079 2005-02-09 Raphael Neider <rneider AT web.de>
2081 * src/SDCC.lex(doPragma) : save and restore warning options as well
2082 (also added new stack plus clone- and copyAndFreeSDCCERRG())
2083 * have #pragma less_pedantic set the errorlevel to WARNING
2085 * (cloneOptimize) : fixed wrong malloc's size
2086 * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
2087 facilitate correct handling of #pragma (save|restore)
2089 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
2091 * src/mcs51/gen.c: removed non-standard C nameless struct/union
2093 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
2095 * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
2097 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
2099 * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
2101 2005-02-02 Raphael Neider <rneider AT web.de>
2103 * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
2104 * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
2105 * (pic16_storeForReturn): fixed to allow returning function pointers
2106 * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
2107 * device/include/pic16/{stddef.h,stdbool.h}: added
2109 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
2111 * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
2113 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
2115 * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
2116 * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
2117 appeared to be required
2119 2005-01-31 Borut Razem <borut.razem AT siol.net>
2121 * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
2122 include/mcs51 and include/z80 directories to the package
2124 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2126 * src/hc08/gen.c (genFunction): fixed bug #1112752
2128 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2130 * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
2132 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2134 * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
2136 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
2138 * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
2140 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
2142 * device/include/c8051fxxx.h: removed these 6 files
2143 * device/include/mcs51/c8051fxxx.h: added these 11 new files
2145 2005-01-26 Raphael Neider <rneider AT web.de>
2147 * src/pic16/gen.c (genAssign): fixed assignment from longs
2148 in codespace (were cut to three bytes)
2149 * (genDummyRead): implemented (except for CODESPACE...),
2151 * src/pic16/glue.c (emitStatistics): beautified
2152 * device/lib/pic16/libm/Makefile: added include path
2154 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2156 * src/z80/gen.c (aopPut): fixed bug #1103902
2158 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2160 * device/lib/expf.c: fixed bug #1095792
2162 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
2164 * device/lib/pic16/libm: added Math library sources
2166 2005-01-24 Raphael Neider <rneider AT web.de>
2168 * src/pic16/pcode.h: added second memory operand to pCodeOpReg
2169 to enable upcast to pCodeOpReg2 (there is no type tag to
2170 differenciate the two and pic16_popGet2p cast into PCOR2)
2171 * src/pic16/main.c (_process_pragma): fixed another malloc bug
2172 (sizeof(sectNames) changed to sizeof(sectName))
2173 Both patches fix segfaults under MinGW.
2175 2005-01-23 Raphael Neider <rneider AT web.de>
2177 * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
2178 Safe_[mc]?alloc()'ed variables
2179 * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
2180 of (byte sized) temporaries (assign them to WREG for now)
2181 * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
2182 (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
2183 this might fix SIGSEGVs on MinGW...
2184 * src/SDCCopt.c (killDeadCode): restored original behaviour
2185 (volatile operands might get thrown away though)
2187 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
2189 * src/pic16/gen.c: fixed bug #1106975,
2190 * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
2191 pointer update, INTCON is saved, global interrupts are disabled and
2192 restored after updateing TOS.
2193 * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
2194 * added function attribute 'shadowregs' to take advantage of shadow
2196 * added function attribute 'wparam' as an alternative to the wparam
2198 * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
2199 user declares a non-ISR function as 'shadowregs',
2200 * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
2202 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
2204 * .version: bumped version number to 2.4.8
2205 * device/lib/pic16/pics.all: list of PIC18F devices supported by
2207 * device/lib/pic16/libio/i2c/: I2C module support library,
2208 * device/include/pic16/i2c.h: I2C support library header,
2209 * device/lib/pic16/libc/stdio/: standard IO support sources,
2210 * (printf_small.c): printf_small() source, supports float print,
2211 * (printf_tiny.c): printf_tiny() source, does not support floats,
2212 * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
2213 enable global optimizations for entire library source, other
2214 Makefiles in the source tree are also modified to reflect this,
2215 * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
2217 * doc/sdccman.lyx: updated to reflect new changes,
2218 * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
2219 sym->onStack if-case,
2220 * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
2221 sbit, idata, _idata, xdata, _xdata,
2222 * added pragma library, to link an external library, (see doc),
2223 * removed command line options, --pomit-config-words, --pomit-ivt,
2224 --pleave-reset-vector,
2225 * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
2226 when calling assembler to reflect memory model used, also define
2227 macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
2228 reflect stack model used,
2229 * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
2230 on stack return NULL,
2232 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
2234 * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
2235 of the operands is volatile. Fixes #1020220
2237 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
2239 * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
2240 * (OptimizeRegUsage): make sure that there is really no other flow where
2241 the first pCode is used
2243 2005-01-22 Raphael Neider <rneider AT web.de>
2245 * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
2246 to fix #1106967 (pCode->seq are not set up correctly)
2248 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2250 * src/SDCCglue.c (glue): make sure code area is declared before the
2251 static initialization area.
2253 2005-01-21 Raphael Neider <rneider AT web.de>
2255 * device/lib/Makefile.in: fixed test for pic16 install dir
2256 * device/lib/pic16/*/Makefile*: modified compile flags to enable
2258 * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
2259 added --optimize-goto compiler switch and pragma wparam documentation
2260 * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
2261 * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
2262 and PRODH closing bug #1071770 (peephole optimizer)
2264 2005-01-19 Raphael Neider <rneider AT web.de>
2266 * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
2267 cmdLine buffers (used when calling sdcpp...) are large enough
2268 (MAX_PATH=256 truncates arguments leading to system halts when
2270 * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
2271 * (genUminus): rewritten to for efficiency
2272 * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
2273 used uninitialized in some cases)
2274 * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
2275 copy the third byte from the int -- now assumes 0x80 (data memory)
2276 * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
2277 operands (genAddLit expects the iCode's operands to swapped as
2278 well), fixed leftover bytes (crashed for short left operands)
2279 * (pic16_genMinusDec): performance improvements, removed false
2281 * (pic16_genMinus): fixed to cope with differently sized operands
2282 * src/pic16/glue.c (pic16_glue): added new banksel optimization
2284 * src/pic16/pcode.c: implemented (first phase of) banksel optimization
2285 * src/pic16/graph.[ch]: implementation of directed graphs, used by
2286 new banksel optimization
2287 * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
2288 analysis for temporary registers (segfaults...)
2289 * src/pic16/peeph.def: added rule
2291 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
2293 * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
2294 which converts a float number to its ASCII representation
2295 * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
2296 functions to convert the fractional and integer part of a float to ASCII,
2297 * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
2298 realloc.c): added _MALLOC_SPEC to explicit place variables in data
2300 * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
2302 * device/include/pic16/adc.h: added GPL info,
2303 * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
2304 a pCodeOp as tested operand,
2305 * (genNearPointerGet): optimized bit testing, does not use
2306 intermediate register for bit value, test directly instead with
2307 BTFSS, BTFSC, works only for single bits,
2308 * (genpic16Code): dump the name of the iCode in the asm,
2309 * src/pic16/ralloc.c (decodeOp): removed static declaration and
2310 renamed to pic16_decodeOp,
2311 * (serialRegAssign): do not allocate a temporary register for iCode
2312 sequences that test a single bit for 1/0
2314 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
2316 * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
2317 pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
2318 access stack and frame pointers. They are initially assigned to
2319 point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
2320 accessing SFRs. Updated all occurences of modification of stack or
2321 frame pointer in gen.c and pcode.c,
2322 * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
2323 assigning of a literal value to pointers,
2324 * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
2325 flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
2328 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
2330 * doc/sdccman.lyx: update documentation about stack pragma, added
2331 some info for stack memory models
2333 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2335 * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
2337 2005-01-08 Raphael Neider <rneider AT web.de>
2339 * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
2340 udata sections to fix bug #1097823
2342 2005-01-05 Raphael Neider <rneider AT web.de>
2344 * src/pic16/gen.c (genGenericShift): added handling of differently
2345 sized left operand and result
2347 2005-01-04 Raphael Neider <rneider AT web.de>
2349 * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
2350 * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
2351 to hold the condition bit)
2352 * added new version of genCmp (old code available via #define)
2353 * added new version of genShiftLeft/genShiftRight in a generic
2354 way, now supports shifting by negative values
2355 * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
2356 shiftCount (expected by genGenericShift)
2357 * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
2358 * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
2360 * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
2361 is an invalid literal too...)
2363 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
2365 * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
2366 from Raphael Neider,
2367 * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
2368 for 8-bit literals. This fixes some literal operands which are sign
2369 extended to 16-bits ints when instruction needs only 8-bits.
2371 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
2373 * device/lib/logf.c: added mcs51 assembly version
2374 * device/lib/expf.c: added mcs51 assembly version
2375 * device/lib/_logexpf.c: new shared asm code for expf and logf
2376 * device/include/math.h: add defines for assembly math library
2377 * device/lib/Makefile.in: build new _logexpf.c
2378 * device/lib/libfloat.lib: use new _logexpf.c
2380 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
2383 * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
2384 device types which have less than 0x7f registers.
2386 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
2388 * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
2390 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
2392 * device/lib/printf_fast.c: only build on supported arch.
2393 * device/lib/printf_tiny.c: only build on supported arch.
2394 * device/lib/printf_fast_f.c: only build if asm float lib
2395 * device/lib/_fsget1arg.c: only build if asm float lib
2396 * device/lib/_fsget2args.c: only build if asm float lib
2397 * device/lib/_fsnormalize.c: only build if asm float lib
2398 * device/lib/_fsreturnval.c: only build if asm float lib
2399 * device/lib/_fsrshift.c: only build if asm float lib
2400 * device/lib/_fsswapargs.c: only build if asm float lib
2401 * device/include/stdio.h: don't provide print_fast,
2402 print_fast_f, print_tiny prototypes if --xstack used
2404 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
2406 * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
2407 * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
2410 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
2412 * device/lib/printf_fast_f.c: same as printf_fast, but
2413 with floating point enabled
2414 * device/lib/printf_fast.c: minor tweaks
2415 * device/include/stdio.h: add printf_fast_f
2417 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
2419 * src/SDCCmain.c: make --float-reent default for mcs51
2420 * device/lib/_fsadd.c: added mcs51 assembly version
2421 * device/lib/_fssub.c: added mcs51 assembly version
2422 * device/lib/_fsmul.c: added mcs51 assembly version
2423 * device/lib/_fsdiv.c: added mcs51 assembly version
2424 * device/lib/_fseq.c: added mcs51 assembly version
2425 * device/lib/_fsneq.c: added mcs51 assembly version
2426 * device/lib/_fsgt.c: added mcs51 assembly version
2427 * device/lib/_fslt.c: added mcs51 assembly version
2428 * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
2429 * device/lib/Makefile.in: add _fscmp to build
2430 * device/lib/libfloat.lib: add _fscmp to build
2432 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
2434 * device/lib/_fs2slong.c: added mcs51 assembly version
2435 * device/lib/_fs2sint.c: added mcs51 assembly version
2436 * device/lib/_fs2schar.c: added mcs51 assembly version
2437 * device/lib/_fs2ulong.c: added mcs51 assembly version
2438 * device/lib/_fs2uint.c: added mcs51 assembly version
2439 * device/lib/_fs2uchar.c: added mcs51 assembly version
2440 * device/lib/_slong2fs.c: added mcs51 assembly version
2441 * device/lib/_sint2fs.c: added mcs51 assembly version
2442 * device/lib/_schar2fs.c: added mcs51 assembly version
2443 * device/lib/_ulong2fs.c: added mcs51 assembly version
2444 * device/lib/_uint2fs.c: added mcs51 assembly version
2445 * device/lib/_uchar2fs.c: added mcs51 assembly version
2446 * device/include/float.h: added #define to select asm vs c
2448 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
2450 * device/lib/printf_fast.c: improvements to float output
2451 * device/include/float.h: add defines for assembly float library
2452 * device/lib/_fsget1arg.c: receive 1 float arg
2453 * device/lib/_fsget2args.c: receive 2 float args (reentrant)
2454 * device/lib/_fsnormalize.c: normalize a float
2455 * device/lib/_fsreturnval.c: return float, various helper routines
2456 * device/lib/_fsrshift.c: right shift a float's mantissa
2457 * device/lib/_fsswapargs.c: swap 2 floats
2458 * device/lib/Makefile.in: build these 6 new files for mcs51
2459 * device/lib/libfloat.lib: add these 6 files to the library
2461 2004-12-26 Borut Razem <borut.razem AT siol.net>
2463 * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
2466 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
2468 * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
2469 and fully reentrant and register bank neutral.
2470 * device/lib/printf_fast.c: added float (not enabled by default),
2471 added compact/slower integer (also not enabled by default),
2472 improved size/speed of fast integer code, other minor changes
2473 * device/include/stdio.h, device/lib/Makefile.in,
2474 device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
2476 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
2478 * src/pic16/pcode.c: declaring variables other than at the start of a
2479 block is not supported in C by VC6.
2481 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
2483 * applied a previous patch from Raphael Neider that wasn't included
2484 in the previous commits, which fixes infinite loops within jumptable
2486 * made some fixes that previous patches introduced
2488 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
2490 * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
2491 that fixes an issue with AOP_PCODE asmop's offset,
2492 * (pic16_popCopyReg): update instance field too,
2493 * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
2494 function of pic port,
2495 * (genCmp, genAnd, genAssign),
2496 * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
2498 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
2500 * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
2501 variables initial values to idata section,
2502 * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
2503 variables in some functions. This utilizes parmBytes field of iCode
2504 structure to hold the offset of the variable in stack. (might be
2505 able to use the stack field too?)
2506 * applied patch from Raphael Neider # ### , # ###
2507 * src/pic16/glue.c (pic16emitRegularMap): fix to print static
2508 variable initial values in idata section,
2509 * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
2510 for static variables with initial value
2511 * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
2512 applied fix in while loop from Raphael Neider.
2514 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
2516 * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
2517 * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
2518 * src/ds390/ralloc.c (serialRegAssign): spill bits
2519 * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
2520 * support/Util/SDCCerr.c,
2521 * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
2522 * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
2523 * support/regression/tests/bitwise.c: added test for bitwise complement(~)
2525 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
2527 * device/include/sdcc-lib.h: inserted LGPL, added includes
2528 asm/ds390/features.h and asm/mcs51/features.h
2529 * device/include/asm/default/features.h,
2530 * device/include/asm/gbz80/features.h,
2531 * device/include/asm/z80/features.h: added empty _AUTOMEM
2533 * device/include/asm/ds390/features.h,
2534 * device/include/asm/mcs51/features.h: added files with defines for
2535 _AUTOMEM and _STATMEM indicating automatic and static storage class
2536 * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
2537 * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
2538 * src/SDCCicode.c (geniCodeCast),
2539 * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
2540 * src/SDCCloop.c (loopInduction): removed unused variable lr
2541 * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
2542 to convertToFcall to include char modulo (RFE 1065037), added check
2543 if left operand is unsigned and use abs of literal value
2544 * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
2545 as it doesn't work after conversion from peephole.def to peephole.rul
2546 * src/mcs51/gen.c (toBoolean): added check for size,
2547 (genModOneByte): optimized code for signed char modulo a literal
2548 power of 2 (thanks to Hubert Sack),
2549 (genRRC): removed unnecessary "clr c",
2550 (genRLC): replaced "add a,acc" with cheaper "rlc a"
2551 * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
2553 swapped rules 256.c and 256.d,
2554 extended 256.d by using new multiple checks (thanks Erik),
2555 added rules 256.e and 256.f,
2556 updated rule 261.a and 261.b to new generated code
2557 * support/regression/tests/muldiv.c: added test div/mod by a power of 2
2559 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2561 * src/SDCCloop.c (basicInduction, loopInduction): fixed several
2562 induction related bugs, including first part of bug #1074377
2564 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
2566 * applied patch from bug-report #1076292,
2567 * applied patches for genAnd and Goto-optimizations for Raphael
2569 * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
2570 dump a less iCode information,
2571 * src/pic16/device.h (pic16_options_t): added field debgen,
2572 * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
2573 DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
2574 * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
2576 * (various functions): added macros FENTRY and FENTRY2 to functions,
2577 to emit function prologue,
2578 * (various functions): fixed indentation,
2579 * (genNearPointerGet): fixed loading of FSR0,
2580 * (genPackBits): applied patch from Raphael Neider to fix updating
2581 of FSR0 and touching only the modified bits,
2582 * src/pic16/genarith.c (various functions): added macros FENTRY to
2583 emit function prologue in comments,
2584 * src/pic16/pcode.h: added functions debugf2, debugf3,
2585 * src/pic16/ralloc.c: partial fix for packForPush caused
2588 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2590 * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
2591 <stsp AT users.sourceforge.net> with reversed byte order
2592 * support/regression/tests/rotate.c: added (ds390 skips some tests)
2594 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2596 * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
2598 * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
2599 * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
2601 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
2603 * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
2605 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2607 * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
2609 (setFromConditionArgs): friendly operand parser for peephole rules,
2610 (operandBaseName, operandsNotRelated): new peephole condition
2611 "operandsNotRelated" -- similar to "operandsNotSame", but takes
2612 architecture specific register naming into account, handles n-way
2613 comparisons, and supports quoted literals
2614 * src/mcs51/peeph.def: restored rule 177.d with an extra condition
2616 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2618 * src/mcs51/peeph.def: fixed bug #1076940
2620 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
2622 * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
2624 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2626 Adding support for replacing ljmps with sjmps in jumptables
2627 generated for switch statements. For now you need to set the
2628 environment variable SDCC_SJMP_JUMPTABLE to enable this.
2629 Now 4 algorithms for mcs51 jumptable generation are used:
2630 ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
2631 addresses loaded pc-relative for up to 112 cases and stack-pushing
2632 target addresses loaded with offset from dptr for up to 256 cases.
2634 * src/SDCCpeeph.c: added peephole conditional labelJTInRange
2635 * src/mcs51/main.c: adapted constants for switch table generation
2636 * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
2638 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
2640 * device/lib/printf_large.c (_print_format): fixed bug 1073386
2641 * support/regression/tests/bug1057979.c: added test for bug 1073386
2643 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
2645 * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
2648 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
2650 * src/pic16/device.h,
2651 * src/pic16/genarith.c,
2654 * src/pic16/pcode.c: applied patches #1068154 and #1070213
2656 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
2658 Large cummulative patch for pic16 port.
2659 * device/lib/pic16/gstack.h: NEW, user can specify its own handler
2660 to call when a stack overflow occurs,
2661 * (malloc.h): added CVS Id tag,
2662 * (pic18f{242,252,442,452}.h): added T0CONbits structure and
2664 * added libc directory. The current version of LibC contains string
2665 functions, ctype functions and macros and some functions of the
2666 stdlib set (like malloc/free/atof/atoi etc...). All functions are to
2667 be extensively tested in the future. Standard disclaimer here.
2668 Library is not automatically build yet. But one can build it by
2669 invoking 'make' inside the libc directory.
2670 * added ADC library under libio. Preliminary version yet.
2672 * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
2673 * src/pic16/gen.c (aopForRemat): asmop size is filled by
2674 aopForRemat() now and not by pic16_aopOp(),
2675 * (pic16_popGetTempReg): removed warning messgae when allocating
2676 temporary registers, its a buggy feature and will be removed,
2677 * (pic16_popGet): set register instance field in AOP_CRY,
2678 * (pic16_outBitC): fixed for results in size greater than 1,
2679 * (genUminusFloat): fixed for pic16, ported code from mcs51,
2680 * (pic16_storeForReturn): optimized return of 0,
2681 * (genCmp): experimental code for new genCmp which uses PIC18's
2682 special compare&skip instructions. Initial tests fail some times
2683 with variables grater than 1 byte in size, so new code is disabled,
2684 * (genUnpackBits, genPackBits): more optimizations in reading/writing,
2686 * (genCast): began a fix to optimize the casting of a bit to another
2687 bit, now assigning a bitfield to another bitfield will fail, sorry,
2688 * src/pic16/main.c: disabled the use of lr-support feature,
2689 * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
2690 * added some function prototypes, added function _debugf prototype,
2691 * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
2692 bits with offset (case PO_GPR_BIT),
2693 * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
2695 * (isBankInstruction): modified to return 0 for no banking instruction,
2696 and 1 for banking instruction,
2697 * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
2698 caused stop processing pCodes after a inline assembly block,
2699 * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
2700 * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
2701 registers when it shouldn't,
2702 * src/pic16/ralloc.c (allocReg): add preliminary support for
2703 supporting a limited set of temporary registers,
2705 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2707 * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
2708 genDataPointerSet): ensure assignments always copy in MSB to LSB
2710 (loadRegFromAop): recognize CLRH optimization,
2711 (genFunction): optimize RECEIVE iCodes in reentrant functions
2713 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2715 * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
2716 --out-fmt-s19 turning into --out-fmt-elf if s19 was already
2718 * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
2719 * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
2720 contiguous with data
2722 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2724 * device/lib/_gptrget.c (_gptrget),
2725 * device/lib/_gptrgetc.c (_gptrgetc),
2726 * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
2727 instead of sjmp to ret
2728 * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
2729 by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
2731 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
2733 * .version: bumped version to 2.4.7
2734 * device/lib/_gptrget.c (_gptrget): is now _naked
2735 * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
2736 * device/lib/_gptrput.c (_gptrput): is now _naked
2737 * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
2738 (createFunction): fixed xstack
2739 * src/SDCCglue.c (emitMaps): set allocation required for bit area
2740 * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
2742 (geniCodeCritical): store original interrupt state in an iTemp bit
2743 var unless stack-auto
2744 * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
2745 * src/SDCCmain.c (setIncludePath): added include/target to search path
2746 * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
2747 * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
2749 (processFuncArgs): put bit vars in bit area
2750 * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
2751 unsaveRBank): fixed xstack,
2752 (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
2753 (genFunction, genEndFunction): fixed xstack,
2754 (genAssign): optimization don't walk backwards through mem
2755 * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
2756 * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
2757 * support/regression/Makefile: also make library (for stack-auto) when
2758 making "all" and added "test-mcs51-xstack-auto"
2759 * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
2760 * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
2761 * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
2762 * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
2763 * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
2764 make-library by MAKE_LIBRARY
2765 * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
2766 regression tests for xstack
2767 * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
2768 * support/regression/tests/critical.c: test for critical on mcs51
2770 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2772 * support/regression/ports/ucz80/spec.mk: use include and lib files from
2773 built version of sdcc instead of installed version
2775 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
2777 * src/mcs51/gen.c (toBoolean): fixed bug 1065458
2778 * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
2780 * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
2781 * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
2782 WARNING: remove device/lib/build/z80/printf.o by hand when
2783 updating from previous build!
2784 * device/lib/z80/printf.c: updated comment
2785 * support/regression/tests/bug1057979.c: test all ports now
2786 * support/regression/tests/bug1065458.c: file added
2788 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2790 * src/z80/gen.c (genFunction, genEndFunction): avoided generating
2791 *_start and *_end symbols for static functions
2793 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
2795 * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
2796 and search crt0.o in all library paths,
2797 (setIncludePath): proper handling of --nostdinc,
2798 (setLibPath): proper handling of --nostdlib
2799 * support/regression/Makefile,
2800 * support/regression/ports/ds390/spec.mk,
2801 * support/regression/ports/gbz80/spec.mk,
2802 * support/regression/ports/hc08/spec.mk,
2803 * support/regression/ports/mcs51/spec.mk,
2804 * support/regression/ports/mcs51-large/spec.mk,
2805 * support/regression/ports/mcs51-stack-auto/spec.mk,
2806 * support/regression/ports/z80/spec.mk: use include and lib files from
2807 built version of sdcc instead of installed version
2808 * doc/sdccman.lyx: fixed typo in --nostdinc
2810 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
2815 * src/pic/gen.c : added support to generate code for struct bit fields.
2817 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
2819 * as/xa51/xa_version.h,
2820 * device/include/errno.h,
2821 * device/include/regc515c.h,
2822 * device/lib/_itoa.c,
2823 * device/lib/_ltoa.c,
2824 * device/lib/ser_ir_cts_rts.c,
2825 * sim/ucsim/xa.src/glob.cc,
2826 * sim/ucsim/xa.src/inst_gen.cc,
2827 * sim/ucsim/xa.src/xa_bit.cc,
2828 * sim/ucsim/xa.src/xa_sfr.cc,
2829 * sim/ucsim/z80.src/inst_dd.cc,
2830 * sim/ucsim/z80.src/inst_fdcb.cc,
2831 * support/scripts/keil2sdcc.pl,
2832 * src/pic16/pic16.dsp,
2833 * src/pic16/pic16a.dsp: corrected cvs line endings
2834 * device/lib/printf_large.c: fixed bug 1057979
2835 * src/pic16/gen.c: fixed non-C standard code
2836 * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
2837 * src/SDCCglobl.h: changed pack_iram to no_pack_iram
2838 * support/regression/ports/mcs51/support.c: reload T1 asap
2839 * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
2840 pdata use and clear idata startup behaviour
2841 * support/regression/tests/bug1057979.c: added
2843 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
2845 * device/examples/ds390/ow390/ad26.h,
2846 * device/examples/ds390/ow390/cnt1d.h,
2847 * device/examples/ds390/ow390/crcutil.c,
2848 * device/examples/ds390/ow390/ownet.h,
2849 * device/examples/ds390/ow390/owsesu.c,
2850 * device/examples/ds390/ow390/swt12.h,
2851 * device/examples/ds390/ow390/swtoper.c,
2852 * device/examples/ds390/ow390/temp10.h,
2853 * device/examples/ds390/ow390/thermodl.c,
2854 * device/examples/ds390/tinitalk/tinitalk.dsp,
2855 * device/examples/ds390/tinitalk/tinitalk.dsw,
2856 * device/examples/mcs51/clock/hw.h,
2857 * device/examples/mcs51/simple2/go.bat,
2858 * device/examples/serialcomm/windows/serial.h,
2859 * device/examples/xa51/dummy.c,
2860 * device/examples/xa51/hello.c,
2861 * device/include/80c51xa.h,
2862 * device/include/at89x051.h: corrected cvs line endings
2864 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
2866 * src/pic16/main.c (options): added command line --gstack, to trace
2867 stack over/under flows,
2868 * added pragma 'wparam' to allow passing first byte of function
2869 parameters via WREG, syntax is #pragma wparam my_function[, func2...]
2870 * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
2871 call to __gstack_test function and sets up the symbol as extern,
2872 * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
2873 * popaop): added call to pic16_testStackOverflow,
2874 * (wParamCmp, inWparamList): NEW, test existence of a symbol in
2876 * (genCall, genPcall): now all parameters are passed via stack
2877 except in functions that are pass to wparam pragma in which WREG is
2879 * (genPcall): REENTRANT flag is checked to see if variable prototype
2880 contains reentrant keyword, don't call a non-reentrant function, via
2881 a reentrant function pointer or vice versa, functions are never
2883 * (genJumpTab): applied patch from bug #1057478 by R.Neider and
2885 * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
2886 SIGSEGV when accessing a NULL register stucture,
2887 * (pic16_printGPointerType): modified to handle UPPER modifier for
2888 function initializers, changed prototype of function to simpler one,
2889 * (pic16_printIvalFuncPtr): check to see if function is already
2890 added in externs list,
2891 * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
2892 optimized a move from W to SFR with a move to the same register
2894 * device/lib/pic16/debug: NEW directory, contains debug features
2895 which are enabled when linking with libdebug.lib, currently command
2896 line option --gstack enables stack pointer tracing for over/under
2897 flow, corresponding sources are in debug/gstack
2899 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
2901 * doc/sdccman.lyx: updated SDCC version,
2902 * (PIC16 port): update list of command line options,
2903 * src/pic16/device.h (structure pic16_options_t): added field gstack
2904 to enable stack overflow tracing on push/pops,
2905 * src/pic16/device.c (statistics structure): added statistics
2907 * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
2908 pic16_dump_int_registers): increase statistics counters for each
2909 * variable which is encountered
2910 * (pic16_dump_usection): emit each .udata variable to its own udata
2912 * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
2913 when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
2914 parameters via stack, otherwise use old scheme,
2915 * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
2916 assembler output file,
2917 * src/pic16/main.c: added command line options --gstack to enable
2918 push/pop tracing for stack overflow,
2919 * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
2920 instructions): added size of each instruction,
2921 * (pic16_countInstruction): estimate size of instructions in
2922 the_pFile list, inline assembly blocks are not counted,
2923 * (pic16_FixRegisterBanking): trace previous register usage, when
2924 banksel optimizations is greater than 0, don't emit a redudant
2927 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
2929 * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
2930 * src/pic16/ralloc.c : applied same fix for pic16.
2931 * src/pic/gen.c : tidied it up a little.
2933 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2935 * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
2936 thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
2938 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2940 * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
2942 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2944 * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
2945 non-reentrant function __modsint in the interrupt function (thus
2946 corrupting math operations during serial I/O)
2947 * device/lib/ser_ir.c: as above, changed buffersize
2948 * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
2950 * doc/Makefile: added option -t for rsync
2952 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2954 * src/SDCCast.h (struct ast),
2955 * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
2957 2004-10-20 Borut Razem <borut.razem AT siol.net>
2959 * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
2962 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
2964 * device/lib/pic16/libsdcc/Makefile: added lregs directory in
2966 * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
2967 support functions to replace long sequences of MOVFF's from access
2968 bank registers to stack and vice versa,
2969 * src/pic16/device.h: added new field opt_flags, where optimization
2970 flags can be set to enable certain features,
2971 * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
2972 * pBlock, (genFunction, genEndFunction): surroung loop for
2973 saving/loading used registers in stack with PC_INFO pCodes,
2974 INF_LREGS. Code in between can then be optimized by pCode optimizer
2975 to support function calls,
2976 * (genDataPointerSet): fixed bug which loaded float fields in
2977 structures with corrupt data,
2978 * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
2979 in a standard way debug info on stderr. Feature used for developing
2981 * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
2982 obsolete chunks of code,
2983 * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
2984 * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
2985 * pic16/src/pcode.c (pic16_newpCodeInfo,
2986 * (pic16_newpCodeOpLocalRegs),
2987 * (pic16_convertLocalRegs2Support): NEW, to support new optimization
2989 * (pic16_pCodeConstString): printing of the initial value of a
2990 symbol as a comment is inhibited since parsing was already done by
2991 copyStr and output is corrupt,
2992 * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
2994 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2996 * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
2998 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
3000 * as/mcs51/lkarea.c: removed old K&R style,
3001 (lnksect): changed check on boundary error,
3002 (lnksect2): changed check on boundary error,
3003 (lnksect2): extend XSTK to end of page if size = 1
3004 * as/mcs51/lkmain.c: removed old K&R style,
3005 (Areas51): create l_IRAM symbol
3006 * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
3007 * device/lib/Makefile.in: renamed model-mcs51-reentrant to
3008 model-mcs51-stack-auto, added model-mcs51-xstack-auto
3009 * device/lib/_mullong.c: added version to be compiled with xstack
3010 * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
3011 * device/lib/mcs51/crtxclear.asm: clear pdata as well
3012 * device/lib/mcs51/crtxstack.asm: fixed comment
3013 * src/SDCCglue.c: maxInterrupts defaults to 0,
3014 (emitMaps): added pdata,
3015 (createInterruptVect): (re)moved default,
3016 (glue): added pdata,
3017 (glue): moved __start__xstack to XSTK with default size 1
3018 * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
3019 and options.float_rent when options.stackAuto is set,
3020 (linkEdit): only write XDATA_NAME if provided on command line
3022 * src/SDCCmem.c: added pdata
3023 * src/port.h: added pdata_name to PORT
3024 * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
3025 (saveRegisters, unsaveRegisters): removed usage of B,
3026 (genMinus): fixed accumulator clash,
3027 (genJumpTab): added comment, this needs another look
3028 * src/mcs51/gen.c: added check for "B in use" paranoia,
3029 added pushB() and popB()
3030 * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
3039 * src/z80/main.c: (reset_regparms) made void parameter explicit and
3040 added PSEG (PAG,XDATA) or NULL to port specifier
3041 * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
3042 * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
3043 (_mcs51_genInitStartup): removed __start__xstack equ,
3044 (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
3045 * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
3046 * src/z80/gen.c (_rleAppend): fixed warnings
3047 * support/regression/tests/zeropad.c: added pdata test
3048 * .version: bumped to 2.4.6
3050 2004-10-17 Borut Razem <borut.razem AT siol.net>
3052 * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
3053 as a part of nightly build
3055 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
3057 * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
3058 WREG holds the first byte function parameters,
3059 * (aopForSym): take special case for symbols which are in FARSPACE
3060 but in CODESPACE too,
3061 * (assignResultValue): modified to take into account _G.useWreg,
3062 * (genCall): don't use wreg for parameter passing when function is
3063 declared as reentrant, too, added optimization INCF to stack
3064 pointer when stack parameter count is 1,
3065 * (genFunction, genEndFunction): refurnished and fixed to not using
3066 wreg for passing parameters when function has varargs or is
3067 reentrant, fixed bug with symbol name compare for generating
3068 functions in absolute address,
3069 * (pic16_storeForReturn): refurnished,
3070 * (genCmp): began writing a new version of the function, not ready
3071 yet, therefore it is disabled,
3072 * (genAssign): do not read code memory when assigning a function to
3074 * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
3075 array of characters, not pointer,
3076 * (pic16initialComments): in debug mode emit an .ident directive for
3078 * (_process_pragma): emit a new warning type (internal to pic16)
3079 when setting stack to default length, emit a similar warning when
3080 placing a function at absolute address and address is not word aligned
3081 * (_pic16_parseOptions): added 'return TRUE' statement,
3082 * (_pic16_linkEdit): if compiling a source, then add the source's
3083 file object, first in the list of objects to link,
3085 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
3087 * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
3088 * src/pic/main.c : removed VC warning.
3089 * src/pic/gen.c : changed comment.
3091 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
3093 * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
3094 reference to a deprecated symbol _GPTRREG was causing failure to
3095 link. Thanks G. M. Gallant for the info.
3097 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
3099 * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
3100 comments for Bugs item #954788.
3102 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
3104 * src/pic16/device.c (pic16_dump_gsection,
3105 * pic16_groupRegistersInSection): handle symbols declared to be in
3106 access bank differently,
3107 * src/pic16/gen.c (struct _G): added field resDirect,
3108 * (aopForSym): if symbol on stack and iCode is '=' and result exists,
3109 send values read from stack directly to result and don't allocate
3111 * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
3113 * (pic16_sameRegsOfs): NEW,
3114 * (freeAsmop): if _G.resDirect is set then do not mark registers as
3115 free because they were not allocated from temporary pool,
3116 * pic16_popRegFromString): workaround to fix a problem with
3117 allocating variables twice or never,
3118 * (genGenPointerGet): using PRODL instead of FSR0H,
3119 * (genGenPointerSet): using POSTDEC1 (that is a stack location)
3121 * (genAssign): take advantage of the _G.resDirect flag,
3122 * (genCast): around line 11844, use mov2f instead of directly
3123 MOVFF'ing between operands to account for literal values,
3124 * src/pic16/genutils.c: some new debug functions for gpsim have been
3126 * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
3127 float with integer part only,
3128 * src/pic16/main.c (_process_pragma): handle pragma udata access to
3129 place variables in access bank
3130 * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
3131 updated sources to reflect recent changes in gen.c
3133 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
3135 * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
3136 sources that searched for headers in installation path, now the
3137 device/include/pic16 is used,
3138 * src/pic16/glue.c (pic16glue),
3139 * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
3140 .line directives if not in debug mode, this suppresses assembler's
3141 warnings for ignored directives
3143 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
3145 * src/port.h: made reset_regparms prototype void parameter explicit.
3146 * src/SDCCsymt.c (processFuncArgs): removed argument "func".
3147 * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
3148 * doc/sdccman.lyx: documented warning disabling and how to use
3149 printf_large to make it print floats.
3150 * device/include/stdbool.h: NEW
3151 * device/lib/_atof.c,
3152 * device/lib/_divuint.c,
3153 * device/lib/_divulong.c,
3154 * device/lib/expf.c,
3155 * device/lib/printf_large.c,
3156 * device/lib/sincosf.c,
3157 * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
3158 * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
3159 a completely reentrant lib.
3161 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
3163 * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
3164 * device/include/pic16/stdio.h: fixed bug with colon
3166 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
3168 * device/include/pic16/stdio.h,
3169 * device/include/pic16/stdlib.h,
3170 * device/include/pic16/math.h: NEW
3171 * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
3172 declared as _naked to reduce overhead
3173 * device/lib/Makefile.in (target port-specific-objects-pic16):
3174 changed * to *.* so to ignore the CVS directory,
3175 * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
3176 stacked variables back in stack,
3177 * (genEndFunction): fixed bug reported by G.M. Gallant with stack
3180 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
3182 * .version: bumped version number to 2.4.5
3183 * support/Util/SDCCerr.h: added warning W_POSSBUG2.
3184 * support/Util/SDCCerr.c (messages structure): added entry for
3187 Large cumulative patch for pic16 port and libraries.
3188 * device/include/pic16/sdcc-lib.h,
3189 * device/include/pic16/stdarg.h,
3190 * device/include/asm/pic16/features.h,
3191 * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
3192 * device/include/pic16/float.h: changes reentrant keyword with
3193 _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
3194 * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
3195 updated target build-libraries to include objects from gptr,
3196 * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
3197 _IL_REENTRANT to all function headings, included sdcc-lib.h header,
3198 * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
3199 all function headings,
3200 * src/SDCCmain.c: added global parameter userIncDirsSet,
3201 * (parseCmdLine): when option -I is encountered add directory to
3203 * src/version.awk: added space between control and long,
3204 * src/pic16/NOTES: added some notes for the port,
3205 * src/pic16/gen.c: added prototype for mov2fp function,
3206 * (fReturnpic16[]): properly named return value registers,
3207 * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
3208 * (aopForSym): added code to handle symbols with onStack flag set,
3209 symbols onStack are allocated PTRSIZE bytes,
3210 * (aopFreeAsmop): handles special case where asmops are stack objects,
3211 * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
3212 * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
3213 added argument lock to trace flaws in allocating temporary registers
3214 when developing port,
3215 * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
3216 * (pic16_popRegFromString): reenabled allocating a direct register
3218 * (assignResultValue): various beautifications,
3219 * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
3220 referenced function argument,
3221 * (genIpush): reenabled to allow stacked arguments, handles only
3222 ic->parmPush iCodes,
3223 * (genCall, genPcall): major changes to allow for variable argument
3224 functions, fixed a bug with falsely restoring stack pointer after
3225 returning from call,
3226 * (genFunction): pending code for critical function,
3227 * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
3228 * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
3229 * (genNearPointerGet): fixed bug with indirect reading, was always
3231 * (genGenPointerGet, genGenPointerSet): rewrote to support generic
3233 * (genAddrOf): rewrote code to take address of a stacked function parameter
3234 * (genCast): fixed casting to generic pointer type,
3235 * src/pic16/gen.h: added AOP_STA,
3236 * (struct asmop): added field stk,
3237 * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
3238 * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
3239 * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
3240 * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
3241 * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
3242 * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
3244 * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
3246 * (pic16_port structure): generic pointer size is set to 3,
3247 * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
3248 * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
3250 * src/pic16/ralloc.c (allocReg): prevent allocating register when
3251 operand is an iTemp,
3253 2004-09-24 Martin Helmling <mh AT octo-soft.de>
3255 * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
3256 * debugger/mcs51/simi.c: addapt new syntax of s51
3258 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
3260 * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
3261 * src/pic16/pcode.c: commented out some calls to free() in order to
3264 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3267 * src/SDCCicode.c (isiCodeInFunctionCall),
3268 * src/avr/ralloc.c (selectSpil),
3269 * src/pic/ralloc.c (selectSpil),
3270 * src/pic16/ralloc.c (selectSpil),
3271 * src/ds390/ralloc.c (selectSpil),
3272 * src/hc08/ralloc.c (selectSpil),
3273 * src/xa51/ralloc.c (selectSpil),
3274 * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
3275 stack in the middle of a function call sequence (fixes bug #1020268)
3276 * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
3277 costs associated with the minimum switch case.
3279 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3281 * src/SDCC.lex: fixed bug #1030549
3283 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3285 * src/SDCCcse.h (struct cseDef),
3286 * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
3287 over a function call if the CSE is derived from a symbol whose
3288 address has been taken (fixes bug #1029883)
3289 * support/regression/tests/bug-1029883: a new regression test for
3292 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3294 * src/hc08/gen.c (emitinline): fixed bug #1029778
3295 * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
3296 to a cast object is no longer a syntax error ("fixes" bug #1030006,
3297 and starts toward RFE #905167)
3299 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
3301 * src/pic16/gen.c (mov2f): New function to move an operand to
3302 another without considering if it is a literal or a register,
3303 * (pic16_sameRegs): don't check if they are both AOP_REG,
3304 * (AccRsh): removed andmask=0 lines,
3305 * (genLeftShift): duplicated to be improved in future versions,
3306 * src/pic16/main.c (_process_pragma): emit stack default size in hex,
3307 * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
3308 in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
3309 * (pic16initMnemonics): added initialization for POC_INFSNZW,
3310 * (insertBankSwitch): fixed inserting banksel directives algorithm
3311 for instructions that follow a skip instruction, this fixes a report
3312 for broken subtraction code generation,
3313 * src/pic16/ralloc.c (deassignLRs): do not free register if current
3314 iCode is a left op, just in case result and right share the same
3317 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3320 * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
3322 * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
3323 * src/mcs51/ralloc.c (packRegisters): removed the patch applied
3324 on 2004-09-12; it was buggy
3326 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
3328 * src/SDCCsymt.h: removed RESULT_CHECK
3333 * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
3335 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
3337 * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
3338 * src/pic16/device.c (pic16_assignConfigWordValues): wrong
3339 configuration values no more rejected by compiler, they are assigned
3340 to configuration registers with a warning message instead,
3341 * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
3342 the for-loop so last conf register is emitted too,
3343 * (_pic16_initPaths): link library libsdcc.lib by default,
3344 * (_hasNativeMulFor): modified test for multiplication according to
3345 Raphael Neider's remarks. Integer multiplication is also done with
3347 * device/include/pic16/pic18fregs.h: corrected type error in while
3348 testing and including 18f6720 header file
3350 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
3352 * src/pic16/device.h (pic16_options): removed field use_crt,
3353 * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
3354 until an optimization to handle single bits is added,
3355 * (pic16_loadFSR0): moved before genUnpackBits,
3356 * (genAnd): some white lines removed,
3357 * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
3358 leave_reset flags in pic16_options when using crt modules,
3360 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
3362 * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
3363 for bugs 898889 & 979599. Also used some safer print instructions.
3365 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
3367 * src/pic16/device.h (pic16_options_t): added field use_crt,
3369 * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
3370 catch a probable future bug,
3371 * src/pic16/gen.c: aopIdx function commented out,
3372 * (genAssign): commented out old code which used aopIdx,
3373 * src/pic16/glue.c (pic16glue): removed some legacy fragments of
3374 code, added if conditionals to take into account the --use-crt
3375 command line options,
3376 * src/pic16/main.c (pic16_optionsTable): added new command line
3377 options, --use-crt= and --no-crt,
3378 * (_pic16_linkEdit): now the proper crt object is added in the
3379 linker command line except than when --no-crt is specified,
3380 * src/pic16/pcode.c,
3381 * src/pic16/pcode.h: added some structures and functions for a new
3382 optimization scheme to compansate for instruction overhead between
3383 same iCodes, this scheme is currently under development and is not
3385 * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
3387 * device/lib/pic16/startup/crt0i.c,
3388 * device/lib/pic16/startup/crt0iz.c: added global char variable
3389 __uflags to force the generation of an idata section
3391 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
3394 * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
3395 * doc/sdccman.lyx: updated sdcc version to 2.4.4
3397 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3399 * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
3400 Frieder) and clarified the default code optimization mode
3402 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3404 * src/SDCC.lex (doPragma, process_pragma),
3405 * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
3406 "opt_code_size", and "opt_code_balanced"
3407 * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
3408 regrouped options by category, added support for category headers
3409 * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
3410 and "--opt-code-size"
3411 * doc/sdccman.lyx: documented these new options and pragmas
3412 * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
3413 preference into account
3415 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
3417 * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
3418 geniCodePreDec): Fixed bug 904237 by generating a warning
3420 * src/SDCCerr.c: added warning W_SIZEOF_VOID
3422 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
3424 * src/pic/device.c : When no max ram set validate full memory range.
3426 * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
3428 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
3430 * device/lib/_gptrget.c,
3431 * device/lib/_gptrput.c: updated comment
3432 * device/lib/calloc.c,
3433 * device/lib/free.c,
3434 * device/lib/malloc.c,
3435 * device/lib/realloc.c: added LGPL, made them reentrant-safe
3436 * src/SDCCcse.c (cseBBlock),
3437 * src/SDCCicode.c (printOperand, geniCodeArray),
3438 * src/SDCCicode.h (struct operand): fixed bug 868103
3439 * support/regression/tests/bug-868103.c: added
3440 * src/SDCCast.c (searchLitOp),
3441 * src/SDCCcse.h (struct cseDef),
3442 * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
3443 * src/SDCCicode.h (struct operand),
3444 * src/SDCCsymt.h (struct sym_link),
3445 * src/avr/gen.c (hasInc),
3446 * src/ds390/gen.c (hasInc),
3447 * src/hc08/gen.c (genPlusIncr, hasInc),
3448 * src/mcs51/gen.c (hasInc),
3449 * src/pic16/glue.c (pic16_printIvalChar),
3450 * src/pic16/ralloc.c (regWithIdx),
3451 * src/xa51/gen.c (hasInc) : removed warnings
3452 * src/SDCCast.c (createBlock): added comment ???
3453 * src/hc08/ralloc.c: updated comments
3455 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3457 * doc/sdccman.lyx: updated section on switch statements, added
3458 section about semaphore locking
3459 * doc/Makefile: added option -info for latex2html
3460 * device/lib/_gptrget.c,
3461 * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
3463 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
3467 * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
3468 maxram is less than 0x100.
3470 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
3472 * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
3474 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3485 * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
3486 a jump table is the best form for a switch statement, including
3487 automatic insertion of missing cases to make the case range
3488 continuous. Developed in collaboration with Frieder Ferlemann.
3490 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3492 * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
3493 accumulator result if it needs sign extension
3495 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
3497 * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
3499 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
3501 * device/lib/gbz80/printf.c,
3502 * device/lib/z80/printf.c: removed define for NULL
3504 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
3506 * as/xa51/xa_link.c,
3507 * device/examples/ds390/ow390/ad26.c,
3508 * device/examples/ds390/ow390/cnt1d.c,
3509 * device/examples/ds390/ow390/counter.c,
3510 * device/examples/ds390/ow390/ds2480.h,
3511 * device/examples/ds390/ow390/ds2480ut.c,
3512 * device/examples/ds390/ow390/findtype.c,
3513 * device/examples/ds390/ow390/gethumd.c,
3514 * device/examples/ds390/ow390/owllu.c,
3515 * device/examples/ds390/ow390/ownetu.c,
3516 * device/examples/ds390/ow390/swt12.c,
3517 * device/examples/ds390/ow390/swtloop.c,
3518 * device/examples/ds390/ow390/temp.c,
3519 * device/examples/ds390/ow390/temp10.c,
3520 * device/examples/ds390/ow390/thermo21.c,
3521 * device/examples/ds390/ow390/tinilnk.c,
3522 * device/examples/ds390/ow390/tstfind.c,
3523 * device/examples/serialcomm/windows/serial.cpp,
3524 * device/examples/serialcomm/windows/test_serialcomm.cpp,
3525 * device/include/reg51.h: fixed line endings for cvs
3527 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3529 * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
3530 packRegsForAccUse, packRegisters): new accumulator register
3532 * support/regression/ports/hc08/support.c (_putchar): suppress
3533 warning of unused variable
3534 * src/SDCCicode.c: added SWAP entry to codeTable
3536 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
3538 * device/lib/sprintf.c: forgot to add this file before previous commit
3540 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
3542 * src/pic16/gen.c (genPackBits): added operand right in function
3543 parameters, load result directly if p_type is POINTER (that is
3544 called by genNearPointerSet)
3545 * (genUnPackBits): added operand left in function parameters,
3546 * (genNearPointerGet, genNearPointerSet): prevent the loading of
3547 FSR0 if accessing bitfields,
3549 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
3551 * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
3552 _print_format; updated printf, sprintf, vsprintf
3553 * device/include/asm/default/features.h: corrected comment/define
3554 * device/lib/Makefile.in: added sprintf.c
3555 * device/lib/libsdcc.lib: added sprintf module
3556 * device/lib/printf_large.c,
3557 * device/lib/vprintf.c,
3558 * device/lib/sprintf.c: totally refactored printf_large and vprintf
3560 * support/regression/Makefile: changed ALL_PORTS into a usefull default
3561 * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
3562 * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
3564 * support/regression/tests/zeropad.c: define idata as data for hc08
3566 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3568 * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
3569 * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
3570 labels are referenced at least once (even if a reference is not found)
3571 * src/hc08/gen.c (emitcode): set isComment flag for comments
3572 * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
3573 loads), rules 6a..6b (optimize jumps to return)
3575 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3577 * device/lib/acosf.c (acosf),
3578 * device/lib/asinf.c (asinf),
3579 * device/lib/atanf.c (atanf),
3580 * device/lib/ceilf.c (ceilf),
3581 * device/lib/cosf.c (cosf),
3582 * device/lib/coshf.c (coshf),
3583 * device/lib/cotf.c (cotf),
3584 * device/lib/fabsf.c (fabsf),
3585 * device/lib/floorf.c (floorf),
3586 * device/lib/log10f.c (log10f),
3587 * device/lib/logf.c (logf),
3588 * device/lib/sinf.c (sinf),
3589 * device/lib/sinhf.c (sinhf),
3590 * device/lib/sqrtf.c (sqrtf),
3591 * device/lib/tanf.c (tanf),
3592 * device/lib/tanhf.c (tanhf),
3593 * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
3594 replaced all instances of "reentrant" in the library functions
3595 defined in math.h with this macro.
3596 * support/regression/tests/float_trans.c: reenabled test for hc08
3598 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
3600 * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
3603 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3605 * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
3606 * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
3607 multi-byte volatile operands are used
3608 * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
3609 * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
3610 initialization to area GSINIT0 so that it would always precede
3611 any static initializers in GSINIT
3612 * support/regression/tests/zeropad.c: fixed idata define for hc08
3613 * support/regression/tests/bug-927659.c,
3614 * support/regression/tests/float_trans.c: disabled tests for hc08
3615 pending missing library routines
3616 * .version: increased version number to 2.4.4 - hc08 port now passes
3620 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
3622 * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
3623 * Makefile.common.in,
3625 * as/hc08/Makefile.in,
3626 * as/mcs51/Makefile.in,
3627 * as/z80/Makefile.in,
3628 * debugger/mcs51/Makefile.in,
3629 * device/include/Makefile.in,
3630 * device/lib/Makefile.in,
3633 * link/z80/Makefile.in,
3634 * packihx/Makefile.in,
3635 * sim/ucsim/main_in.mk,
3636 * sim/ucsim/avr.src/Makefile.in,
3637 * sim/ucsim/doc/Makefile.in,
3638 * sim/ucsim/gui.src/serio.src/Makefile.in,
3639 * sim/ucsim/hc08.src/Makefile.in,
3640 * sim/ucsim/s51.src/Makefile.in,
3641 * sim/ucsim/xa.src/Makefile.in,
3642 * sim/ucsim/z80.src/Makefile.in,
3644 * support/cpp2/Makefile.in,
3645 * support/librarian/Makefile,
3646 * support/makebin/Makefile: added DESTDIR to the install path proposed
3647 by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
3648 * doc/sdccman.lyx: added DESTDIR documentation
3650 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
3652 * src/pic16/gen.c (genFunction, genEndFunction): fixed return
3653 instruction for interrupt handlers, use fast returns when returning
3654 from high priority interrupts
3656 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3658 * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
3660 * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
3661 * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
3662 bugs, ported much of Bernhard's code from mcs51
3663 * src/mcs51/gen.c (genSend),
3664 * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
3665 than one when calling a reentrant function
3666 * device/lib/_mullong.c: defined an alternate struct layout for big
3669 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3671 * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
3674 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3676 * src/SDCCsymt.c (processFuncArgs): make sure parameter types
3677 are sane and complete before asking the port its prefered parameter
3678 passing method (fixes bug #1017633)
3679 * device/lib/hc08/_ret.c: added "data" storage class to _ret2
3682 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3684 * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
3685 problem in bitfields >= 8 bits.
3687 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
3689 * src/SDCCsymt.c: undid changes that were not meant to be committed
3691 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
3693 * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
3695 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
3697 * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
3698 copied and wrong bit got inverted
3700 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3702 * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
3703 genFarPointerSet into genPointerSet; eliminated genFarPointerSet
3704 * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
3705 genFarPointerGet into genPointerGet; eliminated genFarPointerGet
3706 * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
3707 assignments to bitfields at known addresses
3708 * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
3709 reads from bitfields at known addresses
3710 * src/hc08/ralloc.c (packRegisters),
3711 * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
3712 genhc08Code): optimize pointer get values used as conditionals
3713 * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
3716 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3718 * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
3719 genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
3720 * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
3723 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3725 * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
3727 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3729 * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
3732 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
3734 * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
3736 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3738 * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
3741 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
3743 * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
3745 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3747 * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
3748 cases use more compact code.
3750 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
3752 * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
3754 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3756 * src/SDCClrange.c (findPrevUse): fixed bug #1007371
3758 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3761 * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
3762 parameter of changePointer() from symbol* to sym_link*
3763 * src/SDCCast.c (decorateType): call changePointer() for CAST op
3764 * src/SDCCsymt.c (compareType): void* type is castable to other
3765 pointers, but not necesarily an exact match.
3766 * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
3767 is no longer blindly treated as an exact match.
3768 * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
3770 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
3772 * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
3774 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
3779 * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
3781 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
3785 * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
3787 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3789 * src/mcs51/gen.c (emitcode): fixed bug #992819
3791 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
3793 * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
3794 there's no need to make it worse
3796 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3798 * src/mcs51/ralloc.c (deassignLR),
3799 * src/ds390/ralloc.c (deassignLR),
3800 * src/hc08/ralloc.c (deassignLR),
3801 * src/z80/ralloc.c (deassignLR),
3802 * src/pic/ralloc.c (deassignLR),
3803 * src/pic16/ralloc.c (deassignLR),
3804 * src/avr/ralloc.c (deassignLR),
3805 * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
3806 rlivePoint): fixed another part of bug #971834
3808 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3810 * src/z80/main.c: enabled "critical" keyword
3811 * src/z80/mappings.i,
3812 * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
3813 functions (fixes bug #979646)
3814 * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
3816 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3818 * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
3821 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
3823 * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
3824 doesn't disable too much optimizations
3826 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
3828 * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
3830 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
3832 * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
3834 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
3836 * src/pic/gen.c tidied up tabs
3837 * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
3838 * src/pic/main.c tidied up tabs
3839 * src/pic/pcode.c tidied up tabs and disabled verbose code generation
3840 * src/pic/pcoderegs.c tidied up tabs
3841 * src/pic/ralloc.c tidied up tabs
3843 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
3845 * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
3846 to S_FIXED for pic16 port and when symbol is not in level 0,
3847 allocate for S_REGISTER storage class and pic16 port, too,
3848 * src/pic16/device.h: prototype for checkSym,
3849 * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
3850 * (pic16_assignConfigWordValue): test the value and the mask to
3851 validate that the value is suitable for the configuration word,
3852 * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
3853 collect extern declared symbols, don't emit symbol twice, check
3854 first if symbol is in publics set first,
3855 * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
3856 * added command line '--fstack' which enables an experimental
3857 feature for stack access, too buggy to be used yet...
3858 * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
3859 * (pic16_allocDirReg): when register has storage class S_REGISTER
3860 allocate in pic16_dynAccessRegs,
3861 * device/include/pic16/pic18f????.h: modified configuration word
3862 naming convention, words started as CONFIG0H but should be CONFIG1H
3864 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
3866 * device/include/mcs51reg.h: fixed bug 970993
3868 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
3870 * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
3871 * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
3872 * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
3873 * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
3874 * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
3875 * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
3876 error/warning numbers,
3877 added function setWarningDisabled()
3878 * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
3879 * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
3880 _memcmp.c _memmove.c calloc.c realloc.c free.c
3881 * support/regression/tests/malloc.c: added tests for new functionality
3882 * support/regression/tests/zeropad.c: added tests for truncated initializers
3883 and initialized char arrays starting with '\x0'
3884 * src/mcs51/peeph.def: fixed regression, added peephole 177.f
3886 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
3888 * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
3890 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3892 * doc/sdccman.lyx: updated example in section "Absolute Addressing"
3893 * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
3894 peephole 177.e. Thanks to anonymous
3896 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
3898 * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
3899 function isn't used in the source but referenced as a
3900 variable initializer then declare it as extern in .asm file
3902 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
3904 * .version: increased version number to 2.4.3
3906 Adding version extension according to ChangeLog CVS revision
3907 * src/Makefile.in (target all): added dependency 'version.h'
3908 * (rule version.h): added rule to create version.h from ChangeLog,
3909 * (rule dep): added dependency version.h,
3910 * src/version.awk: AWK script to create version.h
3911 * src/SDCCdwarf2.c (dwWriteModule),
3912 * src/SDCCglue.c (initialComments),
3913 * src/SDCCmain.c (printVersionInfo): modified to write after
3914 version string the version extension number,
3915 * src/SDCCutil.c: included "version.h"
3916 * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
3918 * src/SDCCutil.h: added prototype for getBuildNumber
3920 * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
3921 includeDirsSet, too,
3922 * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
3923 const char [] is found in function prototype...
3925 * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
3926 moving to WREG with source is already in WREG,
3927 * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
3928 * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
3929 * (aopForSym): stack'ed symbols are partially supported, added
3930 if-clause to support symbols in FARSPACE,
3931 * (sameRegs): added test for AOP_ACC to see if registers are same,
3932 * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
3933 * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
3934 * (pic16_popRegFromString): will not allocate a new register if it
3935 doesn't find one by name, bug may have introduced...
3936 * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
3937 * (genIpush): revived to use pic16 port's stack,
3938 * (genAddrOf): added incomplete case for stack'ed operand,
3939 * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
3940 * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
3941 can handle multibyte operands,
3942 * src/pic16/glue.c (pic16_printIval*): some debug info added,
3943 * (pic16initialComments): added message for MPLAB compatibility
3945 * src/pic16/main.h: prototype for pic16_mplab_comp,
3946 * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
3947 which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
3948 * (_pic16_linkEdit): NEW, handles link stage, transferred here
3949 because of increased complexity of procedure,
3950 * (_process_pragma): stack pragma changed to format 'stack pos len',
3951 emit symbol '_stack_end' to conform with gplink,
3952 * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
3953 to search for register,
3954 * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
3956 * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
3957 #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
3958 * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
3959 case for PO_GPR_REGISTER,
3960 * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
3961 dies, the new era is ahead !...
3962 * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
3963 pic16_dynInternalRegs,
3964 * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
3965 * (pic16_allocDirReg): minor optimizations and bug fixes,
3966 * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
3968 * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
3969 load stack and frame pointer with address of 'stack_end' symbol
3971 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
3973 * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
3974 without source code but only variable initializers
3976 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
3978 * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
3979 external are not declared as extern to reduce overhead while linking
3981 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
3983 * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
3985 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
3987 * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
3988 Yee Keat for the patch
3989 * src/SDCCast.c (decorateType): fixed bug #979599
3990 * src/ds390/gen.h: removed local fReturnSizeDS390
3991 * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
3992 * src/ds390/gen.c (genAnd, genOr, genXor),
3993 * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
3995 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
3997 * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
3998 add relFilesSet to $3, manipulate $2 to handle linking of object
3999 files without source files in command line,
4000 * device/include/pic16 (all headers): added ID location macros,
4001 * src/pic16/device.c (struct PIC16_device Pics16[]): added field
4002 entries for ID location bytes,
4003 * (pic16_assignIdByteValue): NEW,
4004 * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
4005 added field dumpcalltree to pic16_options_t,
4006 * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
4007 is used instead of pic16_Gstack_base_addr, check if (ifx) before
4008 emitting rFalseIfx label after check_carry label,
4009 * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
4010 pic16_emitDIRegs), NEW
4011 * (pic16glue): dump .calltree file when option --calltree found,
4012 * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
4013 * (_pic16_genAssemblerPreamble): emit ID locations after
4014 configuration registers,
4015 * (pic16_linkCmd): modifications of the link command,
4016 * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
4017 * (pic16_pCodeInitRegisters): don't init stack registers,
4018 * (pic16_findPrevInstruction): fixed bug,
4019 * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
4020 bug with immediate registers,
4021 * (buildCallTree): traces stack push and pop,
4022 * (pct2): dump also stack usage for each function,
4023 * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
4024 * (pic16_allocDirReg): various modifications,
4025 * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
4028 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
4030 * src/pic16/pcode.c: removed buggy double colon
4032 2004-07-01 Borut Razem <borut.razem AT siol.net>
4034 * support/scripts/sdcc.nsi: added include/pic16 to setup
4036 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
4038 * device/lib/Makefile.in: fixed bug in target objects-pic16,
4039 * device/lib/pic16/Makefile: prefixed with dash (-) command under
4041 * doc/sdccman.lyx: changed version to 2.4.2 and added some port
4042 specific command line arguments. Also added sample lkr script
4043 for placing a variable at a specific memory bank.
4044 * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
4045 at a specific memory bank,
4046 * (pic16_dump_isection): fixed bug which caused string literals to
4047 be omitted when dumping idata section,
4048 * (pic16_groupRegistersInSection): added code to handle registers
4049 in specific memory banks,
4050 * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
4051 public, all references are renamed too,
4052 * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
4054 * (pic16_storeForReturn): added case to handle when dest is WREG,
4055 * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
4056 * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
4057 pic16_rel_udata, check to see if that register is marked as being
4058 a member of a specific memory bank,
4059 * (pic16_printIvalCharPtr): added code to add string literals either
4060 to code or the idata sections,
4061 * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
4062 also accept the 'udata' pragma,
4063 * src/pic16/main.h: new structure types sectName and sectSym
4064 * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
4065 * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
4066 * (pic16_findPrevInstruction): fixed, it returned nothing,
4067 * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
4068 instruction combinations,
4069 * (pic16_FixRegisterBanking): heavily reorganised,
4070 * (pic16_AnalyzeBanking): if generating banksel directives is
4071 disabled, then don't call FixRegisterBanking at all,
4072 * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
4074 * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
4076 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
4078 * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
4079 Phuah Yee Keat <yk.phuah AT nestac.com>
4081 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
4083 * src/pic16/glue.c (pic16createInterruptVect): function now emits
4084 correctly the IVT even if it is relocated to some other location
4086 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
4088 * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
4089 * device/include/pic16/pic18f2220.h: NEW,
4090 * device/lib/pic16/libdev/pic18f2220.c: NEW,
4091 * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
4092 * src/pic16/device.c (struct Pics16): added info for 18f2220,
4093 * src/pic16/device.h (struct pic16_options): added ivt_loc and
4094 nodefaultlibs, ivt_loc is the location of the interrupt vector
4095 table, and nodefaultlibs signs that default libraries should not be
4096 linked in link stage,
4097 * src/pic16/gen.c (genFunction): relocate interrupt vector functions
4098 according to --ivt-loc argument,
4099 * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
4100 when pragma stack is found,
4102 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4104 * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
4105 256 (range check), 257 (do while), 258.a-f (bit banging
4106 f.e. on 3-wire SPI bus)
4108 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4110 * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
4111 variables used exclusively within a loop
4113 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
4115 * src/mcs51/gen.c (genCpl): quick fix for bug #974835
4117 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4119 * src/SDCClrange.c (computeClash): fixed bug #971834
4121 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4123 * src/mcs51/gen.c (genCmp): fixed bug #975903
4124 * src/hc08/gen.c (operandsEqu),
4125 * src/ds390/gen.c (operandsEqu),
4126 * src/z80/gen.c (operandsEqu),
4127 * src/pic/gen.c (operandsEqu),
4128 * src/pic16/gen.c (operandsEqu),
4129 * src/mcs51/gen.c (operandsEqu): fixed bug #976283
4130 * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
4132 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4134 * src/SDCCcse.c (cseBBlock): fixed bug #966963
4136 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
4138 * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
4139 default case in switch statement,
4140 * glue.c (pic16_initPointer): expr is initialised via decoarteType
4141 to eliminate problem with initialisation of pointers, but problem
4143 * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
4144 * (emitStaticSegment): removed various lines emitting debug info,
4145 * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
4146 added processor registers for utilizing EEPROM,
4147 * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
4148 configurable and set 8
4150 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
4152 * .version: increased version number to 2.4.2,
4154 Cumulative patch for pic16 port
4155 * src/pic16/device.c: changed scheme to dump initial values for
4156 variables in idata segment, all print_idata* functions were removed,
4157 now the pic16_printIval* will be called,
4158 * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
4159 * _pic16_printPointerType, pic16_printPointerType,
4160 * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
4161 * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
4162 NEW, similar to the respective functions in SDCCglue.c,
4163 * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
4164 way, emitting hex bytes,
4165 * (pic16_emitDS): NEW, emits a string for pointer initialisation,
4167 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4169 * src/avr/ralloc.c (serialRegAssign),
4170 * src/xa51/ralloc.c (serialRegAssign),
4171 * src/pic/ralloc.c (serialRegAssign),
4172 * src/pic16/ralloc.c (serialRegAssign),
4173 * src/hc08/ralloc.c (serialRegAssign),
4174 * src/z80/ralloc.c (serialRegAssign),
4175 * src/ds390/ralloc.c (serialRegAssign),
4176 * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
4178 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4180 * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
4181 * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
4183 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
4185 Cumulative patch for pic16 port:
4186 * src/pic16/device.h (typedef PIC16_device) modified fields for
4187 defining microcontrollers,
4188 * src/pic16/device.c: added new info for all devices in Pics16 array,
4189 * src/pic16/gen.c (genPcall): fixed bug that caused the return label
4190 to be optimised out by the pCode optimiser,
4191 * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
4192 specially, bug reported by G.M. Gallant,
4193 * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
4194 as force'd so that cannot be optimised out by pCode optimiser,
4195 * src/pic16/pcode.c,
4196 * src/pic16/pcodepeeph.c,
4197 * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
4198 they are disabled by default, but can be enabled explicit with
4199 command argument --denable-peeps, for testing,
4200 * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
4201 --pomit-ivt in COMPILE_FLAGS
4203 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
4205 * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
4208 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
4210 * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
4212 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4214 device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
4215 0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
4217 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
4219 * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
4220 would only assign 0x300001 register.
4222 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
4224 * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
4225 in COMPILE_FLAGS. Thanks to G. Gallant for report.
4227 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4229 * doc/sdccman.lyx: minor changes, mentioned beta vendor support
4231 * src/mcs51/peeph.def: ran unexpand -a over peeph.def
4232 * src/mcs51/peeph.def: removed obsolete peephole 100.a,
4233 added peephole 254 (left shift), 255 (jump table)
4235 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
4237 * device/lib/Makefile.in: removed comment line with model-pic16,
4238 * (target port-specific-objects-pic16): the libraries and objects
4239 are copied to the build directory form the device/lib/pic16/bin
4242 Cumulative patch concerning pic16 port:
4243 * library directory has been re-organized,
4244 * added support for PIC18F1220,
4245 * added headers and library sources for chips 18f1220,18f6520,
4246 18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
4248 * configuration registers setting has changed, now each supported
4249 device has a complete description of the registers it uses,
4250 * all initialisations are moved to idata sections, these section
4251 can be absolute or relocatable,
4252 * fixed initialisation of codespace variables,
4253 * fixed warning about PCLATU and gpsim,
4254 * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
4255 * (genAssign): use table reads when assigning from variables in codespace,
4256 * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
4257 char/int variables placed in codespace,
4258 * (pic16_emitConfigRegs): NEW, emits a list with configuration
4259 registers set in .asm file, no need for --pomit-config-words anymore,
4260 * (pic16glue): some 8051 legacy segments are commented out
4261 (to be removed completely),
4262 * added support for alternative assembler and linker with --asm=
4263 and --link= command line arguments,
4264 * peepholes are disabled automatically in the port, no need to
4265 specify on command line,
4266 * port supports natively char/int/long multiplication, but converts
4267 all divisions to support functions,
4268 * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
4269 to the file set in variable $2,
4270 * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
4271 strings in ASCII format and not in hex,
4272 * ralloc.c (serialRegAssign): added a triplet of conditional calls
4273 to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
4274 allocate proper register if iCodes aren't temporary,
4276 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
4278 * support/regression/tests/zeropad.c: added TEST_G macro for alpha
4280 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
4282 * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
4285 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4287 * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
4288 computed address is reused
4289 * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
4290 multi-byte bitfields
4292 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
4294 * src/z80/gen.c: (genArrayInit): must check for pointers too
4296 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
4298 * support/regression/tests/zeropad.c: never meant to commit the
4299 nestedstruct test: removed, added check for GCC version
4301 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
4303 * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
4304 * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
4305 * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
4306 printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
4307 bugs 928906 and 954082 half-empty initializers
4309 * src/SDCCsymt.c (getAllocSize): added for above fix
4310 * src/z80/gen.c (genArrayInit): fixed bug 741044
4311 * support/regression/tests/zeropad.c: added tests
4313 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
4315 * src/pic16/device.c (pic16_dump_section): corrected bug which
4316 caused some symbols of the libraries to be misplaced
4318 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
4321 * src/pic16/ralloc.h,
4322 * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
4323 to fix conflict with pic port
4325 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
4327 * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
4328 externs configuration variables,
4329 * src/pic16/ralloc.h,
4330 * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
4331 prototype in header, commented out some debug messages
4333 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
4337 * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
4338 for gpasm COFF object generation. Thanks to D. Hawkins for
4341 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4344 * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
4345 Brock for spotting this)
4346 * src/ds390/gen.c (genEndFunction),
4347 * src/mcs51/gen.c (genEndFunction): always save psw if function is an
4348 interrupt handler and critical. Disable push/pop optimizations when
4349 peephole optimizations disabled.
4351 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
4353 Updated pic16 library sources and headers.
4354 * device/lib/pic16/pic18f*/ ,
4355 * device/include/pic16/*.h: modified to handle structured SFR
4358 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
4360 * src/port.h (PORT structure): added hook initPaths, now each
4361 port can declare its own default search paths,
4362 which can been seen with the --print-search-dirs option,
4363 see pic16 port for example,
4364 * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
4365 setDataPaths): test to options.printSearchDirs is ifdef'ed out,
4366 * (doPrintSearchDirs): NEW, replaces in a central manner the
4367 printing of search dirs which was split in set*Paths functions,
4368 * (main): added call to port->initPaths and doPrintSearchDirs,
4373 * src/izt/tlcs900h.c,
4376 * src/pic16/main.c: modified port structures to reflect addition of
4379 * src/pic16/device.c (regCompare): registers are finally sorted by name,
4380 * (pic16_dump_section): for registers in same address reserve memory once,
4381 * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
4383 * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
4384 result is greater in size than right or left,
4385 * (pic16_genUMult8X8_8): there are some cases where the result can
4386 be 16 bits size, so handle these,
4387 * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
4388 * (pic16_outBitC): modified to emit pcodes,
4389 * (pic16_storeForReturn): using is_LitOp to see if operand is literal
4391 * (genDivOneByte): implemented algorithm to divide 8-bits,
4392 * (genCmp): uncommented goto, but issues still exist,
4393 * (genAnd): fixed a bug with variables >8bits,
4394 * (genPackBits): optimization added that uses BCF/BSF to change a
4396 * (genAssign): fixed bug when assigning floating point literals,
4397 * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
4398 __sdcc_gsinit_startup label,
4399 * src/pic16/main.c (_pic16_init): removed search directory
4401 * (_pic16_initPaths): NEW, used to initialise search directories,
4402 * (_hasNativeMulFor): support functions for all except char/int
4403 multiplication, and char division,
4404 * (PIC16_port struct): modified entry for native mul support,
4405 * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
4407 * (buildCallTree): call to register_usage is ifdef'ed out,
4409 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4411 * device/include/string.h: applied Stas Sergeev's patch to make this
4412 header file compatible with the preprocessor -Wundef option
4413 * src/SDCCmain.c (main): abort compilation if preprocessor reports
4414 failure (fixes bug #941458)
4416 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4418 * src/SDCCopt.c (killDeadCode): fixed bug #907733
4419 * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
4420 that the variable, not the function, should be static
4421 * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
4422 to be consistent with non-literal case
4424 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4426 * src/SDCCast.c (isConformingBody): fixed bug #949967
4427 * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
4428 convilong): fixed bug #952086
4430 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4432 * src/SDCCmem.c (allocVariables): fixed bug #955321
4434 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4436 * src/hc08/main.c (_hc08_genAssemblerEnd),
4437 * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
4438 dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
4439 completely eliminated the use of a temporary file
4440 * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
4441 when more than one file linked
4442 * src/SDCCloop.c (pointerAssigned): fixed bug #954163
4444 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4446 * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
4447 which fixes bug #543481
4448 * support/regression/tests/bug-751703.c: fixed comments left from a
4450 * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
4451 * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
4452 * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
4454 * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
4455 * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
4456 are now changed to underscores in moduleName
4458 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4460 * as/mcs51/lkmem.c: better fix for bug #954173
4462 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
4463 committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4465 * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
4466 * device/include/c8051f000.h,
4467 * device/include/c8051f120.h,
4468 * device/include/c8051f300.h,
4469 * device/include/c8051f310.h,
4470 * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
4473 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4475 * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
4476 and mailing lists, doc'ed --no-peep-comments, removed reference
4477 to knoppix (newest version has no LyX/LaTeX), other minor changes
4478 * src/SDCCglue.c (glue): save 2 bytes stack space with
4479 option --main-return. The ljmp could probably be avoided too
4481 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4483 * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
4485 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4487 * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
4488 * src/SDCCopt.c (isLocalWithoutDef),
4489 * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
4490 which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
4491 (credit to Maarten Brock for patch #949363, on which this is based)
4492 * support/regression/tests/bug-751703.c: some test cases of extern used
4493 within inner scopes.
4495 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4497 * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
4499 * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
4501 * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
4502 dwWriteLabel): fix to create valid debugger symbols even when
4503 the module name has non-alphanumeric symbols in it
4504 * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
4505 when a variable's allocation has been optimized away
4508 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4510 * src/hc08/gen.c (hc08_emitDebuggerSymbol),
4512 * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
4514 * src/ds390/gen.c (ds390_emitDebuggerSymbol),
4516 * src/z80/gen.c (z80_emitDebuggerSymbol),
4518 * src/pic/gen.c (pic14_emitDebuggerSymbol),
4520 * src/pic16/gen.c (pic14_emitDebuggerSymbol),
4522 * src/avr/gen.c (avr_emitDebuggerSymbol),
4524 * src/xa51/gen.c (xa51_emitDebuggerSymbol),
4526 * src/SDCCdebug.c (emitDebuggerSymbol),
4528 * src/port.h: added a debugger struct to the port struct. Added a
4529 callback for defining debugger symbols
4531 * src/SDCCast.c (createLabel),
4532 * src/SDCC.y (labeled_statement): mark all compiler generated labels
4535 * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
4536 iCode back to the ast for the function
4538 * src/hc08/ralloc.c (hc08_assignRegisters),
4539 * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
4540 unneeded fields from the regs struct.
4541 * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
4542 pushReg() & pullReg() functions instead of emitcode()
4544 * src/hc08/gen.c (genLabel, genhc08Code),
4545 * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
4547 * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
4550 * src/hc08/gen.c (genEndFunction, genhc08Code),
4552 * src/mcs51/gen.c (genEndFunction, gen51Code),
4554 * src/ds390/gen.c (genEndFunction, gen390Code),
4556 * src/z80/gen.c (genEndFunction, genZ80Code),
4559 * src/pic/gen.c (genEndFunction, genpic14Code),
4561 * src/pic16/gen.c (genEndFunction, genpic16Code),
4563 * src/avr/gen.c (genEndFunction, genAVRCode),
4565 * src/xa51/gen.c (genEndFunction, genXA51Code),
4567 * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
4568 specific code to cdbFile.c and out of the backend code generators
4570 * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
4571 * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
4572 starting address is now 0
4576 * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
4577 assembler directive for DWARF support
4578 * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
4582 * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
4584 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4586 * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
4587 and inappropriate peephole optimization in jump tables
4589 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4592 * src/SDCCglue.c: sdccopt works for the hc08 port now
4594 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
4596 * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
4598 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4600 * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
4602 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4604 * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
4608 * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
4609 comments from the peephole optimizer replacement rules
4610 * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
4612 * src/SDCCcse.c (updateSpillLocation),
4613 * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
4615 * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
4616 * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
4617 objects far pointers
4619 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4621 * src/SDCCsymt.h: a missing part of my last change
4622 * src/pic/ralloc.c (regTypeNum),
4623 * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
4625 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4628 * src/SDCCicode.c (aggrToPtrDclType),
4630 * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
4631 ptrPseudoSymConvert),
4632 * src/pic/ralloc.c (regTypeNum),
4633 * src/pic16/ralloc.c (regTypeNum),
4634 * src/hc08/ralloc.c (regTypeNum),
4635 * src/ds390/ralloc.c (regTypeNum),
4636 * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
4637 creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
4639 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4641 * link/z80/lkmain.c (afile),
4642 * as/hc08/lkmain.c (afile),
4643 * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
4644 prevent a pointer problem when a filename has no directory and
4645 no extension specified.
4647 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4649 * link/z80/lkmain.c (afile): allow periods in directory names
4650 * link/z80/lkmain.c (afile),
4651 * as/mcs51/lkmain.c (afile),
4652 * as/hc08/lkmain.c (afile): allow linker script file to have an
4653 extension other than ".lnk"
4654 * link/z80/lklex.c (getfid),
4655 * link/z80/lkmain.c (parse),
4656 * as/mcs51/lklex.c (getfid),
4657 * as/mcs51/lkmain.c (parse),
4658 * as/hc08/lklex.c (getfid),
4659 * as/hc08/lkmain.c (parse): Support comments in the linker script
4660 file on lines by themselves and after filenames
4662 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4664 * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
4666 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4668 * src/z80/peeph-z80.def: removed some peephole rules that don't
4669 work with multibyte arithmetic (fixed bug #937126)
4670 * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
4671 to registers and not global variables
4672 * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
4673 geniCodePreInc, geniCodePostDec, geniCodePreDec,
4674 geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
4675 checking for assignments not internally generated (fixed bug #931895)
4676 * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
4677 structure member (fixed bug #930072)
4679 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4681 * src/SDCCmain.c (linkEdit),
4682 * src/hc08/main.c (_hc08_parseOptions),
4683 * as/hc08/Makefile.in,
4687 * as/hc08/lkrloc.c (relr, rele),
4688 * as/hc08/lkarea.c (lnkarea)
4689 * as/hc08/lkmain.c (afile, parse),
4690 * as/hc08/lkelf.c: support for ELF output
4691 * as/hc08/lks19.c (s19),
4692 * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
4694 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4696 * as/mcs51/lkihx.c: Fixed bug #899105.
4698 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4700 * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
4701 .dsp files from Unix to DOS.
4703 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4705 * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
4706 function pointers; we have been compliant for several months now.
4707 * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
4708 change that was accidently commented out
4709 * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
4710 genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
4713 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4715 * src/hc08/gen.c: output of all of the internal debugging information
4716 is now controlled by the D() macro; it is disabled by default
4718 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4720 * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
4721 harder to keep the same registers during a CAST iCode
4722 * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
4723 long via int can be done in a single cast, if the signedness is
4725 * support/regression/tests/bug-927659.c: fixed to avoid conflict with
4726 putchar() in tinibios.c in ds390's library
4728 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
4730 * src/SDCCast.c (decorateType): fixed bug #898889,
4731 cast result of a literal complement too
4732 * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
4733 fixed check for bitfields
4735 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
4737 * src/SDCCicode.c (geniCodeLogic): made it static,
4738 (geniCodeLogicAndOr): added in order to fix bug #905492,
4739 (ast2iCode): fixed bug #905492
4740 * support/regression/tests/bug-905492.c: added
4741 * src/SDCCast.c (decorateType): don't decorate/process parms twice,
4742 (processParms): fixed bug #927659: don't copy parms, this will clear
4744 * support/regression/tests/bug-927659.c: added
4746 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
4748 * src/SDCCast.c (addCast): don't cast float to char
4749 * device/lib/libsdcc.lib: added _memmove
4751 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
4753 * device/lib/large/Makefile: fixed parallel execution by
4754 replacing `make` by `$(MAKE)`
4756 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4758 * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
4759 offsets (fixes bug #923936)
4761 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
4763 * device/lib/small/Makefile: fixed parallel execution by
4764 replacing `make` by `$(MAKE)`
4766 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
4768 * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
4770 2004-03-23 Scott Dattalo <scott AT dattalo.com>
4772 * src/pic/gen.c (genCpl): multi-byte complements were not working.
4773 * src/regression/Makefile: Regression test was not running.
4775 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
4777 * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
4778 complement if possible
4779 * src/SDCCval.c (valComplement),
4780 * src/SDCCicode.c (operandOperation): fixed complement of literal
4781 * support/regression/tests/onebyte.c (testComplement): added
4783 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
4785 * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
4786 return an optimized tree; actually replace actParm with the new tree
4787 * src/SDCCast.h: added some parantheses to remove side effects
4788 * support/regression/tests/bug-920866.c
4790 2004-03-21 Scott Dattalo <scott AT dattalo.com>
4791 * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
4792 Bit operands were not being handled properly in the pic14 port.
4793 (now src/regression/add.c passes again).
4795 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4797 * src/SDCC.y (labeled_statement): case and default no longer require
4798 a following statement (RFE #893037)
4800 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4802 * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
4803 use MOVA macro to avoid "mov a,acc" when peephole optimizer is
4804 disabled (fixes bug #916294)
4805 * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
4806 "mov a,acc"; patch provided by Lenny Story
4807 * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
4809 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4811 * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
4813 * src/ds390/gen.c (genFunction, genEndFunction),
4814 * src/ds390/ralloc.c (ds390_assignRegisters),
4815 * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
4816 * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
4817 pushed if there are parameters passed on the stack. Also, a cleaner
4818 way to decide if r0/r1 should be pushed/popped. (Together they fix
4821 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4824 * device/lib/mcs51/crtpagesfr.asm,
4825 * device/lib/mcs51/crtxinit.asm,
4826 * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
4827 to avoid confusion with Si Lab's SFRPAGE register.
4829 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4831 * src/SDCCglue.c (emitMaps): allow public sfr variables
4832 * src/SDCCglue.c (initialComments): include compiler build date
4833 with compiler version and put the timestamp of the generated
4834 assembly file on a serperate line to be less confusing.
4835 * src/port.h: added genInitStartup hook
4842 * src/z80/main.c: genInitStartup initialize as NULL (default to
4843 historical behaviour)
4844 * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
4845 * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
4846 _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
4847 library instead of hard coding it into the compiler.
4848 * support/regression/ports/mcs51-stack-auto/spec.mk,
4849 * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
4850 * device/lib/mcs51/Makefile,
4851 * device/lib/small/Makefile,
4852 * device/lib/large/Makefile,
4853 * device/lib/mcs51/crtpagesfr.asm,
4854 * device/lib/mcs51/crtstart.asm,
4855 * device/lib/mcs51/crtxclear.asm,
4856 * device/lib/mcs51/crtxinit.asm,
4857 * device/lib/mcs51/crtclear.asm,
4858 * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
4859 startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
4860 and into user configurable files.
4861 * device/lib/clean.mk: clean mcs51 directory too
4862 * support/regression/tests/longlit.c: added static to T1 declaration
4863 * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
4864 accesses in the initialization code
4866 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4868 * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
4869 OSCTRIMVAL as noted in bug #916008
4871 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4873 * src/SDCCloop.c (basicInduction): fixed bug with loop induction
4874 in loops with multiple exits (reported as incorrect registers
4875 used by Martin Helmling in Sdcc-user list)
4877 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4879 * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
4880 made ds390 register extensions look less like error messages
4882 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4884 * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
4885 reported by Adam Wozniak in Sdcc-user list
4887 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
4889 * src/SDCCast.c (decorateType): fixed with bug and promotion in
4890 arithmetic optimizations, added debug output
4892 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
4894 * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
4895 * sdcc.spec: updated and split sdcc into 3 rpms
4896 * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
4897 needed for literals of LEFT_OP and '+'
4898 * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
4899 introduced RESULT_TYPE_NOPROM
4900 (geniCodeMultiply): fixed logic for decision if mul is optimized to
4902 * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
4903 limited promotion to int only for '*'
4904 * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
4906 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
4908 * src/pic16/gen.c (genSkip),
4909 (genc16bit2lit), (gencjneshort): commented out
4910 (is_LitOp): new helper function, checks operand type
4911 (genCmpEq): rewritten
4913 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
4915 * support/regression/tests/bug-908454.c: added
4917 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
4919 * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
4920 * src/SDCCicode.c (usualBinaryConversions): op needs int type
4921 (geniCodeCast): cosmetic, don't preserve bit storage class
4922 (geniCodeLeftShift): added promotion
4923 (geniCodeLogic): fixed regression
4924 * src/SDCCsymt.c (computeTypeOr): accept bits too
4925 (compareType): 2nd part of fix for bug #908454, needed for bitfields
4927 2004-03-07 Borut Razem <borut.razem AT siol.net>
4929 * support/Util/findme.c: alloca() replaced with malloc()/free() pair
4931 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
4933 * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
4934 version of pic16_genPackRegisters which does not check if ic is a
4936 * src/pic16/gen.c (ifxForOp): disabled new and untested code in
4937 function cause string1.c regression test fails
4939 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
4941 * sim/ucsim/configure.in,
4942 * sim/ucsim/configure,
4943 * sim/ucsim/doc/Makefile.in: use docdir
4944 * src/SDCC.y: fixed sbit atrributes
4945 * src/SDCCast.c (getResultTypeFromType): added support for bitfields
4946 * src/SDCCast.c (decorateType): |^& need special promotion handling
4948 * src/SDCCsymt.h: moved definition of RESULT_TYPE
4949 * src/SDCCsymt.h (computeType),
4950 * src/SDCCicode.c: computeType() needs op
4951 * src/SDCCsymt.c (checkTypeSanity),
4952 * doc/sddman.lyx: "plain" bitfields are unsigned
4953 * src/SDCCsymt.c (computeTypeOr): added
4954 * src/SDCCsymt.c (computeType): added support for bitfields, fixed
4956 * src/SDCCval.c (val*): computeType() needs op
4957 * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
4958 * support/regression/tests/onebyte.c: added tests for |^&
4960 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
4962 * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
4963 for writing icode into asm output.
4965 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
4967 * src/pic16/device.c: added some debug lines enabled
4968 with macro DEBUG_CHECK,
4969 * src/pic16/genarith.c: more debug in genPlus,
4970 * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
4971 * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
4972 * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
4973 * (aopForSym): onStack symbols are re-placed in data memspace,
4974 and onStack flag is cleared,
4975 * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
4976 copy temporary pcodeop,
4977 * (genPcall): added warning for not updating PCLATU,
4978 * (genFunction): removed test with IFFUNC_CALLEESAVES, its
4979 always true for pic16 port,
4980 * (genMultOneWord): NEW, supports integer multiplication,
4981 * (genMult): modified to call genMultOneWord,
4982 * (ifxForOp): added warning when return NULL,
4983 * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
4984 flag is set before call to operandFromSymbol for implicit
4986 * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
4987 options.intlong_rent are set by default,
4988 * (_hasNativeMulFor): modified to allow port generation of integer
4990 * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
4991 set regtype to REG_SFR for all registers, restricting seting the
4992 accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
4994 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4996 * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
4997 more than 500 times in the regression tests
4999 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5001 * support/Util/SDCCerr.h,
5002 * support/Util/SDCCerr.c,
5003 * src/SDCC.y (struct_or_union_specifier, enum_specifier,
5005 * src/SDCCsymt.c (addSymChain): show location of oriignal definition
5006 for symbol conflicts.
5007 * support/valdiags/tests/enum.c,
5008 * support/valdiags/tests/tentdecl.c,
5009 * support/valdiags/tests/struct.c: expect possible error messages
5010 referring to original symbol definitions.
5011 * src/SDCC.y (struct_or_union_specifier, struct_declarator),
5013 * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
5015 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
5017 * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
5019 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
5021 * src/pic16/ralloc.c (newReg): fixed bug #908929
5023 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5025 * src/ds390/gen.c: added missing #include "main.h"
5027 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
5029 * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
5030 checking if symbol is already in set,
5031 * src/pic16/device.h: prototype for checkAddSym,
5032 * src/pic16/gen.c: (_G): added entry interruptvector,
5033 * (assignResultValue): removed some commented out lines,
5034 * (genFunction): check for ISR via sym->type, absolute section for
5035 interrupt code is created via a new pBlock, the goto instruction is
5036 placed now correctly at the interrupt vector position, changed all
5037 references from ivec to _G.interruptvector,
5038 * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
5039 is the interrupt is a high priority one, same for return from ISR,
5040 * src/pic16/glue.c: changed all calls of addSetHead for publics and
5041 externs to calls of checkAddSym,
5042 * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
5043 pic16_pcode_verbose flag is set,
5044 * src/pic16/pcode.h: extern to pic16_pcode_verbose,
5045 * src/pic16/pcoderegs.c: message about how many registers are saved
5046 will only be emitted if pic16_pcode_verbose flag is set,
5048 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5050 * src/ds390/ralloc.h,
5051 * src/ds390/ralloc.c (ds390_regWithIdx),
5052 * src/ds390/gen.c (emitcode),
5054 * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
5055 ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
5056 ds390operandCompare, getRegsRead, getRegsWritten,
5057 initializeAsmLineNode): customized instruction size calculation for
5058 ds390, started basis for some register optimizations
5059 * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
5060 corresponding assembly output
5061 * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
5062 missing push/pop of r0/r1. Optimized push/pops
5064 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5066 * src/mcs51/main.c (instructionSize): fixed ACALL size
5067 * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
5069 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
5071 * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
5072 the sorting of rlist with NULL elements
5073 * (print_idataType, print_idata): NEW to create idata sections
5074 * src/pic16/device.h: idataSymSet new variable
5075 * src/pic16/gen.c (genFunction): fixed some bugs in string
5076 comparing, improved the absolute section creation for ISRs,
5077 added FSR0L/FSR0H in registers that are saved in an ISR,
5078 * (genInline): fixed the processing of inline snippets,
5079 now they undergo no process by the peephole optimizer
5080 * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
5081 are placed in idataSymSet,
5082 * (pic16emitStaticSeg): extern symbols are added in externs,
5083 * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
5084 switching when aboslute variables are placed in access bank memory
5085 * (pic16_writeUsedRegs): added call to pic16_dump_idata,
5086 * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
5087 commented out with #if,
5088 * (pic16_packRegisters): reintroduce the check for CAST because some
5089 symbols are not correctly handled,
5090 * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
5091 pCodeInstruction instead of pCode,
5092 * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
5093 pCodeAsmDir definition,
5094 * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
5095 directive, then the argument directive is emitted without the leading
5096 tab, hack for inline labels which must be in the first column,
5097 * (compareLabel,pic16_findNextInstruction),
5098 * (pic16_findPrevInstruction): added case for PO_ASMDIR,
5099 * (insertBankSwitch): modified for the new pCodeAsmDir,
5101 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
5102 patch applied by Vangelis Rokas <vrokas AT otenet.gr>
5104 * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
5106 * (pushSide): commented out with #if,
5107 * (assignResultValue): fixed some typos in saving
5109 * (genPcall): FIXED and sync'ed with genCall,
5110 * (genDataPointerGet,genDataPointerSet): using offset not leoffset
5111 * (genNearPointerGet): fixed to handle some more cases,
5112 implementation scheme via table reads,
5113 * (genConstPointerGet): modified to access code memory correct,
5114 * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
5115 and improved to handle some cases
5116 * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
5117 instead of "RETLW" for init data
5118 * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
5119 not IN_DIRSPACE, work around to reduce bank switching when aboslute
5120 variables are placed in access bank memory (<0x80 and >=0xf80),
5121 * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
5122 TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
5123 TBLWT_POSTDEC,TBLWT_PREINC
5124 * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
5125 * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
5127 * (pic16_pCodeConstString): use "DB" instead of "RETLW"
5128 * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
5129 pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
5130 * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
5132 2004-02-29 Borut Razem <borut.razem AT siol.net>
5134 * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
5135 support/Util/findme.h, support/Util/system.h: enhance binary relative
5136 search for lib and include by using findProgramPath()
5138 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5141 * src/SDCCpeeph.c (pcDistance),
5143 * src/mcs51/ralloc.h,
5144 * src/mcs51/ralloc.c (mcs51_regWithIdx),
5146 * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
5147 mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
5148 mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
5149 size calculation port specific, started basis for some register
5151 * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
5152 missing push/pop of r0/r1. Optimized push/pops
5153 * src/mcs51/ralloc.c (packregisters): fixed bug #727095
5154 * device/lib/_modsint.c (_modsint),
5155 * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
5156 and stack version so regression tests pass
5158 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
5160 * src/Makefile.in (dep): include SLIBOBJS in dependency check
5161 * src/SDCCast.c (decorateType): catch another small optimization
5163 * src/SDCCsymt.c (computeType): added comments and cosmetic changes
5164 * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
5165 modified to finally use computeType() all over SDCC,
5166 see Feature Request #877103
5167 * src/SDCCval.h: cosmetic
5168 * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
5169 valCompare(); regression tested in muldiv.c
5170 * support/regression/tests/muldiv.c (testMod): mod sign follows
5173 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
5175 * src/SDCCast.c (decorateType): fixed bug #902362
5176 * doc/INSTALL.txt: fixed install instructions for win32
5178 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
5180 * device/include/Makefile.in (install): fixed by replacing spaces
5183 * doc/INSTALL.txt: updated for release
5184 * doc/sdccman.lyx: added warning for --xstack being buggy
5186 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
5188 * src/pic16/ralloc.c (packRegsForAccUse): disabled functions with #if
5189 to eliminate build warnings.
5190 * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
5192 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
5193 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
5195 * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
5196 removed -penable-stack, added comment for stack pragma, added
5197 warning for not initializing the stack/frame registers, removed
5198 comment at interrupts section
5200 Stack is made permanent, there is no ability to disable stack usage.
5201 * src/pic16/device.h,
5202 * src/pic16/device.c: removed all references to USE_STACK macro,
5203 * src/pic16/device.c (pic16_dump_section): when no elements in
5204 rlist, free rlist before return,
5205 * (pic16_dump_int_registers): NEW, internal registers are a new set
5206 of general purpose registers reused by each function,
5207 * (checkAddReg): returns 1 if registers is added to set,
5208 * (pic16_groupRegistersInSection): when a registers is of type
5209 PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
5210 * src/pic16/device.h: memRange and Assigned Memory are deleted,
5211 SRCASECMP macro is moved here from device.c
5212 * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
5213 PO_PCLATU, PO_PRODL, PO_PRODH,
5214 * (pic16_pCodeOpType, genMinus,
5215 changed compares to "a" register, with AOP_ACC,
5216 * (pic16_genPlus): fixed some bugs and indented properly,
5217 * (pic16_addSign): changed size to size+offset in the MOVWF
5219 * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
5220 multiply 8-bit operand by literal, result is 8-bit,
5221 * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
5222 multiply 2 8-bit operand, result is 8-bit,
5223 * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
5225 * src/pic16/gen.c: changed accUse to contain WREG only,
5226 * (pic16_emitcomment): renamed to pic16_emitpcomment,
5227 * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
5228 true, do not use immediate addressing any more unless sym is a
5229 pointer in codespace,
5230 * (aopForRemat): do not use immediate addressing when symbol not in
5231 codespace and when symbol's address is requested,
5232 * (aopOp): for-loop in if(sym->accUse) is modified for the new
5234 * (aopGet): added case for AOP_ACC and don't return "accumulator
5235 bug" but WREG instead,
5236 * (popGetTempReg): pushes contents of temporary register in stack,
5237 * (popReleaseTempReg): pops contents of temporary register from
5238 stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
5239 * (pic16_popGet): separated case AOP_ACC to return register WREG
5240 from processor registers, AOP_PCODE not checks if pcop is PO_DIR
5241 or PO_IMMEDIATE and initializes their instance/offset appropriately,
5242 * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
5243 the use of immediate pointers to certain cases only.
5245 * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
5246 * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
5247 * (assignResultValue, genCall, genRet): modified to use the new
5248 function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
5249 genPcall is still broken,
5250 * (genFunction): added code to create 'A' type pBlocks when
5251 interrupt functions are generated, code not extensively tested yet,
5252 ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
5253 * (genEndFunction): modified so ISRs pop stored registers from stack,
5254 * (genMultOneByte): cleanup,
5255 * (AccRsh): added flag andmask, to and result with appropriate mask,
5256 * (genUnpackBits,genPackBits): fixed and can handle bit fields,
5257 * (genDataPointerGet): fixed and reenabled its use,
5258 * (genNearDataPointerGet): bugs fixed,
5259 * (genDataPointerSet): bugs fixed,
5260 * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
5261 pic16_DumpSymbol, pic16_DumpOp,
5262 * src/pic16/genutils.h: function prototypes for the above functions,
5263 * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
5265 * (pic16emitRegularMap): many many many improvements, but needs a
5267 * src/pic16/main.c: enable_stack in pic16_options is removed,
5268 * (_pic16_parseOptions): removed command line options -penable-stack,
5269 * (_process_pragma): emit stack symbol only when stack pragma is
5271 * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
5272 redirected to FSR0L/FSR0H pair,
5273 * (pic16_get_op, pic16_get_op2): modifications and improvements,
5274 * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5275 cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
5277 * (insertBankSwitch): modified to handle cases like: (alfa + 1)
5278 * (dumpPicOptype): NEW,
5279 * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
5280 * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
5281 with movff instruction,
5282 * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
5283 added pic16_int_regs, some packRegsFor* functions are commented out,
5284 because produce errors,
5285 * src/pic16/NOTES: minor modifications
5287 2004-02-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5289 * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
5290 as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
5292 * doc/sdccman.lyx: described options --stack-size and --pack-iram.
5293 * as/mcs51/lkaomf51.c: fixed bug #895763
5295 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
5297 * device/include/c8051f320.h: added. Contributed by Maarten Brock.
5299 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5301 * doc/sdccman.lyx: added details about the HC08 storage classes and
5302 interrupts, fixed the register usage info for z80 & gbz80
5304 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
5306 * doc/sdccman.lyx: added more pic16 port documentation
5307 * device/include/pic16/: added header pic18fregs.h
5309 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
5311 * doc/sdccman.lyx: added Vangelis' contribution
5313 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5315 * src/SDCClrange.c (rlivePoint): live range of SEND operand should
5316 extend to the next CALL or PCALL, not just to the next CALL.
5318 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
5320 * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
5322 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5324 * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
5325 bug #895752 and a better fix for bug #716790
5327 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5329 * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
5331 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5333 * doc/sdccman.lyx: minor changes, minor changed
5335 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
5337 * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
5338 which can't handle SDCC_NEWONEBYTEOPS,
5339 (geniCodeMultiply): removed conversion from mult to shift for pic14
5342 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5345 * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
5346 rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
5347 thus fixing bug #895406
5349 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
5351 * device/lib/_modsint.c,
5352 * device/lib/_modslong.c: sign follows divisor only
5353 * src/hc08/gen.c (genMultOneByte): if result size is 1,
5354 signs or signedness can be ignored
5355 * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
5356 * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
5357 added optimization for IFX,
5358 (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
5360 reenabled optimization for IFX, which was removed on 2004-01-11
5361 * src/SDCCast.h: added return type IFX
5362 * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
5363 arguments with 8 or 16 bit results; pic14 and pic16 ports use old
5364 promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
5365 SDCC_OLDONEBYTEOPS selects the old behaviour
5366 * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
5367 changed again and commented promotion rule
5368 * src/SDCCval.c (valDiv): promotion no longer necessary
5369 * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
5370 * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
5372 * support/regression/tests/onebyte.c: added
5374 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
5376 * gen.c (genInline): reverted to old code for assemnling inline
5377 code because of bug reported James Chadd
5379 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
5381 * ralloc.h: missing declarations from previous patch,
5382 seems that patch for ralloc.h was never applied, fixed
5384 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
5385 patch committed by Vangelis Rokas <vrokas AT otenet.gr>
5389 * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
5390 indirect addressing. Marked FSR0 as deprecated
5391 * gen.c (pointerCode): commented out, not needed now
5392 (pic16_popGet2p): new MOVFF helper function
5394 (genGenPointerSet): reimplemented with MOVFF and POSTINC0
5395 (shiftRLong): removed duplicate debugging info
5397 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5399 * src/ds390/gen.c (genNearPointerGet),
5400 * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
5401 optimization with bits, but not bitfields.
5402 * src/ds390/ralloc.c (packRegisters),
5403 * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
5405 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
5407 * src/SDCCcse.c (algebraicOpts): copy operands before modification
5409 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5412 * src/SDCCicode.c (operandFromSymbol),
5413 * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
5414 * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
5415 * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
5416 * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
5417 * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
5418 * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
5420 * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
5421 * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
5422 printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
5423 * src/SDCCsymt.c (newSymbol),
5424 * src/SDCC.y (struct_or_union_specifier, enum_specifier,
5427 * src/SDCCval.c (newiList): fixed bug #885705
5429 2004-02-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5431 * doc/sdccman.lyx: added section 3.1.4: sdcclib.
5432 * as/mcs51/lkmem.c: report the size of the stack in .mem file.
5434 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5436 * device/include/c8051f120.h,
5437 * device/include/c8051f300.h,
5438 * device/include/c8051f310.h: added/updated header files for Silicon
5439 Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
5440 * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
5441 in new section Submitting patches
5443 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5445 * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
5446 genFarPointerGet, genCodePointerGet, genGenPointerGet,
5447 genNearPointerSet, genPagedPointerSet, genFarPointerSet,
5449 * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
5450 genFarPointerGet, genCodePointerGet, genGenPointerGet,
5451 genNearPointerSet, genPagedPointerSet, genFarPointerSet,
5453 * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
5454 genFarPointerGet, genCodePointerGet, genGenPointerGet,
5455 genNearPointerSet, genPagedPointerSet, genFarPointerSet,
5457 * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
5458 genFarPointerGet, genCodePointerGet, genGenPointerGet,
5459 genNearPointerSet, genPagedPointerSet, genFarPointerSet,
5460 genGenPointerSet): fixed bug #892400
5461 * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
5462 to eliminate build warnings.
5463 * src/SDCCast.c (processParms),
5464 * src/SDCC.y (function_declarator2, declarator2_function_attributes):
5466 * support/valdiag/valdiag.py: added GCC to the list of defines active
5467 when compiling with gcc
5469 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5471 * support/Util/SDCCerr.h,
5472 * support/Util/SDCCerr.c,
5473 * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
5474 with an incomplete type (fixed bug #883734)
5475 * src/SDCCicode.c (geniCodeCast): fixed bug #890510
5477 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5479 * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
5481 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5483 * src/SDCCast.c (decorateType),
5484 * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
5485 function pointer implementation
5486 * support/regression/tests/funptrs.c: added tests to verify both forms
5487 of function pointers work correctly. Added tests to verify parameters
5488 are passed in the correct order.
5490 2004-02-06 Vangelis Rokas <vrokas AT otenet.gr>
5492 * device.c (regCompare): registers are sorted by ascending
5493 address and increasing size,
5494 * main.c (_pic16_finaliseOptions): removed the declaration
5495 of compiler macro MCU. Now a macro of the format pic18fxxxx
5496 will be defined from the command line
5498 2004-02-06 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
5499 patch committed by Vangelis Rokas <vrokas AT otenet.gr>
5501 * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
5502 PCOP_RLCF was overwritten!
5503 * gen.c (genSkip): commented out calls to pic16_emitcode,
5504 * (genCmpEQ): fixed "long" compares, only high word did get compared,
5506 * (genRRC): added debugging info,
5507 * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
5508 overwritten while shifting,
5509 * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
5510 overwritten while shifting,
5513 * (shiftLLeftOrResult),
5514 * (shiftRLeftOrResult),
5516 * (shiftLLong): Implemented with pic16_emitpcode
5517 * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
5518 * (genLeftShift): Fixed bug, operand for shift by variable always
5519 was "and"ed with 0x0f,
5520 * (genLeftShiftLiteral),
5522 * (genRightShiftLiteral): added debugging info,
5523 * (genrshFour): added comment,
5524 * (genRightShift): determined signedness from operand "left"
5527 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5529 * src/SDCCicode.c (geniCodeParms),
5530 * src/SDCCast.c (decorateType, processParms): support for ANSI-style
5531 function pointers, fixed function pointer bugs #861242 and #861896
5533 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5535 * device/include/c8051f000.h,
5536 * device/include/c8051f120.h,
5537 * device/include/c8051f300.h: added header files for Silicon
5538 Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
5540 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
5542 * src/SDCCast.c (processParams): added new type flow and restructured
5543 (gatherAutoInit): added new type flow
5544 (addCast): cosmetic changes
5545 (getLeftResultType): added new type flow for array indices, patch
5546 provided by Stas, see FR #877103
5547 (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
5548 array index patch by Stas
5549 * src/SDCCast.h: added prototype getResultTypeFromType()
5551 * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
5552 * src/pic/glue.c (pic14emitStaticSeg),
5553 * src/pic16/glue.c (pic16emitStaticSeg),
5554 * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
5555 for initialization of symbols
5556 * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
5557 * support/Util/SDCCerr.h:
5558 * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
5559 * .version: bumped version number to 2.3.8
5560 * device/include/Makefile.in (install),
5561 * doc/Makefile (install): changed to 'rm `find ...`' construct to
5564 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
5566 * support/regression/tests/libmullong.c: fixed for 64 bit hosts
5567 Slade Rich fixed an optimization bug
5568 * src/pic/pcodepeep.c,
5569 * src/pic/pcoderegs.c
5570 * doc/Makefile (install): added test for directory
5572 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5574 * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
5575 * src/ds390/ralloc.c (getRegPtr, getRegGpr),
5576 * src/pic/ralloc.c (getRegPtr, getRegGpr),
5577 * src/pic16/ralloc.c (getRegPtr, getRegGpr),
5578 * src/z80/ralloc.c (getRegGpr): fixed bug #883361
5579 * as/mcs51/asexpr.c (term),
5580 * as/hc08/asexpr.c (term): fixed bug #887146
5582 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5584 * src/z80/gen.c (genMult): handle single byte result product
5585 * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
5586 DUMMY_READ_VOLATILE (fixed bug #886367)
5588 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
5590 * support/regression/tests/libmullong.c: fixed logic, on little endian
5591 hosts we ended without a mullong_wrapper()
5593 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5595 * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
5596 virus/worm forged address usage.
5598 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
5600 Fixed promotion, it should be done on AST level:
5601 * src/SDCCast.c (addCast): added promotion to int
5602 (decorateType): updated call to upCast()
5603 * src/SDCCicode.c (geniCodeLeftShift): removed call to
5604 usualUnaryConversions()
5606 2004-01-26 Michael Hope <michaelh AT juju.net.nz>
5608 * support/regression/tests/literalop.c (mulWrapper): Added a
5609 wrapper to remove integer overflow warnings.
5611 * support/regression/tests/float_trans.c: Made work on host.
5613 * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
5616 * support/regression/generate-cases.py (main): Changed from inline
5619 * doc/Makefile (install): Changed to depth first to get rid of
5620 missing directory install warning.
5622 * as/Makefile (install-doc): Made work on Mac.
5624 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
5626 * src/SDCCast.c: added an additional type flow in decorateType() of
5627 opposite direction, see feature request #860006; it's enabled at runtime
5628 by setting the environment variable SDCC_NEWTYPEFLOW
5629 * src/SDCCast.h: changed prototype of decorateType()
5630 * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
5631 * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
5632 'char' to 'int' can be omitted, if both operands are 'unsigned char';
5633 see feature request #877103
5634 * src/SDCCval.c: updated call of decorateType()
5635 (valBitwise): fixed bug #882876
5636 (valMinus): added promotion
5637 (valLogicAndOr): result is unsigned
5638 (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
5639 * src/SDCCsymt.c (computeType),
5640 * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
5641 must not cause an unsigned operation
5642 * src/pic/glue (pic14emitRegularMap),
5643 * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
5645 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
5647 * src/pic/pcode.c (PCodeID): commented out left over debug code
5649 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
5651 * support/valdiag/tests/overflow.c: added shift tests
5659 * src/pic/pcodepeep.c,
5660 * src/pic/pcoderegs.c,
5662 * src/pic/ralloc.h: applied patch from Slade Rich;
5663 added support for multiple code pages and multiple RAM banks on the
5664 PIC 14 port. The ASM files now no longer simply assume all the
5665 code / RAM are in the same page / bank. This means the linker can
5666 safely allocate code/RAM of separate ASM files to different pages/banks.
5667 * doc/sdccman.lyx: added Slade's tips
5668 * src/mcs51/peeph.def: fixed bug #880768
5670 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5672 * src/hc08/ralloc.c (rematStr): fixed bug #879282
5673 * src/SDCCast.c (decorateType): fixed bug #880197
5675 2004-01-20 Michael Hope <michaelh AT juju.net.nz>
5677 * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
5680 * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
5681 strtof is not part of C89 and isn't included with Mac OS X.
5683 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5685 * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
5686 shiftL2Left2Result): fixed bug #879326
5687 (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
5688 (genMultOneByte): fixed bug in signed vs unsigned multiplication
5689 * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
5690 address fetch for clr instruction
5691 * device/lib/hc08/_mulint.c: created optimized assembly version
5692 * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
5694 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
5696 * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
5697 proposed in FR #877103
5699 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
5701 * src/SDCCval.c (cheapestVal): added missing checks
5702 * src/SDCCicode.c (usualBinaryConversions): fixed condition
5703 * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
5705 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
5707 * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
5710 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
5712 * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
5713 loaded with the linker search paths (-L arguments) and the libraries
5714 to be linked with the current source (-l arguments). Changes
5715 currently will affect only the pic16 port.
5716 * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
5717 include path the port specific paths and port specific libraries,
5718 * gplink command now contains the $3 argument,
5719 * src/pic16/device.h,
5720 * src/pic16/device.c,: structure PIC_device is made public and
5721 renamed to PIC16_device, the same for variable Pics which is renamed
5722 to Pics16. Updated all references to them.
5723 * src/pic16/glue.c (pic16glue): corrected bug with code
5724 initialization which bypassed the variable initializations block.
5726 * device/lib/pic16/Makefile.rules: removed --penable-stack from
5727 COMPILE_FLAGS and added the --nostdinc option
5729 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5731 * device/include/mc68hc908jb8.h: Register defs for another member
5732 of the hc08 family. Contributed by Bjorn Bringert - thanks!
5734 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
5736 Documenting changes from previous commits.
5737 * configure.in (version 1.56),
5738 * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
5739 when generating output files to configure the pic16 library,
5740 but now I've commented it out, since gputils aren't installed in the
5741 SF compile farm, so library won't compile
5743 * device/lib/Makefile.in (version 1.56): initially I've added in
5744 target 'all' the prerequestive 'model-pic16' so it compiled the
5745 pic16 library, but now I've commented it out for the same reasons
5747 * added targets 'model-pic16' and 'objects-pic16' to compile the
5749 * added target 'port-specific-objects-pic16' to handle the
5750 generated libraries and copy them into the build/ directory
5751 * added target 'clean-intermediate-pic16' to clean intermediate
5752 files into pic16 directory
5753 * in target 'installdirs' added line to create directory pic16 in
5754 the installation path
5756 * device/include/Makefile.in (version 1.11): in target 'install'
5757 added lines to copy all header files to installation path,
5758 * in target 'installdirs' added line create directory for pic16
5759 headers in the installation path
5761 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
5763 * src/ds390/gen.c (genCall): fixed a double use of acc and b after
5766 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
5769 * device/lib/configure.in,
5770 * device/lib/configure: fixed for autoconf 2.57
5772 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5774 * src/z80/main.c (_parseOptions): fixed the portmode= command line
5775 option so that it actually works. Made it specific to the z80, since
5776 the gbz80 doesn't have these kinds of I/O ports.
5778 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5780 * device/include/z180.h,
5781 * device/lib/_memcpy.c,
5782 * device/lib/_memmove.c,
5783 * device/lib/_mulint.c,
5784 * device/lib/ser_ir.c,
5785 * device/lib/ser_ir_cts_rts.c,
5786 * device/lib/_strcmp.c,
5787 * device/lib/_strtok.c: fixed pragmas to non-deprecated form
5788 * src/z80/main.c (_process_pragma): add support for pragmas bank and
5789 portmode; added deprecation warning for bank= and protmode= forms.
5790 Also, guard against buffer overflow.
5791 * src/z80/gen.c (aopGet): generate better code for sfr banked read
5793 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5795 * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
5796 changed interrupt vector table generation to only emit declared vectors.
5797 * device/include/Makefile.in: added missing backslash
5798 * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
5800 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
5802 Mainly changes to support compilation of the device libraries
5803 * src/pic16/device.c: stack is allocated via symbol and not
5804 via literal number. The symbol is placed in the corresponding
5805 position of the data ram
5806 * (pic16_dump_section): relocatable and absolute uninitialized
5807 data are now emitted in sorted order to reduce section naming,
5808 * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
5809 weren't marked as being in the access bank,
5811 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
5813 Added portion of GNU PIC Library under the directory
5814 device/include/pic16 and device/lib/pic16. These files
5815 contain the declarations of SFRs for the PIC18Fxx2 devices.
5816 The directory is initialized via configure from toplevel.
5818 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
5820 * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
5821 the spilllocations to be compared correctly
5823 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
5825 * src/SDCCast.c (decorateType): fixed bug introduced today
5827 2004-01-12 Borut Razem <borut.razem AT siol.net>
5829 * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
5830 doc/sdccman.lyx: upper case pragmas are deprecated
5832 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
5834 * src/SDCCast.c (decorateType): replacing 'ul > 0' by '!ul' results
5835 in simpler and even better code
5837 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
5839 * src/SDCCicode.c (operandOperation): fixed bug #874819
5840 * src/SDCCast.c (decorateType): fixed
5841 char foo (unsigned long ul) { return ul > 0; }
5843 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5845 * doc/sdccman.lyx: Moved and added some sections, small changes
5846 all over. Telling LaTeX to be less strict with word spacing
5847 to better keep the right margin. Changed some notes about
5848 maintainance of the ports in section 3.2.1 - is it OK like this?
5850 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
5852 SDCC source changes:
5853 * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
5854 convilong): modified to inform the pic16 port that builtin functions
5857 PIC16 PORT specific changes:
5858 * src/pic16/device.c pic16_dump_equates() added,
5859 processor registers declared internally by the port are emitted in
5860 the translation as equates,
5861 * src/pic16/gen.c: inline code is passed unprocessed to the
5863 * (pic16_popGetLit2): fnuction modified to take second operand as
5864 pCodeOp pointer and not as literal,
5865 * (popRegFromIdx): prefixed with pic16_,
5866 * (pic16_popCombine2): modified to receive already allocated pCode
5868 * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
5869 * (genFunction): initializes local stack frame and pushes on stack
5870 all the registers used by this function,
5871 * (genEndFunction): restores all registers from stack and restores
5873 * src/pic16/glue.c (pic16emitRegularMap): various changes and
5875 * (pic16glue): changed the program startup sequence,
5876 * added new dbName code 'A' for functions placed in absolute section
5877 * src/pic16/main.c: added function attribute _naked,
5878 * added pragma 'code' to place a fnuction at an absolute address,
5879 * added command line arguments --debug-ralloc and --pcode-verbose,
5880 * (_pic16_finiliseOptions): options.all_callee_saves is set by default
5881 * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
5882 * (pic16_newpCodeOpLit2): modified to take the second operand as
5884 * (pic16_printpBlock): modified to emit each function in a separate
5886 * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
5887 UPPER for immediate operands,
5888 * src/pic16/pcodepeeph.c: added peephole support for the LFSR
5890 * src/pic16/peeph.def: all peepholes with movff are commented out,
5891 because there is a problem in the pcode peep optimizer,
5892 * src/pic16/ralloc.c: the register allocator can now reuse local
5893 function symbols for another function. This saves register usage.
5894 * src/pic16/ralloc.h: added flag isLocal in structure regs,
5896 Added file src/pic16/NOTES with information about program writing on
5897 the current port version.
5899 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5901 * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
5902 and peephole 252 (array access)
5904 2004-01-09 Borut Razem <borut.razem AT siol.net>
5906 * src/SDCCmain.c : fixed #872250: -l command line defined library
5907 files are scanned before standard library files
5909 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5911 * src/SDCCast.c (decorateType): fixed bug #874046
5913 2004-01-09 Borut Razem <borut.razem AT siol.net>
5915 * support/scripts/sdcc.nsi: remove previous installation
5917 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5919 * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
5920 bytes for last interrupt vector (mcs51)
5921 * sdcc.spec: fixed typo
5923 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5925 * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
5926 gen51Code): more efficient parameter receive for --model-large
5929 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5932 * src/z80/main.c: added missed needLinkerScript flags (more than
5933 one port structure defined in these file)
5934 * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
5937 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
5939 * src/SDCCmain.c: removed various references to DEFAULT_PORT
5940 * src/port.h: added flag needLinkerScript in port->linker
5941 structure to inform whether to create a .lnk file or not,
5949 * src/z80/main.c: changed appropriately to configure
5950 needLinkerScript flag
5952 * src/pic16/gen.c (genAddrOf): fixed bug #863624
5953 * src/pic/glue.c: added variable udata_section_name to
5954 override default uninitialized data segment definition for
5955 devices only with SHAREBANK memory (reported from Erik Epetrich)
5956 * (pic14emitOverlay): modified to emit a commented overlay segment
5957 directive when no overlay data exist
5958 * (picglue): modified to emit uninitialized data segment
5959 according to udata_section_name
5960 * src/pic/main.c (_pic14_parseOptions): added command line
5961 options --udata-section-name=[name] to override default
5962 udata definition name
5963 * modified _linkCmd and _asmCmd to include compiler passed
5964 arguments via -W option
5965 * src/pic16/main.c: added $l in _asmCmd, changed extension for
5966 object file from '.rel' to '.o' in port->linker structure,
5967 changed size of fptr from 2 to 3 in port structure
5969 2004-01-07 Borut Razem <borut.razem AT siol.net>
5971 * support/scripts/sdcc.nsi: update PATH
5972 * support/scripts/sdcc.ico: craeted
5974 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
5976 * device/include/Makefile.in: fix install
5977 * doc/Makefile: fix install
5979 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5981 * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
5983 * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
5984 how the function variable allocation summary is displayed; also
5985 include information about variables allocated to the overlay
5988 2004-01-06 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5990 * as/mcs51/lkmain.c: Help about -Y option
5991 * as/mcs51/lkarea.c: Fixed gcc warnings
5993 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
5995 * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
5997 * support/valdiag/tests/overflow.c: added
5998 * src/SDCCast.c (decorateType),
5999 * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
6000 LEFT_OP (left shift)
6002 2004-01-06 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6004 * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
6005 (default behaviour).
6007 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6009 A python script to validate compiler diagnostic messages. It can be
6010 used to verify that sdcc complains about bad c source code and
6011 gives a good location of the error.
6012 * support/valdiag/Makefile,
6013 * support/valdiag/valdiag.py,
6014 * support/valdiag/tests/*
6016 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6018 * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
6019 * src/SDCCsymt.c (newEnumType),
6021 * support/Util/SDCCerr.c,
6022 * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
6024 * support/regression/tests/enum.c: added test for enum values that
6025 require at least 2 bytes of storage.
6027 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
6029 * src/common.h: added ifndef/define/endif macros
6030 around the header file.
6031 Bug reported from Jesus Calvino-Fraga
6033 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
6035 * sdcc.spec: updated
6036 * device/include/Makefile.in: don't install CVS directories
6037 * device/lib/Makefile.in: added removal of CVS directories after install
6038 * doc/Makefile: fixed install, added local_icons
6039 * sim/ucsim/gui.src/Makefile.in: fixed an old typo
6040 * src/mcs51/gen.c (genRightShift): fixed bug #870788
6041 * src/ds390/gen.c (genRightShift): fixed bug #870788
6042 * src/SDCCast.c (decorateType): fixed bug #870781
6044 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
6046 PIC16 port related changes:
6047 * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
6048 added variable stackPos,
6050 * gen.c: genCall, assignResultValue: added support for
6051 pushing/retrieving function parameters to/from stack,
6052 genFunction,genEndFunction: setup stack frame for the
6054 genAddrOf: will be changed according to bug 863624
6056 * added files genutils.c and genutils.h which contain gen*
6057 debugged and optimised functions extracted from gen.c
6059 * glue.c: added variable 'externs' which holds extern symbols,
6060 pic16emitRegularMap: is modified to properly handle relocatable
6061 symbols under the new scheme,
6062 pic16createInterruptVect: is modified
6063 pic16printPublics: is modified to emit 'global' assembler directives,
6064 added pic16_printExterns to print extern symbols,
6065 pic16glue: initializes stack/frame pointer in the beginning of
6066 the assembly output. Temporary hack, will be corrected later,
6067 because gplink yet does not support stack and SDCC does not
6068 yet support a type of crt0.o object to create the final binary.
6070 * Removed many lines that contain 8051 legacy code.
6071 * The code is finally placed under a 'code' directive.
6072 * Added port specific options.
6074 * _process_pragma: simplified since now we do not need *special*
6075 include file to define SFR registers. But a separate header
6076 will be needed. This will be developed later.
6077 * _pic16_parseOptions: added, parses port specific options:
6078 --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
6079 --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
6080 --preplace-udata-with=
6082 * _pic16_setDefaultOptions: modified to initialize section names,
6083 but hack is temporarly out of order since it needs improvement.
6084 * _pic16_genAssemblerPreamble: configuration words are emitted by
6085 their address instead of their name. This part is incomplete and
6086 supports only the 18Fxx2 devices. Other devices will emit an error
6087 during assembly since they do not contain the same set of config
6089 * _pic16_genIVT: is modified,
6091 * pcode.c: added definitions for some hardware registers that are needed
6093 * added flag is2LitOp and variable pci_magic in pCodeInstruction.
6094 All PCI entries are updated. Now LFSR is supported.
6095 * Removed pic16_pciTRIS is mentioned by mdubuc in source
6096 * added pic16_newpCodeOpLit2 to support instructions with
6097 two literal arguments
6098 * pic16_pCode2str: corrected code that emits assembler instructions
6099 with two literal operands and those that have an access bit modifier
6100 * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
6101 this fixes a bug which caused some labels to be lost, when an
6102 assembler directive was added, i.e. banksel,
6103 * pic16_FixRegisterBanking: improved logic that causes the insertion
6105 * InlineFunction: functions that are called once, are not any more
6106 inlined. This can be a port option in the future,
6108 * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
6110 * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
6111 hold the corresponding uninitialized symbols,
6112 * pic16_allocProcessorRegister: registers have explicit marked the
6114 * pic16_allocInternalRegister: registers are explicit marked as
6116 * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
6117 processing list, so bit registers were lost,
6120 * ralloc.h: added field 'accessBank' and original symbol operand
6121 in register definition,
6122 * removed the field isMapped from register definition,
6124 ** Several functions have been removed from various sources:
6125 BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
6126 pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
6127 isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
6128 pic16_assignRelocatableRegisters
6130 ** others have been introduced:
6131 pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
6132 pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
6134 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
6136 * support/scripts/inc2h.pl: changed definition of BIT_AT
6137 to emit 'sbit at' instead of 'bit at'. This was a request.
6139 PIC16 port related preliminary changes:
6140 * gen.c: prefixed function popRegFromString with
6141 pic16_ and all references to it corrected
6142 * pcode.c: all pic16_pc_* hardware registers prefixed
6143 with underscore (_),
6144 pic16_popCopyGPR2Bit(): function sets register wasUsed=1
6145 * ralloc.c: newReg(): when register is REG_SFR then
6146 set address to rIdx,
6147 pic16_allocProcessorRegister(): marks register wasUsed=0
6148 pic16_writeUsedRegs(): added a call to assign processor
6149 registers via pic16_assignFixedRegisters
6151 2004-01-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6153 * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
6154 as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
6155 variables in unused register banks. Also the SSEG is placed
6156 wherever there is enough space for it, and IDATA can be anywhere
6157 in internal RAM. For now compile using -Wl-Y[stack_size].
6158 The mem file is different for this option as well, since it
6159 makes no sense of talking about DSEG lenght.
6161 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
6163 * src/SDCClrange.c: fixed bug 869095 that caused segfault
6164 in certain cases, e.g. when ROM assignment, patch provided
6165 from Albert den Haan.
6167 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
6169 Many signedness and type propagation fixes:
6170 * src/SDCCicode.c: made geniCodeCast() static
6171 replaced SPEC_ by IS_ (cosmetic)
6172 (operandOperation): fixed div and mod operation
6173 (usualBinaryConversions): added support for promotion of char
6174 (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
6175 (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
6176 (geniCodeAdd): an array index will stay unsigned, even if promoted
6178 (geniCodeArray): ditto
6179 * src/SDCCicode.h: made geniCodeCast() static: removed prototype
6180 * src/SDCCsymt.c (computeType): added more support for char;
6181 promotion of char is selectable by promoteCharToInt, fixed signedness
6183 (powof2): replaced (unsigned long) by (TYPE_UDWORD)
6184 * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
6185 * src/SDCCval (val*): replaced signedness calculation by
6187 rearranged if-branches (cosmetic)
6188 (valShift): added warning W_SHIFT_CHANGED
6189 (valCompare): fixed problem with different types
6190 * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
6191 * support/regression/tests/literalop.c: added many cases
6192 * support/regression/tests/ast_constant_folding.c: changed finally to
6194 * .version: new year, new version: 2.3.7
6195 * src/SDCCmain.c (main): applied patch #866468
6196 * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
6197 provided by Scott Bronson
6198 * doc/sdccman.lyx: updated documentation for sdcdb
6199 updated and added chapter tips
6201 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6203 * src/SDCCsymt.h: missing from yesterday's commits
6205 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6207 * src/SDCC.y (struct_or_union_specifier),
6208 * support/Util/SDCCerr.c,
6209 * support/Util/SDCCerr.h: verify that struct & union tags are used
6212 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6214 * src/SDCCglobl.h: missing from yesterday's commits
6216 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6218 * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
6219 sft_attributes, struct_declaration, parameter_declaration,
6220 type_name, start_block, declaration_list),
6221 * src/SDCC.lex (check_type): support redefinition of typedef names
6223 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6225 * src/mcs51/gen.c (genPlus): added special handling for 256 byte
6226 aligned xdata arrays. Erik helped me with the if clause.
6228 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6230 * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
6233 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6236 * src/SDCCast.c (newAst_),
6238 * src/SDCCicode.c (ast2iCode, newiCode),
6240 * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
6241 expr, statement, expression_statement, selection_statement,
6242 iteration_statement, expr_opt, jump_statement): foundation for tracking
6244 * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
6247 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6249 * support/Util/SDCCerr.c,
6251 * src/SDCCast.c (createCase, createDefault, decorateType),
6252 * src/SDCClabel.c (labelUnreach),
6253 * src/SDCC.y (labeled_statement, jump_statement): More improvements
6255 * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
6256 (with thanks to Stas Sergeev)
6257 * device/include/time.h,
6258 * device/lib/time.c (CheckTime): suppress unreachable code warning
6260 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6262 * src/SDCCast.c (createIvalCharPtr),
6263 * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
6265 * support/regression/tests/nullstring.c: tests for these two bugs
6267 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6269 * support/Util/SDCCerr.h,
6270 * support/Util/SDCCerr.c (E_NOT_ALLOWED),
6271 * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
6272 about storage class and 'at' used inside struct or union
6273 * src/SDCCBBlock.c (iCodeFromeBBlock),
6274 * src/SDCCcse.c (ifxOptimize),
6275 * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
6276 printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
6277 printIval, emitStaticSeg, emitOverlay),
6278 * src/SDCClabel.c (deleteIfx),
6279 * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
6280 * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
6281 gatherAutoInit, processParms),
6282 * support/Util/SDCCerr.h,
6283 * support/Util/SDCCerr.c (werrorfl): Support for better error location
6284 reporting for post-parse errors.
6286 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6288 * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
6289 implicit casts via union; they don't work on big endian systems
6290 (possible fix for bug #861138)
6292 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6294 (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
6295 * src/mcs51/main.c: fixed the fix for bug #737001
6297 2003-12-15 Borut Razem <borut.razem AT siol.net>
6299 * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
6301 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6303 * support/makebin/makebin.c: put output in binary mode
6305 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6307 * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
6308 xdata and data memory on startup. Set the environment variable
6309 SDCC_NOGENRAMCLEAR to disable this.
6310 * src/mcs51/peephole.def,
6311 * src/ds390/peephole.def: using the atomic test and clear instruction jbc
6312 (allows non-interrupt and interrupt code to safely compete for a resource
6313 without the non-interrupt code having to disable interrupts)
6315 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6317 * src/SDCCicode.c (geniCodeAdd),
6318 * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
6319 with valFromType if type might be a pointer and host is big endian).
6320 * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
6321 types, not just integer types.
6322 * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
6323 multiply defined with mismatching "at" address.
6325 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6327 * src/ds390/main.c (PORT tininative_port): fixed bug #858416
6328 * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
6329 * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
6330 with embedded nulls (fixed bug #753752)
6332 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6334 * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
6335 Apparently this did not see much testing (endless loop)
6337 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6339 * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
6341 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6343 * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
6344 gracefully handle NULL memmap pointers
6346 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6348 * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
6349 instead of deleting the iCode when an operand is volatile
6350 * src/z80/gen.c (genDummyRead),
6351 * src/mcs51/gen.c (genDummyRead),
6352 * src/ds390/gen.c (genDummyRead),
6353 * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
6355 * src/SDCCicode.c (geniCodeCall): fixed bug #851607
6356 * src/SDCC.y: fixed bug #850420
6358 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6360 Applied z80 i/o port patch from Peter Townson and fixed some operators
6361 to better handle operands in A register.
6362 * device/include/z180.h
6368 * src/z80/peeph-z80.def
6372 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6374 * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
6376 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6378 * device/lib/hc08/_mullong.c: Removed extra #endif
6380 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6382 * sim/ucsim/hc08.src/inst.cc,
6383 * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
6385 * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
6386 * src/hc08/gen.c (XAccRsh): fixed problem with right shift
6387 * device/include/stdarg.h: fixed varargs for hc08
6388 * device/lib/Makefile.in,
6389 * device/lib/hc08/Makefile,
6390 * device/lib/hc08/_mulint.c,
6391 * device/lib/hc08/_mullong.c: fixed some endian problems
6393 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6395 * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
6396 * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
6397 * device/lib/_gptrget.c,
6398 * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
6400 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6402 * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
6403 * src/SDCCast.c (astErrors): fixed bug #846007
6404 * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
6406 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6408 * src/SDCCast.c (decorateType): disabled a transformation I added in
6409 revision 1.188 (access to fields of a structure at an absolute address);
6410 it breaks with bitfields, extern declarations, and gcse analysis.
6411 * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
6412 could be assigned through a pointer, so don't complain.
6413 * src/SDCCast.c (astErrors),
6415 * src/SDCCglue.c (emitRegularMap): fixed bug #847813
6417 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
6419 * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
6420 * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
6421 output of __config directives, since gpasm now supports them
6422 * src/pic16/main.c (_pic16_finaliseOptions): define MCU
6423 pre-processor macro, i.e. -DMCU=p18f452
6424 * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
6425 and modified to handle 'cast' icode similarly to '=' icode
6426 * src/pic16/device.h (typedef struct PIC_device): added field
6427 'extMIface' to indicate that chip has external memory interface
6428 * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
6429 18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
6432 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6434 * src/SDCC.y (pointer): fixed bug #846006
6435 * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
6436 * src/SDCCast.c (decorateType): fixed bug #846009
6437 * src/ds390/peeph.def,
6438 * src/ds390/gen.c (genAnd, genOr),
6439 * src/mcs51/peeph.def,
6440 * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
6442 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6444 Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
6451 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
6455 * src/SDCCbitv.c: added function to free a bitvector
6457 * src/SDCClrange.c: added function to recompute the liveranges
6459 * src/ds390/ralloc.c,
6460 * src/hc08/ralloc.c,
6461 * src/mcs51/ralloc.c,
6463 * src/pic16/ralloc.c,
6464 * src/xa51/ralloc.c,
6465 * src/z80/ralloc.c: recompute the liveranges after register packing
6467 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
6469 * src/SDCCloop.c (newInduction): fixed bug #845630
6471 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6473 * src/SDCCsymt.c (compareTypesExact): disabled debugging output
6474 inadvertantly left behind from my 2003-11-12 change
6476 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6478 Updated headers I neglected to commit yesterday.
6482 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6484 * src/SDCCcse.c (algebraicOpts): fixed bug #773153
6485 * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
6486 * src/SDCCopt.c (eBBlockFromiCode),
6487 * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
6488 the creation of the key hash table from the sequencing so it can be used
6489 earlier (for some GCSE bug fixes still pending)
6491 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6493 * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
6494 * support/regression/tests/addsub.c: testing genPlus shortcut
6496 2003-11-15 Borut Razem <borut.razem AT siol.net>
6498 * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
6500 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6502 * src/SDCCcse.c (cseBBlock): fixed bug #527779
6503 * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
6504 ordering is immaterial.
6505 * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
6507 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6509 * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
6510 * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
6511 (SIGSEV) of bug #840381
6512 * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
6513 unlink new file before rename if new and old filenames are the same)
6515 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6517 * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
6518 uninitialized variables) for the mcs51. Set environment variable
6519 SDCC_GENRAMCLEAR to test.
6520 xdata initialization slightly shorter
6522 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6525 * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
6526 #838241 & 780691 (basicly the same bug)
6527 * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
6528 * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
6530 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
6532 * src/SDCCmain.c (linkEdit): "fix" #834252
6534 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6536 * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
6538 * src/SDCC.y: fixed bug #819403
6540 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6542 * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
6543 the reentrant attribute.
6544 * src/hc08/gen.c (genPackBits): added missing stack readjustment
6545 * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
6547 * src/SDCCast.c (decorateType): fixed bug with storage class not being
6548 updated during pointer dereference; f.e. ~(((char *)1)*) was being
6549 erroneously reduced to a literal.
6550 * src/hc08/ralloc.c (packRegisters, rematStr),
6551 * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
6554 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6556 * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
6557 * doc/sdccman.lyx: changed from 'article' to 'book'
6558 * doc/Makefile: readded test_suite_spec and cdbfileformat
6560 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
6562 * device/include/stdlib.h: include malloc.h to comply with ANSI
6563 * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
6565 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6567 * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
6568 * doc/clean.mk: also remove *.out files
6569 * doc/sdccman.lyx: some additions, larger top/bottom margins
6571 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6573 * src/SDCC.y: fixed bug #837365
6574 * support/regression/tests/bitopcse.c
6575 * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
6576 a symbol (might be valop instead)
6577 * device/lib/Makefile.in: added errno.c to HC08SOURCES
6578 * device/lib/clean.mk: added hc08 to the cleaning list
6580 2003-11-04 Borut Razem <borut.razem AT siol.net>
6582 * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
6584 * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
6585 as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
6586 malloc is declared in standard stdlib.h
6588 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6590 * device/lib/hc08/Makefile: need to clean .rel not .o files
6591 * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
6593 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6603 * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
6604 * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
6605 tests (which uses the port's oclsExpense function)
6611 * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
6613 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6615 * src/SDCCcse.c (ifxOptimize),
6616 * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
6617 an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
6618 deleting the IFX iCode.
6619 * src/hc08/ralloc.c: reduced unneeded slocs
6620 * src/hc08/gen.c: fixed bug in asmopToBoolean
6622 2003-11-04 Borut Razem <borut.razem AT siol.net>
6624 * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
6625 support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
6626 as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
6627 transferred to configure
6629 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
6631 Use headers defined in the C[++] standards:
6632 * sim/ucsim/gui.src/serio.src/fileio.cc
6633 * sim/ucsim/gui.src/serio.src/frontend.cc
6634 * sim/ucsim/gui.src/serio.src/main.cc
6635 * sim/ucsim/gui.src/serio.src/posix_signal.cc
6636 * support/Util/NewAlloc.c
6642 2003-11-03 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6644 * Added MSVC projects for hc08 assembler and linker:
6645 all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
6646 /as/hc08/link_hc08.dsp
6648 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
6650 * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
6652 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
6654 * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
6656 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6658 * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
6660 2003-10-31 Borut Razem <borut.razem AT siol.net>
6662 * support/cpp2/cpplib.h,
6663 support/cpp2/cpplib.c,
6664 support/cpp2/cpplex.c,
6665 support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
6666 to switch _asm block preprocessing on / off. Default is
6667 #pragma preproc_asm +
6669 2003-10-31 Borut Razem <borut.razem AT siol.net>
6671 * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
6672 when outputting comment blocks (when executed with -C option) and
6673 _asm (SDCPP specific) blocks
6675 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6677 * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
6679 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
6681 * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
6683 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
6685 * src/SDCCmain.c (linkEdit): "fixed" bug #833605
6686 * src/SDCCast.c (decorateType): fixed bug #832664
6688 2003-10-31 Borut Razem <borut.razem AT siol.net>
6690 * support\cpp2\cpplex.c: fixed for SDCPP:
6691 comments(when executed with -C option) and _asm blocks
6692 were included even if they where in skipped #if block.
6693 Applied solution from GCC cpp 3.3.2
6695 2003-10-31 Borut Razem <borut.razem AT siol.net>
6697 * src/SDCC.lex: sdcc now understands both formats:
6698 '# <line_number> <file_name>' and
6699 '#line <line_number> <file_name>'
6700 * support/cpp2/cppmain.c: sdcpp now generates the standard
6701 '# <line_number> <file_name>' instead of former
6702 '#line <line_number> <file_name>'
6704 2003-10-30 Borut Razem <borut.razem AT siol.net>
6706 * support/cpp2/cpphash.h,
6707 * support/cpp2/cpplib.h
6708 * support/cpp2/cpplex.c,
6709 * support/cpp2/cppmain.c,
6710 * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
6712 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6714 Fixed a number of problems revealed by bug #827883.
6715 * src/SDCCloop.c (loopInvariants): Spill location of the
6716 result operand should be recomputed if extracted from
6717 a loop. Also, don't extract assignments of an iTemp
6719 * src/SDCCast.c (isConformingBody): loop reversal should
6720 not occur if the control variable is involved with a
6721 relational operator.
6723 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
6725 * .version: bumped to 2.3.6 to reflect the big improvements
6726 made by Erik and Klaus. Thanks!
6728 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
6730 Replaced the livrange code.
6731 * src/SDCClrange.c: added new LR code
6733 * src/SDCCBBlock.h: removed remainig parts from old LR code
6734 * src/ds390/ralloc.c,
6735 * src/ds390/gen.c: minor fixes to make it work with new code
6737 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6742 * src/hc08/ralloc.c: Fix various warnings related to the hc08
6743 * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
6744 (tweaked fix for bug #818696)
6746 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6748 * src/z80/ralloc.c (joinPushes): Fixed bug #828742
6750 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6753 * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
6754 * src/mcs51/gen.c (gencjneshort),
6755 * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
6756 more efficient (per Scott Bronson's suggestion)
6758 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6760 Extended the semantics of the critical keyword to include
6761 individual statements. See RFE #827755 and #799831
6766 * support/Util/SDCCerr.c
6767 * support/Util/SDCCerr.h
6772 2003-10-19 Borut Razem <borut.razem AT siol.net>
6774 * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
6776 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6778 * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
6780 * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
6781 and predecrement operand is displayed
6783 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
6785 * src/SDCCval.c (valMinus): fixed bug #826041
6787 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6789 Some hc08 related updates that I missed earlier
6790 * sim/ucsim/stypes.h
6791 * support/regression/ports/hc08/spec.mk
6793 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6795 New target "hc08" for the Motorola 68hc08 family of micros
6803 * sim/ucsim/hc08.src/*
6804 * sim/ucsim/configure.in
6805 * src/ucsim/configure
6806 * sim/ucsim/packages_in.mk
6809 * device/include/mc68hc908qy.h
6811 * device/lib/Makefile.in
6812 * support/regression/ports/hc08/*
6813 * support/regression/Makefile
6815 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6817 * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
6819 * src/ds390/gen.c (genCast): fixed bug #821957
6821 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
6823 * device/lib/logf.c: "fixed" overlay bug
6824 * support/regression/ports/host/spec.mk: added m library
6825 * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
6826 * support/regression/tests/float_trans: added (for Eric)
6828 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
6830 * src/mcs51/gen.c (genCpl): fixed bug
6831 http://sf.net/mailarchive/message.php?msg_id=6263915
6833 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
6835 * src/SDCCast.c (decorateType): added extended constant folding
6836 * src/SDCCsymt.c (computeType): cleanup
6837 * src/SDCCval.c (valShift): minor optimization
6838 * support/regression/tests/ast_constant_folding.c: added
6840 2003-10-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6842 * src/SDCCmain.c: removed some unintended changes
6844 2003-10-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6846 * src/SDCCmain.c (setParseWithComma): fixed bug #816685
6847 * src/z80/gen.c: fixed part of bug #817589
6848 * src/SDCCsymt.c (checkFunction): fixed bug #817895
6850 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
6852 Replaced cast (void **) with (void *) to avoid gcc 3 warning:
6863 * src/ds390/ralloc.c
6865 * src/mcs51/ralloc.c
6867 * src/pic16/ralloc.c
6870 * src/z80/gen.c: removed unused label "release:"
6872 2003-10-06 Borut Razem <borut.razem AT siol.net>
6874 * src/SDCC.lex: removed definition of unused variables
6875 save_optimize and save_options
6877 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
6879 * clean.mk: removed '=' in "-maxdepth=1"
6880 * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
6881 * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
6883 2003-10-06 Borut Razem <borut.razem AT siol.net>
6885 * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
6886 my_unput() replaced by unput()
6888 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
6890 * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
6891 setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
6892 type-punned pointer will break strict-aliasing rules"
6893 Old LR behaviour is again default; Klaus' LR can be choosen by
6894 defining the environment variable LRKLAUS
6898 * src/ds390/ralloc.c (spillThis): applied Klaus' patch
6899 * clean.mk: fixed removal of files in bin/CVS/
6900 * device/lib/clean.mk: fixed removal of directories small and large
6901 * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
6903 * src/SDCCval.c: removed superflous test for pedantic
6905 2003-10-05 Borut Razem <borut.razem AT siol.net>
6907 * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
6908 Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
6909 message "unmatched #pragma SAVE and #pragma RESTORE"
6911 2003-10-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6913 * doc/sdccman.lyx: various additions and updates (interrupts, inline
6914 assembly, critical functions, atomic, nojtbound)
6916 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
6918 Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
6924 2003-10-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6927 * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
6929 * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
6931 * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
6932 * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
6933 * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
6935 2003-10-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6937 * src/z80/gen.c (genRet): fixed bug #524753
6938 * src/z80/gen.c (genCast): fixed internal error on cast from
6940 * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
6941 fix for bug #477835 to the z80
6942 * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
6943 for tracking iCodes in the peephole optimizer for z80
6945 2003-10-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6947 * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
6948 the other part of bug #814548
6949 * src/SDCCpeeph.c (labelInRange): fixed bug #814558
6951 2003-09-30 Bernhard Held <bernhard AT bernhardheld.de>
6953 * src/SDCCcse.c: fixed part of bug #814548
6955 2003-09-28 Borut Razem <borut.razem AT siol.net>
6957 * src/asm.c: rewrite of printILine() to use temporary file instead
6959 * src/xa51/main.c: commented out declaration of int rewinds
6961 2003-09-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6963 * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
6965 2003-09-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6967 * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
6968 * src/asm.c (printILine): Fixed bug #811015
6970 2003-09-22 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6972 *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
6975 2003-09-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6977 * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
6978 * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
6979 to correctly handle general case of AOP_PAIRPTR
6980 * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
6982 2003-09-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6984 * src/mcs51/ralloc.c (fillGaps),
6985 * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
6986 register positioning bug)
6988 2003-09-21 Bernhard Held <bernhard AT bernhardheld.de>
6990 * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
6992 2003-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6994 * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
6995 genCodePointerGet, genGenPointerGet, genFarPointerSet,
6996 genGenPointerSet): handle AOP_DPTR correctly when loading dptr
6997 (ralloc doesn't intentionally do this now, but perhaps later)
6998 * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
6999 * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
7000 register positioning bugs (Fixed bug #762602 and #795325)
7001 * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
7003 * src/z80/gen.c: increased _vemit2's buffer[] to handle long
7004 lines that --i-code-in-asm generates
7006 2003-09-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7008 *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
7009 trying to fclose a FILE* that was already closed.
7011 2003-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7013 * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
7014 of const struct should be treated as if const themselves)
7016 2003-09-18 Bernhard Held <bernhard AT bernhardheld.de>
7018 * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
7020 2003-07-06 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7022 * support/librarian/sdcclib.c: Generate correct offsets for libraries with
7023 Unix (/n) and DOS (/r/n) line terminations.
7025 2003-09-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7027 * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
7030 2003-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7032 * src/mcs51/gen.c (genFunction, genEndFunction),
7033 * src/ds390/gen.c (genFunction, genEndFunction): Moved save
7034 and restore of EA so that stack offsets to parameters are
7035 correct when using both critical and reentrant/stack-auto.
7036 * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
7037 size (can be triggered in error if sloc is shared between
7038 different sized objects)
7039 * device/include/float.h: fixed macros to explicitly use
7040 unsigned long where needed
7042 2003-09-15 Bernhard Held <bernhard AT bernhardheld.de>
7044 Feature req. 799831: added code to allow nesting of critical functions
7045 * src/mcs51/gen.c (genFunction, genEndFunction)
7046 * src/ds390/gen.c (genFunction, genEndFunction)
7048 2003-09-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7050 * src/SDCCsymt.c (sclsFromPtr),
7052 * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
7053 support for standard C idiom of memory mapped variables; for
7054 example, *((xdata int*)0x1234) = 1 is now internally equivalent
7055 to xdata int at 0x1234 tempvar = 1.
7056 * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
7057 provided by Akiya ISHIDA
7059 2003-09-13 Bernhard Held <bernhard AT bernhardheld.de>
7061 * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
7062 * src/SDCCval.c (constVal): added reduction from int to char
7063 * src/SDCCval.c (valMult, valDiv): fixed sign handling
7064 * src/SDCCval.c (valShift): fixed after change of cheapestVal()
7065 * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
7067 * support/regression/tests/shifts.c: fixed
7069 2003-09-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7071 * src/z80/gen.c (genXor): Fixed bug #805445
7073 2003-09-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7075 Fixed bug #621531 (const & volatile confusion in the type chain).
7076 DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
7077 refer to the const or volatile state of the pointer itself.
7089 * src/pic16/ralloc.c
7090 * support/regression/tests/const.c
7092 2003-09-10 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7094 When checking for duplicated modules, use absolute paths
7095 instead of relative paths. Files changed:
7100 2003-09-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7102 * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
7104 2003-09-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7106 * device/include/string.h: added size_t typedef, changed
7107 prototypes to use size_t, eliminated separate reentrant and
7108 non-reentrant declarations, added _memmove declaration
7109 * device/lib/_memcpy.c: changed to use size_t instead of int,
7110 changed /4 to >>2 to avoid division library call
7111 * device/lib/_memcmp.c,
7112 * device/lib/_memset.c,
7113 * device/lib/_strncat.c,
7114 * device/lib/_strncpy.c,
7115 * device/lib/_strncmp.c: changed to use size_t instead of int
7116 * device/lib/_memmove.c: new file (fixed bug #772294)
7117 * device/lib/Makefile.in: added _memmove.c
7118 * device/lib/z80/asm_strings.s: fixed bug #772290
7119 * support/regression/tests/bitfields.c: attempt to fix host assertion
7120 failure on amd64-unknown-linux2.2
7122 2003-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7124 * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
7125 * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
7126 * as/z80/asmain.c (main): fixed bug #801766
7128 2003-09-06 Bernhard Held <bernhard AT bernhardheld.de>
7130 * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
7133 2003-09-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7135 * src/SDCCast.c (isConformingBody): fixed loop reversal bug
7136 reported in bug #800609
7138 2003-09-04 Vangelis Rokas <vrokas AT otenet.gr>
7140 * Top header beautifications in src/pic16 directory:
7141 device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
7142 pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
7143 pcoderegs.h, ralloc.c, ralloc.h
7144 * main.c: added top header and GPL license notice
7145 * pcode.c: fixed the if-conditional warning
7147 2003-09-04 Bernhard Held <bernhard AT bernhardheld.de>
7149 * device/lib/_mullong.c: replaced int by short for gcc
7151 2003-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7153 * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
7154 and JUMPTABLE iCodes properly now (worked by accident before)
7155 * src/mcs51/gen.c (leftRightUseAcc),
7156 * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
7157 iCode properly now. Use getSize instead of nRegs since a & b
7158 aren't part of the nRegs tally.
7160 2003-08-31 Vangelis Rokas <vrokas AT otenet.gr>
7162 * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
7163 * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
7164 before instructions that use the _STATUS register
7166 2003-08-31 Bernhard Held <bernhard AT bernhardheld.de>
7168 * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
7169 * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
7170 fetching of the pointer
7171 * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
7172 copied from genNearPointerSet()
7173 * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
7174 * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
7175 If they pop r0/r1 they must be called in the opposite order than aopOp().
7176 * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
7177 (resp. --stack-auto), prepared for --xstack
7179 2003-08-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7181 * doc/sdccman.lyx: reverted tables to those in cvs 1.64
7183 2003-08-28 Bernhard Held <bernhard AT bernhardheld.de>
7185 * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
7186 these ports have their own __sdcc_external_start()
7188 2003-08-26 Bernhard Held <bernhard AT bernhardheld.de>
7190 pic patch provided by Slade Rich <slade_rich AT yahoo.com>
7191 * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
7192 type for bits was changed. It resulted in bit variables becoming
7193 global, which is not permitted in PIC 14 assembly output.
7195 2003-08-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7197 * doc/sdccman.lyx: various additions and updates. Rearranged sections
7199 2003-08-22 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7201 Z80 and MCS51 linkers complaint if a public symbol is defined
7202 in more than one library module:
7206 * as/mcs51/Makefile.in
7208 2003-08-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7210 A few small changes that speed up the peephole optimizer.
7214 2003-08-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7216 Try to make the peephole optimizer smarter by maintaining
7217 an association between the assembly source code and the
7218 iCodes that originated them. Put this information to use
7219 with a new peephole rule condition "notVolatile" so that
7220 the rules can be aggressive yet still safe.
7225 * src/mcs51/peeph.def
7227 2003-08-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7231 * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
7232 * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
7233 if the left or right operand symbols have the accuse flag set.
7235 2003-08-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7237 Changed the type of the result of the ! (NOT) operator to char;
7238 previously it returned the same type as the source. This allows
7239 us to eliminate all the genFloatNot functions (all of its target
7240 implementations were very buggy) since !float can use the same
7243 * src/SDCCicode.c (ast2iCode): ! returns char
7244 * src/mcs51/gen.c (genNot, genNotFloat),
7245 * src/ds390/gen.c (genNot, genNotFloat),
7246 * src/z80/gen.c (genNot, genNotFloat),
7247 * src/pic/gen.c (genNot, genNotFloat),
7248 * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
7250 2003-08-19 Bernhard Held <bernhard AT bernhardheld.de>
7252 pic patch provided by Slade Rich <slade_rich AT yahoo.com>
7253 1. Interrupt would not compile properly. Ensure PCLATH register is saved
7254 during interrupts. Ensure WSAVE is located at a shared bank address.
7255 2. Fixed page selection in some places
7256 3. Fixed BTFSS/C to where necessary use registers directly and not simply
7257 the registers name strings.
7258 4. Fixed "signed / unsigned compare" compiler warnings.
7259 5. The PIC port manages its own allocation of the general purpose
7260 registers, but makes no attempt to reuse them. As a result when
7261 compiling it soon runs out of general purpose registers. Some
7262 additional code was added to the files pcode.c and device.c to walk
7263 through the function call tree and rename the registers so that they
7273 * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
7274 genPlus() & genMinus() when the result is the same as left or right
7276 2003-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7278 * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
7280 2003-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7282 Made bitfield a distinct type from bit so that bitfields
7283 convert as per ANSI C and bits retain their traditional
7284 boolean style behaviour. Implemented bitfield support in
7292 * src/ds390/gen.c: bit v bitfield split
7293 * src/z80/gen.c: New support for bitfields
7294 * support/regression/tests/bitfields.c: reenabled z80,
7297 2003-08-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7299 Rules 246.x, 247.x relate to bitfields, the others speed up
7300 access to xdata mapped I/O devices.
7302 * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
7304 2003-08-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7306 Cleaned up genPackBits and genUnpackBits and added two helper
7307 functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
7308 for literal assignments in genPackBits (thanks to Frieder for
7314 2003-08-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7316 Fixed bug #748310 (pointer to function type mishandled when the
7317 function name is omitted). Also fixed a SIGSEGV when a function
7318 attribute (reentrant, etc) is used on a non-function or on a
7319 function but misplaced before the parameter list.
7321 * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
7323 * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
7324 * support/Util/SDCCerr.h,
7325 * support/Util/SDCCerr.c: Added func attr misuse error msg
7327 2003-08-13 Bernhard Held <bernhard AT bernhardheld.de>
7329 Fixed bug #787649 by anonymous
7330 * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
7331 * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
7333 2003-08-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7335 Fixed numerous bitfield problems.
7337 * src/SDCC.y: More bitfield related error checking
7339 * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
7340 * support/Util/SDCCerr.h,
7341 * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
7342 * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
7343 * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
7344 * support/regression/tests/bitfields.c: tests added
7346 2003-08-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7348 Made the constant following the "interrupt" keyword optional. If
7349 omitted, the function will not automatically be given an entry
7350 in the interrupt vector table (similar to #pragma NOIV, but
7351 less syntacticly kludgy). The interrupt number is also now
7352 range checked. Also fixed a bug in the high order bit example
7359 * support/Util/SDCCerr.c
7360 * support/Util/SDCCerr.h
7363 2003-08-13 Bernhard Held <bernhard AT bernhardheld.de>
7365 * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
7366 * src/SDCCicode.c (operandOperation): rewritten some ops
7367 (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
7368 * src/SDCCsymt.c (computeType): literals are handled the same way as any
7370 * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
7371 be re-activated by defining REDUCE_LITERALS)
7372 * src/SDCCval.c (constVal): fixed; hex and octal constants can be
7373 unsigned, but are signed by default
7374 * src/SDCCval.c (constVal): rearranged
7375 * src/SDCCval.c (valMod): preliminary fix
7376 * src/SDCCval.c (valCastLiteral): use TYPE_* types
7377 * support/regression/literalop.c: added, work in progress
7379 2003-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7381 Generate warnings for useless declarations like "char data;"
7382 that don't do what new users expect.
7385 * support/Util/SDCCerr.h
7386 * support/Util/SDCCerr.c
7388 2003-08-09 Bernhard Held <bernhard AT bernhardheld.de>
7390 * src/SDCCval.c (valMult): fix overflow detection of negative int
7392 2003-08-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7394 * src/z80/ralloc.c (joinPushes): made compatible with new signedness
7396 Changes to support big endian targets:
7409 2003-08-06 Bernhard Held <bernhard AT bernhardheld.de>
7411 * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
7412 * device/lib/time.c: fixed warning "integer overflow in expression"
7414 2003-08-05 Bernhard Held <bernhard AT bernhardheld.de>
7416 * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
7417 * src/SDCCval.c (constVal): changed default to signed; hex and octal
7418 constants are unsigned; added recognition of "u" flag for unsigned
7419 * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
7420 * src/SDCCval.c (valDiv, valMod): fixed signdness
7421 * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
7422 signedness of modulo, left and right shift
7423 * support/Util/SDCCerr.c: added warning "integer overflow in expression"
7424 * support/Util/SDCCerr.h: added warning W_INT_OVL
7425 * src/SDCCast.c (decorateType): fixed gcc3.3 warning
7426 * src/SDCCast.c (ast_print): improved output of constants
7428 2003-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7430 Fixed some warnings when building with MSVC:
7443 * support\cpp2\cpplib.c
7447 2003-08-03 Bernhard Held <bernhard AT bernhardheld.de>
7449 * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
7451 2003-08-01 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7453 * support\librarian\clean.mk: Do not remove Makefile.
7454 * support\librarian\Makefile: added.
7456 2003-08-01 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7458 Added librarian to MSVC build:
7461 * support\librarian\librarian.dsp
7463 'configure' not needed for librarian, removed:
7464 * support\librarian\configure
7465 * support\librarian\configure.in
7466 * support\librarian\config_in.h
7467 * support\librarian\Makefile.in
7469 Hopefully these ones built the librarian and the rest of sdcc properly:
7471 * Makefile.common.in
7473 Messed up 'configure', so revert to previous version:
7477 2003-07-31 Bernhard Held <bernhard AT bernhardheld.de>
7479 * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
7480 there, while the mantissa of a double is "only" 53 bits wide.
7482 2003-07-31 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7484 Adding sdcclib to the build. MSVC project coming soon.
7485 Files added/changed:
7487 * support\librarian\clean.mk
7488 * support\librarian\configure
7489 * support\librarian\configure.in
7490 * support\librarian\config_in.h
7491 * support\librarian\Makefile.bcc
7492 * support\librarian\Makefile.in
7493 * support\librarian\sdcclib.c
7496 * Makefile.common.in
7500 2003-07-29 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7502 Linker now complaints if linked modules have conflicting options, for
7503 example, one compiled using --model-large and another one compiled with
7504 --model-small. The following files were modified:
7526 2003-07-28 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7528 *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
7529 as/mcs51/lklibr.c: Generate a warning when a library is not found.
7531 2003-07-28 Bernhard Held <bernhard AT bernhardheld.de>
7533 * src/z80/mappings.i: fix _mul[us][int,long] entries
7535 2003-07-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7537 *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
7539 2003-07-24 Bernhard Held <bernhard AT bernhardheld.de>
7541 * src/SDCCicode.c (operandOperation): really fixed problem with bitops
7542 * support/regression/tests/bitopcse.c: added
7550 2003-07-24 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7552 added support for new library format to z80, gbz80 linkers:
7558 2003-07-24 Bernhard Held <bernhard AT bernhardheld.de>
7560 * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
7561 after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
7563 2003-07-23 Bernhard Held <bernhard AT bernhardheld.de>
7565 added DUMMY_READ_VOLATILE:
7574 * src/SDCCcse.c (algebraicOpts): many improvements
7575 * src/SDCCcse.h: removed algebraicOpts()
7576 * src/SDCCicode.c (picDummyRead): added
7578 2003-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7580 * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
7581 "Insufficient space in data memory".
7583 2003-07-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7585 * src/mcs51/gen.c: fixed bug #771358
7586 * src/z80/gen.c: fixed bug #759087
7588 2003-07-20 Bernhard Held <bernhard AT bernhardheld.de>
7590 * src/pic16/glue.c: minor cleanup by Vangelis
7592 2003-07-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7594 * device/include/regc515c.h: fixed #758477
7595 * device/lib/_gptrget.c: saving some cycles in generic pointer get
7596 * device/lib/_gptrput.c: saved a few bytes
7597 * my tab spacing is 8, yours too?)
7598 * device/lib/_ser.c: process RX bytes earlier than TX bytes
7599 * device/lib/serial.c: process RX bytes earlier than TX bytes
7600 * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
7602 2003-07-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7604 * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
7606 2003-07-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7608 * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
7610 2003-07-17 Bernhard Held <bernhard AT bernhardheld.de>
7612 * device/lib/Makefile.in: bad fix, reverted to 1.43
7614 2003-07-16 Bernhard Held <bernhard AT bernhardheld.de>
7616 * device/lib/Makefile.in: added missing z80 object files
7618 2003-07-14 Bernhard Held <bernhard AT bernhardheld.de>
7620 * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
7621 pic16 progress by Vangelis:
7636 * pic16/pcodepeep.c:
7639 2003-07-13 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7641 * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
7643 2003-07-12 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7645 * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
7646 added gbz80 build to MSVC project.
7647 * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
7648 link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
7649 from 8051 stuff and setup so it links using a .lnk file.
7651 2003-07-06 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7653 * support/librarian/sdcclib.c: sdcc librarian.
7654 * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
7657 2003-07-03 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7659 * as/mcs51/lkmain.c: properly handle extensions in function afile.
7661 2003-07-02 Borut Razem <borut.razem AT siol.net>
7663 * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
7664 src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
7665 src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
7666 src/xa51/main.c, src/z80/main.c:
7667 virtualization of glue() function: each port has it's own glue function,
7668 which is accessed by do_glue function pointer in PORT.general structure
7670 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
7672 * DS800C400 fun, improved ROM interface and tinibios.
7674 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
7676 * More support for DS80C400. Now includes beginning of interface to ROM.
7678 2003-06-25 Bernhard Held <bernhard AT bernhardheld.de>
7680 * src/mcs51/gen.c (gencjneshort): fixed bug #760345
7682 2003-06-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7684 * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
7686 2003-06-19 Borut Razem <borut.razem AT siol.net>
7688 * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
7690 2003-06-19 Borut Razem <borut.razem AT siol.net>
7692 * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
7693 fixed Z80 port - crt0.o: cannot open.
7695 2003-06-19 Bernhard Held <bernhard AT bernhardheld.de>
7697 * support/Util/MySystem.c (merge_command): revert bad fix
7699 2003-06-18 Borut Razem <borut.razem AT siol.net>
7701 * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
7703 2003-06-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7705 * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
7706 option --use-stdout sends errors to stdout instead of stderr.
7708 2003-06-18 Bernhard Held <bernhard AT bernhardheld.de>
7710 * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
7712 2003-06-15 Borut Razem <borut.razem AT siol.net>
7714 * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
7715 * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
7716 * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
7717 fixed width array of pointers replaced with sets;
7718 multiple include and lib paths ared transferred to preprocessor and linker
7719 * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
7720 * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
7721 fixed width array of pointers
7722 * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
7723 removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
7724 fixupPath(), getPathDifference()
7725 * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function inExcludeList() by using sets instead
7726 fixed width array of pointers
7728 2003-06-11 Bernhard Held <bernhard AT bernhardheld.de>
7730 * src/pic16/ralloc.c: fix warnings
7731 * src/pic16/pcode.c: fix warning
7733 2003-06-10 Scott Dattalo <scott AT dattalo.com>
7735 Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
7736 know all the details, but essentially this set of changes enable
7737 the pic16 port to generate movff instructions and generate assembler
7742 * src/pic16/pcode.c:
7743 * src/pic16/device.c:
7745 * src/pic16/pcode.h:
7746 * src/pic16/pcoderegs.c:
7747 * src/pic16/ralloc.c:
7748 * src/pic16/ralloc.h:
7750 2003-06-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7752 * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
7753 added option --vc, so sdcc errors and warnings are compatible with
7754 Microsoft Visual Studio.
7756 2003-06-07 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7758 * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
7759 device/lib/libfloat.lib: added atof function.
7761 2003-06-04 Bernhard Held <bernhard AT bernhardheld.de>
7763 * doc/sdccman.lyx: updated to Lyx 1.3
7764 * doc/cdbfileformat.lyx: updated to Lyx 1.3
7765 * doc/test_suite_spec.lyx: updated to Lyx 1.3
7766 * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
7768 2003-06-03 Bernhard Held <bernhard AT bernhardheld.de>
7770 * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
7772 2003-06-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7774 * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
7775 additions to the "related tools/documentation" section
7777 2003-06-02 Bernhard Held <bernhard AT bernhardheld.de>
7779 * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
7781 2003-05-29 Bernhard Held <bernhard AT bernhardheld.de>
7783 * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
7784 * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
7786 2003-05-28 Bernhard Held <bernhard AT bernhardheld.de>
7788 * doc/sdccman.lyx: fix double dash and other minor things
7789 * doc/Makefile: fix double dash
7791 2003-05-28 Karl Bongers(patches from Martin Helmling)
7792 * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
7793 condition and ignore commands.
7795 2003-05-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7797 * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
7798 is in parts still quite out of date, I did changes as far as I felt makes sense
7799 for a non-native english speaker.
7800 Please feel free to add to the manual or to correct my changes.
7801 * doc/Makefile: undid touching the date of intermediate tex files.
7803 2003-05-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7805 * doc/sdccman.lyx: Manual has an index now
7807 2003-05-25 Bernhard Held <bernhard AT bernhardheld.de>
7809 Finalize muluint/mulsint and mululong/mulslong merging:
7810 * device/lib/_mulint.c
7811 * device/lib/_mullong.c
7812 * device/lib/gbz80/mul.s
7813 * device/lib/gbz80/stubs.s
7814 * device/lib/z80/mul.s
7815 * device/lib/z80/stubs.s
7816 * src/SDCCsymt.c (initCSupport)
7818 2003-05-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7820 * as/mcs51/lkaomf51.c: Address space 'z' was missing.
7821 * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
7822 src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
7823 src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
7826 2003-05-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7828 * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
7829 the regression tests I'm not brave enough to enable 245.b, 245.c
7830 * doc/sdccman.lyx: added latex preamble for hyperref package.
7831 Using pdflatex this will give you a hyperlinked pdf file with
7832 bookmarks. (prepend '%' before /usepackage if this breaks something)
7834 2003-05-24 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7836 * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
7838 2003-05-22 Bernhard Held <bernhard AT bernhardheld.de>
7840 * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
7842 2003-05-21 <johan AT balder>
7844 * src/SDCCglue.c (printIval): fixed bug #739934
7846 2003-05-19 Bernhard Held <bernhard AT bernhardheld.de>
7848 Applied patch from bug 737905 (renamed yylineo to mylineno):
7855 * src/pic16/pcode.c: Cleaned warnings
7856 * src/pic16/pcodeflow.c: Cleaned warnings
7857 * src/pic16/pcoderegs.c: Cleaned warnings
7859 2003-05-19 Scott Dattalo <scott AT dattalo.com>
7861 * src/pic16/pcode.c: Cleaned warnings
7862 * src/pic16/pcodepeep.c: Cleaned warnings
7863 * src/pic16/ralloc.c: Cleaned warnings
7865 2003-05-19 Bernhard Held <bernhard AT bernhardheld.de>
7867 * doc/sdccman.lyx: fixed bug 739745
7868 * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
7870 2003-05-18 Bernhard Held <bernhard AT bernhardheld.de>
7872 * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
7873 it can be defined with CFLAGS when running configure
7874 * src/SDCCmain.c: fixed compiling + linking with object files
7876 2003-05-18 Vangelis Rokas (vrokas AT otenet.gr)
7878 * configure.in: configure for pic16 port,
7879 added --disable-pic16-port
7880 * sdccconf_in.h: added macro OPT_DISABLE_PIC16
7881 * src/SDCCmain.c: linkOptions is changed to set *,
7882 added if/endif conditional macros to remove options help
7883 messages from optionsTable when a port is not configured, added
7884 support for the PIc16 port in the ports table, when executing
7885 the compiler with no port specified on command line, a default
7886 port is selected with the new macro DEFAULT_PORT which is
7887 defined in port.h, in setDefaultOptions() linkOptions is removed
7888 from initialization assignment, since now it is a set,
7889 parseCmdLine uses setParseWithComma for linkOptions, in
7890 linkEdit() linkOptions are accessed with new function indexSet()
7891 which returns the i'th item of a set variable. See SDCCset.c, in
7892 linkEdit() when calling buildCmdLine(), added linkOptions as
7893 last argument. Now users can pass arguments to gplink via the
7894 -Wl option, main() uses pic16glue() to glue up pic16 programs
7895 * src/SDCCpeeph.c: various changes to support pic16
7896 * src/SDCCset.c: added function void *indexSet(set *, int) to
7897 return the i'th item of the set
7898 * src/SDCCset.h: added function prototype for indexSet()
7899 * src/SDCCsymt.c: in checkSClass(), added support for PIC16
7900 * src/clean.mk: added pic16 in CLEANALLPORTS variable
7901 * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
7902 added macro DEFAULT_PORT
7903 * src/pic/main.c: corrected arguments of gplnk in _linkCmd
7904 * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
7906 * src/pic16/glue.c: commented out some error producing lines
7907 * src/pic16/main.c: __config directives are commented out to stop
7908 gpasm complaining and test the linkage with gplink, _linkCmd and
7909 _asmCmd changed to be more gplink and gpasm friendly
7910 * src/pic16/peeph.def: peep rule 3 is commented out, since it
7911 produced an error when parsed, peep rule 12 is added to utilize
7912 movff, but it is commented out since the pCode does not support
7913 yet a command with 2 address arguments
7915 2003-05-18 <johan AT balder>
7917 * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
7918 * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
7919 2003-05-17 Karl Bongers(apply patches from Martin Helmling)
7921 * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
7922 Added feature to script commands from file.
7924 2003-05-14 Bernhard Held <bernhard AT bernhardheld.de>
7926 * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
7927 * src/SDCCutil.c: include ctype.h for win32
7929 2003-05-13 Bernhard Held <bernhard AT bernhardheld.de>
7931 * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
7933 2003-05-12 Karl Bongers(apply development patches from Martin Helmling)
7935 * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
7936 Fixed so you can set breakpoints prior to run, run does not stop
7937 on entry now. Add tbreak. Other enhancements and fixes for use
7940 2003-05-12 Borut Razem <borut.razem AT siol.net>
7942 * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
7944 2003-05-11 Borut Razem <borut.razem AT siol.net>
7946 * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
7947 the path of bin directory, so that PATH is the only env. variable, which has to be set
7948 in case of standard installation.
7949 * src/ds390/ds390.dsp: increased value of /Zm option to 1000
7950 * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
7951 * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
7953 2003-05-04 Bernhard Held <bernhard AT bernhardheld.de>
7955 * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
7956 * support/regression/Makefile: inter-port-clean is no longer nesessary, the
7957 temp files are in the port dir; clean the gen/test directory when
7958 generating new test.c
7959 * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
7960 * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
7961 * support/regression/tests/zeropad.c: added
7963 2003-05-09 <johan AT balder>
7965 * src/SDCCglue.c: fixed bug #597940
7967 2003-05-05 Karl Bongers(apply patches from Martin Helmling)
7969 * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
7970 cache sfr, optimize next,step, fix off by one sourceline,
7971 support ddd list function.
7972 * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
7974 2003-05-04 Bernhard Held <bernhard AT bernhardheld.de>
7976 * support/regression/HTMLgen.py: added compare_s2f()
7977 * support/regression/Makefile: redo 1.27
7978 * support/regression/generate-cases.py: redo 1.5
7980 2003-04-30 Bernhard Held <bernhard AT bernhardheld.de>
7982 * support/regression/tests/float.c: workaround 33 bit hex constant
7983 * support/regression/tests/simplefloat.c: fix division for host
7985 2003-04-29 Scott Dattalo <scott AT dattalo.com>
7987 * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
7988 that tame's the PIC's over-aggressive optimizer.
7990 2003-04-29 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7992 * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
7995 2003-04-29 Kevin Vigor <kevin AT vigor.nu>
7997 Initial support for DS80C400. "Hello world" runs on TINIm400
8000 2003-04-28 Karl Bongers(apply patches for Martin Helmling)
8002 * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
8003 * Some notes on ddd usage added in debugger/README
8004 Martin Helmling adding more features and fixes for ddd GUI debugger.
8005 Code added for nexti, stepi, up, down, and other adjustments.
8007 2003-04-28 Scott Dattalo <scott AT DATTALO.COM>
8009 * src/pic/pCodepeep.c non-wildcard asmops are now handled
8010 * src/pic/peeph.def Added two rules to optimize carry manipulation
8011 * src/pic/* removed debug printfs
8013 2003-04-28 Bernhard Held <bernhard AT bernhardheld.de>
8015 * debugger/mcs51/cmd.c: added header newalloc.h
8017 2003-04-26 Bernhard Held <bernhard AT bernhardheld.de>
8019 * as/Makefile: new EXEEXT
8020 * as/z80/Makefile: remove trailing slash of BUILDIR
8021 * as/z80/clean.mk: new EXEEXT
8022 * Makefile.common.in: add to CFLAGS (and others), don't replace it
8023 * support/cpp2/Makefile.in: new EXEEXT
8024 * src/pic/glue.c (pic14emitRegularMap): fixed warning
8026 2003-04-24 Bernhard Held <bernhard AT bernhardheld.de>
8028 Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
8029 EXEEXT was introduced to fix all related problems with targets
8030 "clean", "install" and "uninstall"; a couple of further flaws
8031 especially with "clean" have been fixed too
8032 * as/mcs51/Makefile.in
8037 * debugger/mcs51/Makefile.in
8038 * debugger/mcs51/clean.mk
8040 * link/z80/Makefile.in
8043 * packihx/Makefile.in
8045 * sim/ucsim/Makefile
8046 * sim/ucsim/clean.mk
8047 * sim/ucsim/avr.src/Makefile.in
8048 * sim/ucsim/avr.src/clean.mk
8049 * sim/ucsim/s51.src/Makefile.in
8050 * sim/ucsim/s51.src/clean.mk
8051 * sim/ucsim/xa.src/Makefile.in
8052 * sim/ucsim/xa.src/clean.mk
8053 * sim/ucsim/z80.src/Makefile.in
8054 * sim/ucsim/z80.src/clean.mk
8055 * sim/ucsim/main_in.mk
8056 * sim/ucsim/packages_in.mk
8057 * sim/ucsim/gui.src/Makefile.in
8058 * sim/ucsim/gui.src/serio.src/Makefile.in
8059 * sim/ucsim/gui.src/serio.src/clean.mk
8062 * support/cpp2/Makefile.in
8063 * support/cpp2/clean.mk
8064 * support/makebin/Makefile
8065 * support/makebin/clean.mk
8066 * support/scripts/sdcc_mingw32: --program-suffix no longer needed
8067 * doc/sdccman.lyx: --program-suffix no longer needed
8069 2003-04-23 Karl Bongers(apply patches for Martin Helmling)
8071 * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
8072 Martin Helmling added support for ddd GUI debugger.
8073 Code added to display assembly, set variables, and other commands
8074 to interface to ddd.
8076 2003-04-23 Bernhard Held <bernhard AT bernhardheld.de>
8078 * as/Makefile: fix target clean
8079 * as/clean.mk: fix target clean
8080 * as/z80/clean.mk: fix target clean
8082 2003-04-22 Bernhard Held <bernhard AT bernhardheld.de>
8084 * Makefile.common.in: added AT EXEEXT AT
8085 * configure.in: removed all mingw32 stuff
8086 * configure: rebuilt from configure.in
8087 * doc/sdccman.lyx: updated section "installation"
8088 * support/scripts/sdcc_mingw32: adapted to configure
8089 * support/scripts/sdcc_cygwin_mingw32: added
8091 2003-04-22 Scott Dattalo <scott AT dattalo.com>
8093 * src/pic Added object file support for the PIC port
8094 * src/pic Applied patch from Craig Franklin (this started the object file support)
8095 * src/regression Updated the PIC regression tests for object files
8097 2003-04-20 Borut Razem <borut.razem AT siol.net>
8099 * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
8100 lklex.c: In function `getfid':
8101 lklex.c:203: warning: array subscript has type `char'
8102 * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
8103 with MSVC with global optimization enabled (probably an cl compiler bug ;-)
8104 * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
8105 stack handling macros
8107 2003-04-19 Borut Razem <borut.razem AT siol.net>
8109 * "handling space characters in file path" task:
8110 * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
8111 * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
8112 * support/Util/MySystem.h: make it self-sufficient
8113 * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
8114 src/z80/main.c, sdcc/as/mcs51/lklex.c:
8115 handling space characters in file path
8116 * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
8117 (it will be used by assemblers, which have their own includes, e.g. gpasm)
8118 * support/Util/MySystem.c: handling space characters in executable's path
8120 2003-04-19 Bernhard Held <bernhard AT bernhardheld.de>
8122 * as/z80/Makefile: fix permanent rebuild of z80
8123 * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
8124 * support/regression/tests/bitfields.c: added Johan's bitfields.c
8126 2003-04-18 Kevin Vigor <kevin AT vigor.nu>
8128 * src/SDCCopt.c: add special case optimization to replace modulo by
8129 a power of two with a bitwise AND.
8131 2003-04-18 <johan AT balder>
8133 * src/mcs51/gen.c (getFreePtr): fixed bug #635354
8135 2003-04-17 <johan AT balder>
8137 * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
8138 * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
8140 2003-04-13 Borut Razem <borut.razem AT siol.net>
8142 * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
8143 * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
8144 fixed mingw problem in adl_NORMALIZE_PATH
8146 2003-04-12 Borut Razem <borut.razem AT siol.net>
8148 * fixed "#pragma SAVE/RESTORE can not be nested":
8149 * src/SDCC.lex: reworked pragma handling functions
8150 * sdcc/src/SDCCglobl.h: reworked stack handling macros
8151 * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
8153 2003-04-12 Bernhard Held <bernhard AT bernhardheld.de>
8155 * src/SDCCutil.c (pathEquivalent): defined but not used
8156 * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
8157 * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
8158 * configure: rebuilt from configure.in
8159 * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
8160 * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
8161 * device/include/Makefile.in: replace sdcc_datadir
8162 * device/lib/Makefile.in: replace sdcc_datadir
8163 * Makefile.common.in: add LDFLAGS from configure
8164 * packihx/Makefile.in: use LDFLAGS
8165 * src/Makefile.in: use LDFLAGS
8166 * support/cpp2/Makefile.in: add LDFLAGS from configure
8167 * support/makebin/Makefile: use LDFLAGS
8168 * .version: bumped version number to 2.3.5
8170 2003-04-12 Borut Razem <borut.razem AT siol.net>
8172 * completed "different paths" task:
8173 * src/SDCCmacro.c: fixed bug in handling quotes
8174 * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
8175 * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
8177 2003-04-12 Bernhard Held <bernhard AT bernhardheld.de>
8179 * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
8181 2003-04-11 kevin Vigor <kevin AT vigor.nu>
8183 * ds390/gen.c ds390/peeph.def: fix bug 706781
8185 2003-04-11 Borut Razem <borut.razem AT siol.net>
8187 * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
8189 2003-04-10 Scott Dattalo <scott AT dattalo.com>
8191 * src/pic/* Applied the pointer-to-function patch from Steve Tell.
8192 * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
8193 set - this bit used to not be set...).
8194 * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
8195 bad code in PIC Port
8196 * src/regression/and2.c added to test bug 609268
8197 * src/regression/Makefile added and2.c to regression test
8200 2003-04-08 <johan AT CP255758-A>
8202 * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
8203 * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
8204 * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
8206 2003-04-07 Bernhard Held <bernhard AT bernhardheld.de>
8208 * configure.in: fully support prefix, exec_prefix, datadir, docdir;
8210 * support/cpp2/Makefile.in: fix bug #487815
8211 * configure: rebuilt from configure.in
8212 * Makefile.common.in: docdir changed, new path suffixes
8213 * sdccconf_in.h: new RETSIGTYPE, and other PATHs
8214 * sdcc_vc_in.h: reflect changes from sdccconf.h
8215 * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
8216 * src/SDCCutil.h: remove BINDIR hack
8217 * doc/sdccman.lyx: update new path hierarchy
8219 2003-04-06 Paul Stoffregen <paul AT pjrc.com>
8221 * src/SDCCpeeph.c: added okToRemoveSLOC test
8223 2003-04-06 Paul Stoffregen <paul AT pjrc.com>
8225 * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
8227 2003-04-06 Paul Stoffregen <paul AT pjrc.com>
8229 * src/SDCCpeeph.c: added labelIsReturnOnly test
8230 * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
8232 2003-04-05 <johan AT balder>
8234 * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
8235 * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
8236 * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
8237 * src/SDCCast.c: fixed a warning
8238 * src/SDCCast.h: fixed a warning
8239 * src/SDCCicode.c (operandFromAst): fixed a warning
8241 2003-04-04 <johan AT balder>
8243 * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
8244 * src/SDCCast.c (decorateType): fixed bug #715076
8245 * src/SDCC.y: fixed bug #702907
8247 2003-04-03 <johan AT balder>
8249 * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
8250 * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
8251 * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
8252 * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
8253 * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
8255 2003-04-03 Bernhard Held <bernhard AT bernhardheld.de>
8257 * _decdptr.c: fix return values
8258 * _gptrget.c: fix return values
8259 * _gptrgetc.c: fix return values
8260 * _gptrput.c: fix return values
8261 * _mulint.c: fix return values
8262 * as/z80/Makefile: fix 'make -j' problem
8264 2003-04-02 Bernhard Held <bernhard AT bernhardheld.de>
8266 * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
8267 * configure.in: big cleanup, updated to autoconf 2.5x
8268 * configure: rebuilt from configure.in
8269 * sdccconf_in.h: new RETSIGTYPE, and other PATHs
8270 * sdcc_vc_in.h: reflect changes from sdccconf.h
8271 * doc/Makefile: fixed a flaw in "make install"
8273 2003-04-02 <johan AT balder>
8275 * src/ds390/gen.c (genCmp): no comments
8276 * src/mcs51/gen.c (genCmp): no comments
8277 * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
8278 * src/SDCCast.c (ast_print): fixed the function type in --dumptree
8280 2003-04-01 Bernhard Held <bernhard AT bernhardheld.de>
8282 * support/regression/generate-cases.py: place generated file in given sub directory
8283 * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
8284 * support/regression/Makefile: improvements for 'make -j';
8285 side effect: it's simpler and faster now
8287 2003-03-31 Borut Razem <borut.razem AT siol.net>
8289 * src/z80/main.c: link-{port} and as-{port} defined without path
8290 * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
8292 2003-03-31 Bernhard Held <bernhard AT bernhardheld.de>
8294 * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
8296 2003-03-30 Borut Razem <borut.razem AT siol.net>
8298 * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
8299 changed type of list parameter to set
8300 * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
8301 * src/port.h: changed type of do_assemble() parameter to set
8302 * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
8303 sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
8304 definition of "cppoutfilename" macro with NULL value in preProcess()
8305 * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
8306 * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
8307 * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
8308 replaced with set *binPathSet
8309 * shash_add() deallocates the item, if allready exsists, before adding the new one
8310 * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
8312 2003-03-30 Scott Dattalo <scott AT dattalo.com>
8314 * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
8315 a nested for loop bug in the PIC port
8316 * src/regression/nestfor.c: new regression test file Steve wrote to test nested
8319 2003-03-29 Bernhard Held <bernhard AT bernhardheld.de>
8321 * support/Util/dbuf.h: remove C++ stuff to make it portable
8323 2003-03-28 Borut Razem <borut.razem AT siol.net>
8325 * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
8326 literal strings in stringLiteral()
8327 * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
8328 * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
8331 2003-03-27 Paul Stoffregen <paul AT pjrc.com>
8333 * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
8335 2003-03-26 <johan AT balder>
8337 * src/mcs51/gen.c (saveRegisters): catched symbol abuse
8338 * src/ds390/gen.c (saveRegisters): catched symbol abuse
8339 * src/SDCCast.c (decorateType): fixed " -v < 3"
8341 2003-03-23 Bernhard Held <bernhard AT bernhardheld.de>
8343 * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
8344 Added Lenny Story's debug infrastructure changes:
8345 * src/Makefile.in: added new files cdbFile.c and SDCCdebug.c
8346 * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
8347 * src/cdbFile.c: added
8348 * src/SDCCdebug.c: added
8349 * src/SDCCdebug.h: added
8350 * src/SDCCast.c (createFunction)
8351 * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
8352 * src/SDCCmain.c (parseCmdLine, main)
8353 * src/SDCCmem.c (redoStackOffsets)
8354 * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
8357 * src/avr/gen.c (genAVRCode)
8358 * src/ds390/gen.c (gen390Code)
8359 * src/mcs51/gen.c (gen51Code)
8360 * src/pic/gen.c (genpic14Code)
8361 * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
8362 * src/xa51/gen.c (genXA51Code)
8363 * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
8365 2003-03-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8367 * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
8368 * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
8370 2003-03-22 <johan AT balder>
8372 * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
8374 2003-03-21 Bernhard Held <bernhard AT bernhardheld.de>
8376 * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
8377 * doc/cdbfileformat.lyx: added, written by Lenny Story
8378 * doc/Makefile: added cdbfileformat.lyx
8379 * doc/clean.mk: added cdbfileformat.lyx
8381 2003-03-20 Bernhard Held <bernhard AT bernhardheld.de>
8383 * src/mcs51/peeph.def: fix bug #705773
8385 2003-03-20 <johan AT balder>
8387 An sfr/sbit can have an "at #" AND an initializer
8388 * src/SDCCsymt.c (checkSClass):
8389 * src/SDCCmem.c (allocGlobal):
8390 * src/SDCCmem.c (allocLocal):
8391 * src/SDCCast.c (createBlock):
8393 2003-03-17 Bernhard Held <bernhard AT bernhardheld.de>
8395 * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
8397 2003-03-16 <johan AT balder>
8399 Undid the hackup of const and volatile, the problem is much bigger
8401 * src/SDCCast.c:1.171
8402 * src/SDCCglue.c:1.138
8403 * src/SDCCicode.c:1.146
8404 * src/SDCCsymt.c:1.150
8405 * src/SDCCval.c:1.65
8407 2003-03-15 Bernhard Held <bernhard AT bernhardheld.de>
8409 * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
8410 * src/ds390/gen.c (genAddrOf): fixed bug #704087
8412 2003-03-13 <johan AT balder>
8414 Hackup const and volatile modifiers in type chains a bit:
8416 * src/SDCCast.c:1.169
8417 * src/SDCCglue.c:1.136
8418 * src/SDCCicode.c:1.143
8419 * src/SDCCsymt.c1.146
8420 * src/SDCCsymt.h1.59
8421 * src/SDCCval.c:1.63
8423 2003-03-12 <johan AT balder>
8425 * src/SDCCBBlock.h: more LRH debugging junk
8426 * src/SDCCcflow.h: more LRH debugging junk
8427 * src/SDCCloop.c: more LRH debugging junk
8428 * src/SDCC.y (struct_declaration): fixed bug #697590
8429 * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
8430 * src/ds390/gen.c (aopForRemat): fixed bug #700031
8431 * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
8433 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
8434 * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
8435 test function names must now match exactly).
8436 * src/SDCCcse.c: added special case in findCheaperOp to allow
8437 extending a short integer. Makes less awful code for bug 700121 test case.
8439 2003-03-11 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8441 * as/mcs51/lkmain.c: Added ASlink-Warning to messages
8442 * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
8444 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
8446 * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
8447 actually called (operandsNotEqual() was called for all
8448 operandsNotEqualX tests).
8450 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
8452 * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
8453 with shorter literals. Fixes bug 700121.
8455 2003-03-11 <johan AT balder>
8457 * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
8459 2003-03-11 Bernhard Held <bernhard AT bernhardheld.de>
8461 * src/SDCCloop.c (mergeRegions): an evil beast is dead
8462 * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
8464 2003-03-10 Borut Razem <borut.razem AT siol.net>
8466 * src/SDCCmain.c: pipe preprocessor's output
8467 * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
8468 * sdcc_vc_in.h: define pclose as _pclose for WIN32
8469 * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
8470 which closes all pipes in pipeSet set
8471 * src/SDCCset.c: free deleted item in function deleteSetItem()
8472 * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
8473 moved from z80 to src subproject
8474 * .version: increased version number to 2.3.4
8476 2003-03-10 Bernhard Held <bernhard AT bernhardheld.de>
8478 * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
8479 * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
8480 * support/regression/ports/xa51/spec.mk: fix typo
8482 2003-03-09 Bernhard Held <bernhard AT bernhardheld.de>
8484 * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
8486 2003-03-09 Borut Razem <borut.razem AT siol.net>
8488 * src/SDCCmain.c: pipe preprocessor's output
8489 * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
8490 * sdcc_vc_in.h: define pclose as _pclose for WIN32
8491 * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
8492 which closes all pipes in pipeSet set
8493 * src/SDCCset.c: free deleted item in function deleteSetItem()
8494 * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
8495 moved from z80 to src subproject
8497 2003-03-09 Borut Razem <borut.razem AT siol.net>
8499 * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
8500 * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
8501 * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
8502 * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
8503 * src/SDCCglobl.h: unification of WIN32 native definitions
8505 2003-03-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8507 * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
8509 2003-03-08 Bernhard Held <bernhard AT bernhardheld.de>
8511 * src/configure.in: check for endianess (even while cross-compiling)
8512 * src/configure: check for endianess (even while cross-compiling)
8513 * src/configure_in.h: check for endianess (even while cross-compiling)
8514 * src/avr/gen.c: remove old endianess stuff
8515 * src/mcs51/gen.c: remove old endianess stuff
8516 * src/ds390/gen.c: remove old endianess stuff
8517 * src/pic/gen.c: remove old endianess stuff
8518 * src/pic/genarith.c: remove old endianess stuff
8519 * src/pic/glue.c: fix endianess check
8520 * src/pic16/gen.c: remove old endianess stuff
8521 * src/pic16/genarith.c: remove old endianess stuff
8522 * src/pic16/glue.c: fix endianess check
8523 * src/xa51/gen.c: remove old endianess stuff
8524 * src/z80/gen.c: fix endianess check
8525 * src/SDCCglue.c: fix endianess check
8526 * src/ds390/peeph.def: fix bug 700036
8528 2003-03-08 Bernhard Held <bernhard AT bernhardheld.de>
8530 * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
8531 * src/configure: find appropriate data-types on host for SDCC's int and long
8532 * src/configure.in: find appropriate data-types on host for SDCC's int and long
8533 * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
8534 * src/xa51/gen.c: use %d, not %ld for 4 byte variables
8536 2003-03-07 <johan AT balder>
8539 some minor cleanups before the big shot
8540 OP_DEFS and OP_USES now use Kevin's protection
8541 new option --nolabelopt
8552 * src/ds390/ralloc.c:
8553 * src/mcs51/ralloc.c:
8555 * src/xa51/ralloc.c:
8558 2003-03-06 Bernhard Held <bernhard AT bernhardheld.de>
8560 * src/pic/pcode.c (get_op): fix 64 bit warnings
8561 * src/pic/pcode.c (pCode2str): fix 64 bit warnings
8562 * src/SDCChasht.c (newHashTable): fix 64 bit warnings
8563 * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
8564 * support/regression/tests/malloc.c: fix 64 bit warnings
8566 2003-03-04 Bernhard Held <bernhard AT bernhardheld.de>
8568 * src/mcs51/gen.c (genMinus): fixed bug 696436
8570 2003-03-02 Borut Razem <borut.razem AT siol.net>
8572 * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
8574 2003-02-26 Bernhard Held <bernhard AT bernhardheld.de>
8576 * configure.in: test for mkstemp
8577 * sdccconf_in.h: add HAVE_MKSTEMP
8579 2003-02-24 Bernhard Held <bernhard AT bernhardheld.de>
8581 * device/include/ctype.h: removed warning while using --stack-auto
8582 * device/include/malloc.h: removed warning while using --stack-auto
8583 * device/include/string.h: removed warning while using --stack-auto
8585 2003-02-23 Borut Razem <borut.razem AT siol.net>
8587 * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
8588 because NDEBUG is defined (see man assert)
8589 * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
8591 2003-02-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8593 * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
8594 * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
8596 2003-02-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8598 * src/SDCCpeeph.c: added peephole conditions testing for same arguments
8599 * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
8601 2003-02-18 <johan AT balder>
8603 * as/mcs51/asmain.c (asmbl): module can start with a digit
8604 * as/z80/asmain.c (asmbl): module can start with a digit
8606 2003-02-16 Bernhard Held <bernhard AT bernhardheld.de>
8608 * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
8609 * src/asm.c: fix pipe() for Mingw32
8611 2003-02-15 Bernhard Held <bernhard AT bernhardheld.de>
8613 * src/SDCCglue.h: make tmpfileNameSet available for preOutName
8614 * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
8615 make -V work again; --c1mode reads now from stdin
8616 * doc/sdccman.lyx: added --c1mode
8617 * support/Util/SDCCerr.c: new messages for c1 mode
8618 * support/Util/SDCCerr.h: new messages for c1 mode
8619 * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
8621 2003-02-15 <johan AT balder>
8623 * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
8625 2003-02-14 Bernhard Held <bernhard AT bernhardheld.de>
8627 * doc/sdccman.lyx: Environment variables, -o and other minor things
8629 2003-02-14 <johan AT balder>
8631 * src/xa51/main.c: before anyone really tries to use it :)
8633 * Install doc's in share/sdcc/doc
8634 * removed some obsolete files
8635 * Do a proper make distclean and uninstall
8636 M Makefile.common.in
8639 M device/include/Makefile.in
8640 M device/lib/Makefile.in
8643 M sim/ucsim/doc/Makefile.in
8646 R src/xa51/peeph.rul
8647 M support/cpp2/Makefile.in
8648 M support/makebin/Makefile
8651 2003-02-13 Bernhard Held <bernhard AT bernhardheld.de>
8653 * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
8655 2003-02-10 Borut Razem <borut.razem AT siol.net>
8657 * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
8658 support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
8659 * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
8660 device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
8661 support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
8662 src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
8663 src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
8664 src/z80/Makefile.bcc: Borland Makefile cleanup
8665 * as/z80/Makefile.bcc: Added Borland Makefile
8666 * support/cpp2/borland.h: Removed
8668 2003-02-10 Bernhard Held <bernhard AT bernhardheld.de>
8670 * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
8671 * src/SDCC.lex: new pragma NOIV
8672 * src/SDCCglobl.h: new pragma NOIV
8673 * src/SDCCmem.c: new pragma NOIV
8675 2003-02-09 Bernhard Held <bernhard AT bernhardheld.de>
8677 * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
8679 2003-02-09 Bernhard Held <bernhard AT bernhardheld.de>
8681 * src/SDCCmain.c: signal handling is switched off by --debug
8682 * doc/Makefile: small fix for install; use clean.mk again
8683 * doc/clean.mk: clean *.pdf and *.html too
8685 2003-02-08 Bernhard Held <bernhard AT bernhardheld.de>
8687 * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
8688 * device/lib/printfl.c: fix a ds390 bug by making it portable
8689 * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
8690 * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
8691 * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
8692 * debugger/mcs51/cmd.c: converted multi-line string literals
8693 * sim/ucsim/globals.cc: converted multi-line string literals
8694 * src/SDCCmain.c: introduced signal handler to remove temp files
8695 * doc/Makefile: small tweaks, implement clean
8696 * doc: removed generated files
8698 2003-02-05 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8700 * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c: Applied
8701 patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
8702 Address Record is not correctly generated for DS390."
8704 2003-02-02 Borut Razem <borut.razem AT siol.net>
8706 * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
8707 * as/mcs51/asm.h: fixed compilation with Borland C
8708 * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
8709 * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
8710 * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
8711 * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
8712 src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
8713 src/z80/Makefile.bcc: delete $(LIB) only if exist
8714 * src/Makefile.bcc, src/pic/Makefile.bcc: fixed compilation with Borland C
8716 2003-02-02 Bernhard Held <bernhard AT bernhardheld.de>
8718 * device/include/malloc.h: introduced NULL
8719 * device/include/string.h: introduced NULL
8720 * device/include/stdlib.h: introduced NULL
8721 * device/lib/_memcpy.c: removed NULL
8722 * device/lib/_strcat.c: removed NULL
8723 * device/lib/_strchr.c: removed NULL
8724 * device/lib/_strcmp.c: removed NULL
8725 * device/lib/_strcpy.c: removed NULL
8726 * device/lib/_strcspn.c: removed NULL
8727 * device/lib/_strlen.c: removed NULL
8728 * device/lib/_strncat.c: removed NULL
8729 * device/lib/_strncmp.c: removed NULL
8730 * device/lib/_strncpy.c: removed NULL
8731 * device/lib/_strpbrk.c: removed NULL
8732 * device/lib/_strrchr.c: removed NULL
8733 * device/lib/_strspn.c: removed NULL
8734 * device/lib/_strstr.c: removed NULL
8735 * device/lib/_strtok.c: removed NULL
8736 * device/lib/malloc.c: removed NULL, include own header
8738 2003-02-02 <johan AT balder>
8740 * 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
8741 * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
8742 * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
8743 * src/z80/gen.c (genZ80Code): added c-lines in asm comments
8744 * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
8745 * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
8747 2003-02-01 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8749 * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
8752 2003-02-01 <johan AT balder>
8754 * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
8756 2003-01-31 <johan AT CP255758-A>
8758 * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
8760 2003-01-30 <johan AT balder>
8762 * src/SDCCBBlock.c: automatic bug detection
8763 * src/SDCCicode.c: automatic bug detection
8765 2003-01-29 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8767 * src/SDCCglobl.h: now --xram-size 0 works
8768 * src/SDCCmain.c: now --xram-size 0 works
8770 2003-01-29 <johan AT balder>
8772 * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
8774 2003-01-29 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8776 * as/mcs51/aslink.h: Added options --xram-size and --code-size
8777 * as/mcs51/lkdata.c: Added options --xram-size and --code-size
8778 * as/mcs51/lkmain.c: Added options --xram-size and --code-size
8779 * as/mcs51/lkmem.c: Added options --xram-size and --code-size
8780 * src/SDCCglobl.h: Added options --xram-size and --code-size
8781 * src/SDCCmain.c: Added options --xram-size and --code-size
8783 2003-01-28 Bernhard Held <bernhard AT bernhardheld.de>
8785 * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
8786 * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
8788 2003-01-27 <johan AT balder>
8790 * src/SDCC.y: fixed bug #613764
8792 2003-01-26 <johan AT balder>
8794 * src/SDCClrange.c: fixed Bernhard's "char * code ptr = &c"
8795 * src/SDCCsymt.h: fixed bug #673374
8796 * src/SDCCglue.c: fixed bug #661910
8797 * src/SDCCast.c: fixed bug #458099 and 673374
8799 2003-01-26 Bernhard Held <bernhard AT bernhardheld.de>
8801 * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
8802 * as/mcs51/strcmpi.h: added
8803 * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
8804 * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
8805 * as/mcs51/asmain.c: strcmpi -> as_strcmpi
8806 * as/mcs51/assym.c: strcmpi -> as_strcmpi
8807 * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
8808 * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
8809 * as/mcs51/lksym.c: strcmpi -> as_strcmpi
8810 * as/mcs51/Makefile.aslink: new module strcmpi
8811 * as/mcs51/Makefile.asx8051: new module strcmpi
8812 * as/mcs51/Makefil.bcc: new module strcmpi
8813 * as/mcs51/Makefile.in: new module strcmpi
8814 * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
8816 2003-01-26 <johan AT balder>
8818 * src/SDCCglue.c: reverted back to 1.124
8819 * src/SDCCast.c: reverted back to 1.156
8820 * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
8822 2003-01-25 <johan AT balder>
8824 * src/SDCCglue.c: A better fix for bug #661910
8825 * src/SDCCast.c: A better fix for bug #661910
8826 * src/SDCCglue.c (emitRegularMap): That was a little too efficient
8828 2003-01-24 Bernhard Held <bernhard AT bernhardheld.de>
8830 * src/Makefile.in: remove spawn.o
8831 * src/SDCCmain.c: remove spawn.h
8832 * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
8833 * src/spawn.c: removed
8834 * src/spawn.h: removed
8835 * support/regression/ports/ds390/spec.mk: link with -r
8837 2003-01-24 <johan AT CP255758-A>
8839 * src/ds390/gen.c (aopOp): fixed bug #667458
8840 * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
8841 * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
8842 (createIvalCharPtr): an ival doesn't always have a storage class anymore
8844 2003-01-24 Bernhard Held <bernhard AT bernhardheld.de>
8846 * src/mcs51/peeph.def: better assembler identation by Frieder
8847 * src/mcs51/gen.c: better assembler identation by Frieder
8849 2003-01-22 Bernhard Held <bernhard AT bernhardheld.de>
8851 * as/z80/string.h: removed for gcc 3.2
8852 * support/makebin/makebin.c: #include <string.h> for gcc 3.2
8853 * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
8855 2003-01-19 Bernhard Held <bernhard AT bernhardheld.de>
8857 * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
8858 * src/SDCCpeeph.c (replaceRule): fix bug #663503
8859 * support/regression/Makefile: separate temp files for ports
8860 * support/regression/generate-cases.py: separate temp files for ports
8861 * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
8862 * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
8864 2003-01-19 Bernhard Held <bernhard AT bernhardheld.de>
8866 * moved tinitalk to device/examples/ds390
8868 2003-01-14 Bernhard Held <bernhard AT bernhardheld.de>
8870 * as/mcs51/lkmem.c: rflag is for DS390
8871 * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
8872 * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
8873 (linkEdit): move mem- and map-files the same way as ihx-files
8874 * src/z80/main.c (_setDefaultOptions): removed --generic
8875 * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
8876 * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
8877 * src/pic/glue.c (picglue): --c1mode works again
8878 * src/pic16/glue.c (pic16glue): --c1mode works again
8879 * src/asm.c (printCLine): fix #660034
8881 2003-01-13 Bernhard Held <bernhard AT bernhardheld.de>
8883 * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
8884 * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
8885 * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
8886 * as/mcs51/lkmem (summary): better fix for sp problem
8887 * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
8888 * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
8889 * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
8890 remove --stack-after-data
8892 2003-01-12 Bernhard Held <bernhard AT bernhardheld.de>
8894 * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
8895 * src/SDCCutil.c (join): ugly bug: missing '\0'
8896 * as/mcs51/lkmem.c (summary): sp on address 7 is safe
8898 2003-01-11 Bernhard Held <bernhard AT bernhardheld.de>
8900 * src/SDCCmain.c (assemble, linkEdit): preparations for -o
8902 * src/pic/main.c (_asmCmd): gpasm supports -o
8903 * src/z80/main.c: more general macros
8904 * device/lib/Makefile.in: remove intermediate files
8906 2003-01-11 Bernhard Held <bernhard AT bernhardheld.de>
8908 * .version: Bumped version number to 2.3.3
8909 * src/SDCCBBlock.c: new option -o
8910 * src/SDCCglobl.h: new option -o
8911 * src/SDCCglue.c: new option -o
8912 * src/SDCCmain.c: new option -o
8913 * src/asm.c: new option -o
8914 * src/ds390/main.c: new option -o
8915 * src/pic/glue.c: new option -o
8916 * src/pic/pcode.c: new option -o
8917 * src/pic/ralloc.c: new option -o
8918 * src/pic16/glue.c: new option -o
8919 * src/pic16/pcode.c: new option -o
8920 * src/pic16/ralloc.c: new option -o
8921 * src/z80/main.c: new option -o
8922 * device/lib/Makefile.in: use -o
8923 * support/regression/ports/ds390/spec.mk: use -o
8924 * support/regression/ports/gbz80/spec.mk: use -o
8925 * support/regression/ports/mcs51/spec.mk: use -o
8926 * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
8927 * support/regression/ports/z80/spec.mk: use -o
8928 * support/regression/ports/ucz80/spec.mk: use -o
8929 * support/regression/ports/xa51/spec.mk: use -o
8930 * support/regression/fwk/lib/timeout.c: fix usage string
8932 2003-01-09 Bernhard Held <bernhard AT bernhardheld.de>
8933 * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
8935 2003-01-07 <johan AT balder>
8937 * src/SDCCast.c (decorateType): fixed bug #600035
8939 2003-01-07 Bernhard Held <bernhard AT bernhardheld.de>
8940 * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
8941 * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
8942 * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
8943 * src/pic/pcode.c: outcommented unused variable to remove warnings
8944 * src/pic/ralloc.c: outcommented unused variable to remove warnings
8946 2003-01-06 <karl AT turbobit.com>
8947 * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
8950 2003-01-06 <johan AT balder>
8952 * src/SDCCicode.c: fixed array add
8954 2002-01-05 Bernhard Held <bernhard AT bernhardheld.de>
8955 * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
8956 * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
8958 2003-01-04 <johan AT balder>
8960 * src/SDCCval.c (getNelements): fixed the initialized array of structures
8962 2002-12-29 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8963 * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
8965 2002-12-28 Bernhard Held <bernhard AT bernhardheld.de>
8966 * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
8967 * support/regression/tests/bug-524697.c: fit mem usage into 8032
8969 2002-12-28 Bernhard Held <bernhard AT bernhardheld.de>
8970 * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
8972 2002-12-27 Bernhard Held <bernhard AT bernhardheld.de>
8973 * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
8975 2002-12-26 Bernhard Held <bernhard AT bernhardheld.de>
8976 * src/mcs51/main.c: removed {bindir}{sep} from aslink
8978 2002-12-10 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8980 * in \sdcc\as\mcs51\ changed these files in order to create an
8981 aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
8982 lkmain.c. Also added: lkmem.c and lkaomf51.c. Changed the
8983 following files to include the previous two files: aslink.dsp,
8984 Makefile.aslink, Makefile.bcc, and Makefile.in.
8986 * Changed \sdcc\src\SDCCmain.c so it creates files with extension
8987 .adb instead of .cdb
8989 2002-11-09 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8991 * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
8992 value from option --iram-size.
8994 2002-09-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8996 * \sdcc\as\mcs51\lklist.c: added boundary check before using
8999 2002-09-18 <wiml AT hhhh.org>
9001 * SDCClrange.h: exposed setFromRange() and setToRange()
9002 * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
9003 packRegsForAccUse() (bug 542397)
9004 * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
9005 multiple times and emitting the fetch operations more than once
9006 added aopGetUsesAcc() function to allow binary operators to
9007 fetch their operands in the correct order; made genMinus() emit
9008 compact code for X = LITERAL - Y
9010 2002-09-00 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9011 * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
9012 sprintf() in line 1267.
9014 2002-09-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9015 * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
9018 2002-09-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9019 Changes to aslink (All the changes are marked with 'JCF'):
9021 * \sdcc\as\mcs51\aslink.h: External definition of sflag and
9024 * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
9025 area BSEG. Also moves, if possible, the DATA area down into the internal
9026 ram so more space is available.
9028 * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
9031 * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
9032 not bytes. Function summary() which creates a memory usage summary
9033 file with extension .mem. Reports of overlaping stack and small stack
9034 size. If the space for the stack is less than 16 bytes aslink trows a
9037 * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
9038 the 8051. Option 'y' for memory summary output file.
9040 Changes to sdcc (All the changes are marked with 'JCF'):
9042 * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
9044 * \sdcc\src\SDCCglue.c: If a register bank is used, creates an
9045 overlaying area for it (uses RegBankUsed[4]).
9047 * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
9048 bank zero as used by default. By default aslink locates the stack
9049 (equivalent to --stack-after-data). Pass option 'y' to aslink for
9050 the creation of the .mem file. Delegates the allocation of data area
9051 to aslink (it is not longer 0x30 by default). If --stack-loc passes
9052 the begining of the stack area to aslink.
9054 * \sdcc\src\SDCCmem.c: If a register bank is used, marks it so
9055 glue() in SDCCglue.c creates an area for it.
9057 2002-09-03 Borut Razem <borut.razem AT siol.net>
9058 * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
9059 sdcc/src/pic/glue.c:
9060 introduced atexit() handler for teporay files removal in case of
9061 errors, assertions, ...
9063 2002-08-29 Borut Razem <borut.razem AT siol.net>
9064 * sdcc/support/cpp2/auto-host_vc_in.h:
9065 re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
9066 with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
9067 Maybe there is a similar problem with BORLANDC? It should be checked!
9069 * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
9070 corrected improper use of assert: the assignment to clr variable was done inside the assert.
9071 In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
9072 was not executed, and the compiler (cl) launched a warning:
9073 ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
9075 2002-08-28 Bernhard Held <bernhard AT bernhardheld.de>
9076 * src/SDCCglue.c (printIvalArray): iterative calculation of array length
9078 2002-08-28 Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
9079 * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
9081 * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
9082 sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
9083 sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
9084 sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
9085 sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
9086 sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
9087 sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
9088 - added Release configuration in VS projects
9089 - review of compiler an linker options
9090 - VC .exe files are generated in bin_vc directory, not to interfere
9091 with binaries generated from other projects (cygwin, mingw, bcc ...)
9093 * sdcc/src/yacc.dsp: added
9095 * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
9096 added - genarate sdcc_vc.h using sdcc_vc_in.h as template
9097 and insert the version number definitions from .version
9099 * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
9101 * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
9102 added - genarate auto-host.h using auto-host_vc_in.h as template
9105 removed from CVS, generated automatically
9107 2002-08-25 Bernhard Held <bernhard AT bernhardheld.de>
9108 * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
9110 2002-08-11 Borut Razem <borut.razem AT siol.net>
9111 * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
9113 2002-08-10 Borut Razem <borut.razem AT siol.net>
9114 * src/SDCCmain.c (main):
9115 file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
9116 platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
9117 The consequence was that some temporary files were not removed.
9120 unification of code in functions tempfilename() and tempfile():
9121 function tempnam() is defined in Visual Studio 6.0 and .NET
9123 * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
9125 * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
9126 sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
9127 - removed compiler command line option /WX: Treats all warnings as errors
9128 - update a list of source files, included into the project
9130 * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
9131 sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
9132 changed project type to Generic Project so that can be correcly converted to VS.NET project
9134 * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
9136 * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
9138 * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
9140 * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
9141 added return 0 statements after assert() to make compiler happy
9143 * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
9144 added newline in the def file to keep MSC compiler satisfied
9146 * sdcc/src/z80/gen.c:
9147 - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
9148 so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
9149 - solved MSC error in function aopDump()
9151 * sdcc_vc.h: define PREFIX as "\\sdcc"
9153 2002-07-18 Bernhard Held <bernhard AT bernhardheld.de>
9154 * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
9156 2002-06-22 Scott Dattalo <scott AT dattalo.com>
9157 * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
9158 - Rewrote the register banking algorithm.
9159 - Added pCode live-range analysis to registers (for now, only non-used and
9160 singly-used registers optimized away)
9162 * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
9164 * 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.
9166 2002-05-10 Scott Dattalo <scott AT dattalo.com>
9167 * src/pic/*: Added support for multiplication. Fixed many,many bugs.
9169 2002-04-22 Michael Hope <michaelh AT vroom>
9171 * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
9173 * configure.in (DD_COPT): Added include support required for gbdk.
9175 * .version: Bumped version number just to increase it.
9177 * src/SDCCmain.c: Added -nostdinc to the default options.
9179 2002-04-15 Michael Hope <michaelh AT vroom>
9181 * device/lib/z80/printf.c (sprintf): Added.
9183 * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
9185 * src/z80/peeph.def: Added transpose redundent load rule.
9187 * src/z80/main.c: Added force callee saves for jaune.
9189 * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
9191 * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
9193 2002-03-28 Johan Knol <johan AT balder>
9195 * src/SDCCval.c: fixed bug #532436
9197 2002-03-14 Scott Dattalo <scott AT dattalo.com>
9199 Added "char *Processor" field to the port structure.
9202 Added -p option. Allows port dependent processor to be specified.
9205 Initialized the new field char *Processor field to NULL in all ports
9208 Compiler generated registers for interrupt context saving
9209 were not getting allocated.
9211 2002-03-16 Sandeep Dutta <sandeep AT ddi.com>
9214 Fixed left shift. Will promote the left side of a left shift
9215 if a) left shifting more than size of operand or b) when assigned
9216 to something size > size of left side
9218 2002-03-14 Scott Dattalo <scott AT dattalo.com>
9220 tons of changes. Register allocation has been
9221 rewritten. Added customization for the various PICs. Flow
9222 analysis is restructured. ...
9228 Added. device.c is a PIC port hack to accomodate variations
9231 2002-03-13 Michael Hope <michaelh AT vroom>
9233 * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled. Yeah.
9235 2002-03-04 johanknol <johanknol AT manik>
9237 * /src/SDCCval.c: fixed
9239 const unsigned char arr[][2] = { { 0, 1 } };
9240 t18.c:1: error: Initializer element is not constant
9242 2002-03-04 bela <bela AT manik>
9244 * /device/include/mcs51reg.h:
9245 ds89c420 register definition update
9247 2002-03-03 <johan AT FRIJA>
9249 * support/Util/SDCCerr.c: did something, but don't no why anymore
9251 * support/regression/tests/bug-524691.c: made it a little less shy
9253 * src/SDCCast.c (decorateType): fixed bug #524697
9255 * src/SDCCast.c: made some lineno improvements
9257 * src/SDCCval.c (getNelements): changed warning to error
9259 * src/SDCCglue.c (printIvalArray): changed warning to error
9261 * src/SDCCicode.c: fixed a warning for mingw
9263 * src/SDCCast.c (decorateType): fixed the << promotion for ops
9265 * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
9267 2002-03-02 Sandeep Dutta <sandeep AT ddi.com>
9269 * src/ds390/peeph.def:
9270 Added some more peephole rules
9272 * src/ds390/gen.c: Various fixes & enhancements
9274 * src/SDCClrange.c, src/SDCClrange.h:
9275 functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
9277 * src/ds390/ralloc.c:
9278 various fixes & enhancements (ds390) specific
9280 * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
9281 Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
9284 * sdcc/src/SDCCcse.c: Better fix for bug # 514308
9286 2002-03-02 <johan AT FRIJA>
9288 * src/SDCCast.c (decorateType): fixed bug #524708
9290 * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
9292 * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
9294 2002-03-01 Michael Hope <michaelh AT vroom>
9296 * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
9298 * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
9300 2002-03-01 <johan AT FRIJA>
9302 * src/SDCCglue.c (printIvalPtr): fixed bug #524211
9304 * src/SDCCast.c (decorateType): fixed bug #524209
9306 * src/SDCCval.c (valNot): fixed bug #524195
9308 2002-02-26 <johan AT balder>
9310 * src/xa51/gen.c: fixed a warning
9312 * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
9314 * src/SDCCast.c (decorateType): fixed bug #522534
9316 2002-02-23 <johan AT balder>
9318 * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
9320 2002-02-22 <johan AT balder>
9322 * src/SDCCast.c: fixed bug #514865
9324 * src/SDCCy.c ("SDCC.y"): fixed bug #516625
9326 2002-02-21 Sandeep Dutta <sandeep AT ddi.com>
9328 * sdcc/src/SDCCloop.c:
9329 Previous fix was not good. basic blocks that have "break" or "return" are
9330 not really partof a loop , but live ranges used in these blocks should
9331 be live thru the entire loop, so set partOfLoop but don't add them to
9334 2002-02-21 <johan AT FRIJA>
9336 * src/SDCCcse.c: fixed bug #514308
9338 2002-02-20 Sandeep Dutta <sandeep AT ddi.com>
9341 Fixed BUG #519583. If a conditional block ended in a return/break
9342 statement inside a loop, it was not being considered part of the loop.
9344 * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
9346 2002-02-10 Karl Bongers <karl AT turbobit.com>
9349 Fixed up SDCDB debugger somewhat. Updated debugger/README
9350 with lots of comments and notes.
9352 * device/examples/test2.c:
9353 Fix bug, "red" variable not being initialized(compiler complained).
9355 * device/examples/Makefile, examples/test3.c:
9356 Add Makefile in device/examples folder, compiles test3.c
9357 for use as a multiple module SDCDB test case.
9359 * sim/ucsim/cmd.src/cmdset.cc:
9360 Took out debug printfs in ucsim "next" command.
9363 Karl and Johan start ucsim XA support. Most dissassembly working,
9364 about 75% emulation done(plenty of work remaining).
9366 * sim/ucsim/z80.src:
9367 Add Z80 support to ucsim, add test-ucz80 regression test,
9368 notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
9369 Notice z80 compiler fails on examples/test3.c/crc code.
9371 2002-01-30 Sandeep Dutta <sandeep AT ddi.com>
9373 * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
9374 Added support for --parms-in-bank1
9376 * src/ds390/peeph.def:
9377 added a few more peephole optimzations
9380 1) added __builtin_inp & __builtin_outp used to read in data of given length
9381 from a memory mapped port
9382 2) added __builtin_memcmp
9383 3) added __builtin_swapw swap bytes of a short
9385 * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
9386 1) handle multiple send & receives from register bank1
9387 2) ralloc can now allocate DPTR1 to some liveRanges
9389 * src/SDCCsymt.c, src/SDCCsymt.h:
9390 changes to handle multiple sends & receives
9393 added some pointer arithmetic optimization
9396 added some pointer arithmetic optimizations but not stable yet so not
9397 called from anywhere (will get this working shortly)
9399 * src/SDCCopt.c: fixed for multiple sends & receives
9402 1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
9403 2) preprocessing done AFTER port->finalizeoptions . This allows ports to
9404 set preprocessor defines (depending on options)
9406 * src/SDCCicode.c, src/SDCCicode.h:
9407 changes made to handle multiple sends & receives
9410 Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
9412 * src/SDCCcse.c, src/SDCCcse.h:
9413 added function findbackward def (to be used in upcoming optimization)
9415 * src/SDCCcflow.c, src/SDCCcflow.h:
9416 added function returnAtEnd - to determine if a basic block terminates with
9419 * src/SDCCast.c, src/SDCCast.h:
9420 added option parms-in-bank1
9422 * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
9423 * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
9424 * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
9425 adjusted for --parms-in-bank1 option
9427 * device/include/string.h:
9428 donot redefine "reentrant" keyword
9430 * device/include/ds80c390.h: Added some more SFRs
9432 2002-01-28 Bernhard Held <bernhard AT bernhardheld.de>
9434 * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
9436 2002-01-26 Bernhard Held <bernhard AT bernhardheld.de>
9438 * src/SDCCast.c (funcOfType): fix usage of double --float-reent
9440 2002-01-22 Bernhard Held <bernhard AT bernhardheld.de>
9442 * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
9444 2002-01-18 Paul Stoffregen <paul AT pjrc.com>
9446 * Added --xram-movc option
9448 2002-01-13 Bernhard Held <bernhard AT bernhardheld.de>
9450 * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
9452 2002-01-11 Johan Knol
9454 * Added math lib of Jesus Calvino-Fraga
9456 2002-01-08 Bernhard Held <bernhard AT bernhardheld.de>
9458 * src/SDCCmain.c (processFile): fix processing of ../../src.c
9459 * support/regression/Makefile: new target test-mcs51-stack-auto
9460 * support/regression/ports/mcs51-stack-auto/spec.mk: added
9462 2002-01-04 Bernhard Held <bernhard AT bernhardheld.de>
9464 * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
9466 2002-01-04 Bernhard Held <bernhard AT bernhardheld.de>
9468 * support/regression/ports/mcs51/support.c: correct setup of timer / UART
9470 2002-01-03 Bernhard Held <bernhard AT bernhardheld.de>
9472 * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
9474 * src/SDCCglue.h: add definition for printIvalChar()
9476 2002-01-02 Bernhard Held <bernhard AT bernhardheld.de>
9478 * src/SDCCast.c: fix #498138 by Johan
9480 * src/SDCCglue.c: fix #498138 by Johan
9482 2002-01-02 Bernhard Held <bernhard AT bernhardheld.de>
9484 * support/regression/Makefile: fix clean
9486 * support/regression/ports/ds390/support.c: fix transmission of last character
9488 2001-12-29 Sandeep Dutta <sandeep AT ddi.com>
9490 * /sdcc/src/ds390/gen.c:
9491 a) improved computing address of stack variable
9492 b) took out some #if 0 code
9493 c) improved parmBytes adjustment
9494 d) improved genPlusIncr & genMinusIncr
9495 e) genCmp could generate bad code (when left assigned to DPTR)
9496 f) Fixed bug in hasInc
9498 * /sdcc/src/ds390/ralloc.c:
9499 a) packRegsForSupport could mess up live information (Fixed)
9500 b) packRegsDPTRuse could be incorrect for left & right shift
9502 * /sdcc/src/mcs51/ralloc.c:
9503 packRegsForSupport could mess up the live information (Fixed)
9505 * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
9507 * /sdcc/src/SDCCast.c:
9508 can reverse a loop even if function call is present as long
9509 as the loop control variable is local & is not passed as parameter
9511 2001-12-24 Sandeep Dutta <sandeep AT ddi.com>
9513 * /sdcc/ChangeLog: *** empty log message ***
9515 * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
9516 More builtin function additions for TININative
9518 * /sdcc/src/ds390/ralloc.c:
9519 Had broken the regression testsuite
9521 * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
9523 * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
9524 Added funcattr hasStackParms will be set for reentrant functions when there
9525 are paramteres on the stack, this helps in minimizing frame pointer generation
9526 typeFromStr can handle function pointers now
9528 * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
9529 *** empty log message ***
9531 2001-12-24 Sandeep Dutta <sandeep AT ddi.com>
9533 * /src/ds390/gen.c, /src/ds390/main.c:
9534 More builtin function additions for TININative
9536 * /src/ds390/ralloc.c:
9537 Had broken the regression testsuite
9539 * /src/SDCCast.c: Fixed a bug in dumptree
9541 * /src/SDCCsymt.c, /src/SDCCsymt.h:
9542 Added funcattr hasStackParms will be set for reentrant functions when there
9543 are paramteres on the stack, this helps in minimizing frame pointer generation
9544 typeFromStr can handle function pointers now
9546 * /doc/builtins.txt, /doc/TININative.txt:
9547 *** empty log message ***
9550 2001-12-24 Sandeep Dutta <sandeep AT ddi.com>
9552 * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
9553 ALPHA version for -mTININative
9555 * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
9556 updated to reflect changes in the port structure
9559 added function do_assemble (similar to do_link) if non-null this function
9560 will be called to do assembly (-mTININative) requires a multi command
9562 added function genAssemblerEnd will be called to generate assembler Epilogue
9565 added _JavaNative to debug info printing
9567 * /src/SDCCmain.c: added option --tini-libid
9568 added port->do_assemble function (-mTININative) has a multi command assemble
9570 * /src/SDCCglue.c: Disabled "constExpr" check
9571 added port->genAssemblerEnd function
9573 * /src/SDCCglobl.h: Added option --tini-libid value
9576 tookout optimizeCompare from the header (has no external references)
9578 * /src/SDCCast.c: made one more function "static"
9580 2001-12-23 Michael Hope <michaelh AT juju.net.nz>
9582 * src/z80/mappings.i: Added z80asm support.
9584 * src/z80/main.c: Added z80asm support on --asm=z80asm
9586 * src/z80/gen.c: Fixed asm portability issues.
9588 * src/asm.c (tvsprintf): Removed old code, added 'N' for function name. For extern support.
9590 * src/SDCCglue.c (printExterns): Added global/extern split.
9592 2001-12-17 Bernhard Held <bernhard AT bernhardheld.de>
9594 * support/regression/Makefile: added test for mcs51 model large
9596 * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
9598 * support/regression/ports/gbz80/spec.mk: added -mgbz80
9600 2001-12-05 Michael Hope <michaelh AT juju.net.nz>
9602 * src/diff.1 (Index): Many, many optmisiations. Dhrystone up to 201.
9604 1904-01-06 Michael Hope <michaelh AT juju.net.nz>
9606 * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
9608 * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
9610 2001-12-02 Bernhard Held <bernhard AT bernhardheld.de>
9612 * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
9614 * support/regression/tests/simplefloat.c: Port to mcs51.
9616 2001-11-25 Michael Hope <michaelh AT juju.net.nz>
9617 * support/regression/tests/bug-485362.c: Added.
9619 * support/regression/tests/simplefloat.c (testDivNearOne): Added.
9621 * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
9623 * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
9625 * src/z80/gen.c (aopDump): Added a dump function.
9627 2001-11-25 Bernhard Held <bernhard AT bernhardheld.de>
9628 * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
9630 * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
9632 * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
9634 * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
9636 * sim/ucsim/s51.src/uc390cl.h: Work in progress.
9638 * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
9640 * support/regression/fwk/lib/testfwk.c: Run with tinibios.
9642 * support/regression/ports/mcs51/spec.mk: Fine tuninig.
9644 * support/regression/ports/ds390/support.c: Use tinibios.
9646 * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
9648 2001-11-23 Michael Hope <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
9650 * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
9651 (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
9653 * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
9655 * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
9657 2001-11-18 Michael Hope <michaelh AT juju.net.nz>
9659 * src/z80/gen.c (genCmp): Fixed compare on unsigned.
9661 * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
9662 (packRegsForIYUse): Created and optimised.
9664 2001-11-07 Michael Hope <michaelh AT juju.net.nz>
9666 * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
9667 2001-11-18 Bernhard Held <bernhard AT bernhardheld.de>
9669 * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
9671 * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
9673 * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
9675 2001-11-07 Bernhard Held <bernhard AT bernhardheld.de>
9677 * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
9679 * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
9681 2001-11-07 Bernhard Held <bernhard AT bernhardheld.de>
9683 * sdcc/sim/ucsim/globals.cc: New: IXRAM.
9685 * sdcc/sim/ucsim/stypes.h: New: IXRAM.
9687 * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
9689 2001-11-07 Michael Hope <michaelh AT juju.net.nz>
9691 * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
9692 (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
9693 (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
9695 * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
9697 * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
9698 (genNotFloat): Added.
9699 (genUminusFloat): Added.
9701 * device/lib/z80/Makefile: Added floating pt stubs.
9703 * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
9705 * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
9707 * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
9709 2001-11-07 Bernhard Held <bernhard AT bernhardheld.de>
9711 * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
9713 * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
9715 * sdcc/support/regression/Makefile: Add port ds390.
9717 * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
9719 * sdcc/support/regression/ports/z80/spec.mk: Minor change.
9721 * sdcc/support/regression/ports/ds390/spec.mk: Added.
9723 * sdcc/support/regression/ports/ds390/support.c: Added.
9725 * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
9727 * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
9729 * sdcc/support/regression/fwk/lib/timeout.c: Paste.
9731 2001-11-04 Michael Hope <michaelh AT juju.net.nz>
9733 * device/include/malloc.h: Added z80 and gbz80 support.
9735 * device/lib/gbz80/heap.s: Added.
9737 * device/lib/z80/heap.s: Added.
9739 * device/lib/malloc.c: Added z80 and gbz80 support.
9741 * support/regression/tests/malloc.c (testMalloc): Added.
9743 * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
9745 * support/regression/tests/bug-478094.c: Added.
9747 * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
9749 2001-11-04 Bernhard Held <bernhard AT bernhardheld.de>
9751 * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
9753 * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
9755 * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
9757 * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
9759 * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
9761 2001-11-04 Michael Hope <michaelh AT juju.net.nz>
9763 * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
9765 2001-11-03 Michael Hope <michaelh AT juju.net.nz>
9767 * support/regression/tests/bug-477927.c: Added.
9769 * src/z80/peeph.def: Added minor rules.
9771 * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
9773 * src/z80/peeph.def: Added jump optimisation modification.
9775 2001-11-01 Michael Hope <michaelh AT juju.net.nz>
9777 * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
9779 2001-10-30 Michael Hope <michaelh AT juju.net.nz>
9781 * support/regression/tests/funptrs.c: Added.
9783 2001-10-29 Michael Hope <michaelh AT juju.net.nz>
9785 * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
9787 2001-10-28 Michael Hope <michaelh AT juju.net.nz>
9789 * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
9791 * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
9793 * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
9794 (movLeft2ResultLong): Created.
9796 * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
9797 (joinPushes): Added. Joins two char pushes into a word push.
9799 2001-10-27 Michael Hope <michaelh AT juju.net.nz>
9801 * support/cpp2/Makefile.in (install): Added creation of dest dir.
9803 * support/makebin/Makefile (install): Added creation of dest dir.
9805 2001-10-24 Karl Bongers <karl AT turbobit.com>
9807 * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
9809 2001-10-21 Michael Hope <michaelh AT juju.net.nz>
9811 * src/z80/ralloc.c: Turned off faulty pack for one use.
9813 * src/z80/peeph-gbz80.def: Removed redundent restart options.
9815 * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
9817 2001-10-21 Bernhard Held <bernhard AT bernhardheld.de>
9819 * support/regression/Makefile: Improved clean
9821 * support/regression/ports/gbz80/spec.mk: Added clean
9823 * support/regression/ports/host/spec.mk: Added clean
9825 * support/regression/ports/z80/spec.mk: Added clean
9827 * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
9829 * support/regression/ports/mcs51/timeout.c: little improvements
9831 2001-10-17 Michael Hope <michaelh AT juju.net.nz>
9833 * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
9835 * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
9837 * support/regression/generate-cases.py: Fixed up to use function pts correctly.
9839 2001-10-16 Bernhard Held <bernhard AT bernhardheld.de>
9841 * support/regression/port/mcs51/spec.mk: add timeout for uCsim
9843 * support/regression/port/mcs51/timeout.c: add timeout for uCsim
9845 2001-10-13 Michael Hope <michaelh AT juju.net.nz>
9846 * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
9848 * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
9850 * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
9852 * src/mcs51/main.c (_linkCmd): Added bin path to command.
9854 * src/SDCCmain.c (initValues): Added support for when it it called just to link.
9856 * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
9858 * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
9860 * support/regression/tests/longor.c: Added.
9862 2001-10-11 Bernhard Held <bernhard AT bernhardheld.de>
9864 * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
9866 * as/mcs51/aslink.h: define PATH_MAX
9868 * as/mcs51/asm.h: define PATH_MAX
9870 * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
9872 * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
9874 * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
9876 * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
9878 * src/SDCCglobl.h: define PATH_MAX
9880 * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
9882 * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
9884 2001-10-11 Michael Hope <michaelh AT juju.net.nz>
9886 * src/z80/gen.c (gencjneshort): Fixed
9888 * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
9890 2001-10-09 Michael Hope <michaelh AT juju.net.nz>
9892 * support/regression/tests/bug-469671.c: Added.
9894 * src/z80/gen.c (shiftIntoPair): Fixed up warning.
9896 2001-10-08 Michael Hope <michaelh AT juju.net.nz>
9898 * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
9900 * src/z80/gen.c (genPlus): Fixed to work with extended stack. Also fixed genMinus, genCmp. genUMinus is still left.
9902 2001-10-08 Bernhar Held <bernhard AT bernhardheld.de>
9904 * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
9906 * src/device/lib/_mulint.c : removed hint: nooverlay bug
9908 * src/device/lib/_mullong.c : removed hint: nooverlay bug
9910 * src/device/lib/_divuint.c : removed hint: nooverlay bug
9912 * src/device/lib/_divulong.c: removed hint: nooverlay bug
9914 * src/device/lib/_moduint.c : removed hint: nooverlay bug
9916 * src/device/lib/_modulong.c: removed hint: nooverlay bug
9918 2001-10-07 Michael Hope <michaelh AT juju.net.nz>
9920 * 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.
9922 * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all. Fixes runtime segfault.
9924 * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
9926 2001-10-07 <johan AT FRIJA>
9928 * device/lib/gets.c (gets): fixed the return value.
9930 2001-10-06 Michael Hope <michaelh AT juju.net.nz>
9931 * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
9933 * 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.
9935 * 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.
9937 * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
9939 * src/pic/gen.c: Removed Safe_strdup.
9941 * configure.in: Added option to enable libgc support.
9943 * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
9944 (bitVectUnion): Optimised.
9945 (bitVectIntersect): Optimised.
9946 (bitVectBitsInCommon): Optimised.
9947 (bitVectCplAnd): Optimised.
9949 * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it. Sigh.
9951 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
9953 * src/SDCCmain.c: distinguish between assembler debug and plain options
9955 * src/avr/main.c: remove standard assembler options
9957 * src/ds390/main.c: remove standard assembler options
9959 * src/mcs51/main.c: remove standard assembler options
9961 * src/port.h: removed "PENDING" comment
9963 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
9965 * src/device/lib/_mulint.c : new, with assember functions
9967 * src/device/lib/_mullong.c : new, with assember functions
9969 * src/device/lib/_divuint.c : with assember functions
9971 * src/device/lib/_divsint.c : with assember functions
9973 * src/device/lib/_divulong.c: with assember functions
9975 * src/device/lib/_divslong.c: with assember functions
9977 * src/device/lib/_moduint.c : with assember functions
9979 * src/device/lib/_modsint.c : with assember functions
9981 * src/device/lib/_modulong.c: with assember functions
9983 * src/device/lib/_modslong.c: with assember functions
9985 * src/device/lib/libint.lib: replaced _muluint.c and _mulsint.c by _mulint.c
9987 * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
9989 * src/device/lib/Makefile.in: replaced _muluint.c and _mulsint.c by _mulint.c
9990 replaced _mululong.c and _mulslong.c by _mullong.c
9992 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
9994 * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
9996 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
9998 * src/SDCCglue.c: test, if win32api is available for MINGW
10000 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
10002 * src/SDCCsymt.c: no more _modifier in printTypeChain()
10003 * support/regression/tests/driverstruct.c: REENTRANT for mcs51
10004 * support/regression/ports/gbz80/spec.mk: removed GENERIC
10005 * support/regression/ports/host/spec.mk: removed GENERIC
10006 * support/regression/ports/mcs51/spec.mk: removed GENERIC
10007 * support/regression/ports/z80/spec.mk: removed GENERIC
10009 2001-10-01 Michael Hope <michaelh AT juju.net.nz>
10011 * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
10013 * support/regression/tests/bug-467035.c: Created.
10015 2001-10-01 <johan AT FRIJA>
10017 * src/SDCC.y: fixed bug #466586 part 1
10019 2001-10-01 Johan Knol <johan.knol AT iduna.nl>
10021 * SDCCicode.c: z80 has no generic pointers
10022 * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
10024 2001-09-30 Michael Hope <michaelh AT juju.net.nz>
10026 * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
10028 2001-09-29 Michael Hope <michaelh AT juju.net.nz>
10030 * Makefile (sdcc-libs): Added makebin to the list of standard targets.
10032 * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
10034 2001-09-25 Michael Hope <michaelh AT juju.net.nz>
10036 * configure.in: Fixed up so that ucsim is only configured once.
10038 * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
10040 * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
10041 (getPathDifference): As above.
10043 * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory. Fixed case where pre-processing only.
10045 * src/SDCCglue.c (tempfilename): Added function for pre-processor.
10047 2001-09-23 Michael Hope <michaelh AT juju.net.nz>
10048 * .version: Updated to 2.3.1
10050 * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
10051 Added copyright header.
10053 * src/SDCCmain.c: Shifted various functions into SDCCutil.c
10054 (assemble): Added support for macro based assembler commands.
10055 (linkEdit): Added support for macro based linker commands.
10056 (preProcess): Changed the pre-processor to use macros.
10057 (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
10058 (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
10060 * device/lib/z80/crt0.s: Added module name for debugging.
10062 2001-09-20 Michael Hope <michaelh AT juju.net.nz>
10064 * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
10066 * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
10068 * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
10070 * src/Makefile.in: Added SDCCmacro and SDCCutil
10072 2001-09-19 Michael Hope <michaelh AT juju.net.nz>
10074 * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
10076 2001-09-16 <johan AT FRIJA>
10078 * 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.
10080 2001-09-15 <johan AT FRIJA>
10082 * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
10083 * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
10085 2001-09-11 <johan AT FRIJA>
10087 * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
10089 2001-09-10 Michael Hope <michaelh AT juju.net.nz>
10091 * support/regression/tests/bug-460444.c: Added test case.
10093 * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
10094 (genCast): Added justification for all of the asserts.
10096 2001-09-10 Bernhard Held <bernhard AT bernhardheld.de>
10098 * support/regression/support.c: _xdata replaced by xdata
10100 * support/regression/spec.mk: removed _generic
10102 2001-09-09 Michael Hope <michaelh AT juju.net.nz>
10104 * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
10106 * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
10107 (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
10109 * src/z80/peeph.def: Added a rule to optimise shift then compare.
10111 * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
10113 * support/regression/tests/bug-460010.c: Added test case.
10115 * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
10117 2001-09-09 Bernhard Held <bernhard AT bernhardheld.de>
10119 * support/regression/Makefile: inter-port-clean adjusted for mcs51
10121 * support/regression/testfwk.c: removed workaround for bug #436344
10123 * support/regression/tests/bp.c: use less memory with mcs51
10125 * support/regression/tests/bug-441448.c: use less memory
10127 * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
10129 * support/regression/collate-results.py: typo
10131 2001-09-08 Michael Hope <michaelh AT juju.net.nz>
10133 * support/regression/tests/fetchoverlap.c: Added new test case.
10135 * support/regression/tests/bp.c: Added new test case.
10137 * support/regression/tests/bug-448984.c: Added new test case.
10139 * support/regression/tests/pow2shifts.c: Added new test case.
10141 * src/z80/gen.c: Turned off the noise it normally generates for the release.
10142 (genlshTwo): Fixed right shift for count > 8.
10144 * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
10146 2001-09-08 <johan AT FRIJA>
10148 * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
10150 2001-09-07 <johan AT FRIJA>
10152 * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
10154 * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
10156 2001-09-06 <johan AT FRIJA>
10158 * src/SDCC.y: this could be a fix for bug #458744 (1.37)
10159 * bernhard noted me at this: "() equals to (void)" (1.38)
10161 2001-09-05 <johan AT FRIJA>
10163 * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
10165 2001-09-04 <johan AT FRIJA>
10167 * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
10170 2001-09-04 Paul Stoffregen <paul AT pjrc.com>
10172 * pragma noinduction broke memcpy on mcs51 large model. Moved it inside z80 optimization
10174 2001-09-03 Michael Hope <michaelh AT juju.net.nz>
10176 * link/z80/aslink.h: Fixed path for PATH_MAX
10178 2001-09-02 Michael Hope <michaelh AT juju.net.nz>
10180 * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
10182 * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
10184 * support/regression/tests/uminus.c: Added a test for the unary minus operator.
10186 * 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.
10188 2001-09-01 Michael Hope <michaelh AT juju.net.nz>
10190 * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
10191 (genCmp): Fixed up genCmp for the GB with longs.
10193 * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
10195 * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
10197 * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
10199 * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
10201 2001-08-30 Paul Stoffregen <paul AT pjrc.com>
10203 * added peepholes 223 to 231 to mcs51 port. These improve code when using large model.
10205 2001-08-30 Michael Hope <michaelh AT juju.net.nz>
10207 * 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.
10209 * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
10211 2001-08-29 Michael Hope <michaelh AT juju.net.nz>
10213 * link/z80/aslink.h: Fixed long file name support. Is now based off PATH_MAX instead of a constant.
10215 * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
10217 2001-08-30 Bernhard Held <bernhard AT bernhardheld.de>
10219 * sim/ucsim/configure: little improvement of Cygwin-detection
10220 * sim/ucsim/configure.in: little improvement of Cygwin-detection
10221 * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
10222 * support/regression/tests/bug-221100.c: small changes for mcs51
10223 * support/regression/tests/bug-221168.c: small changes for mcs51
10224 * support/regression/tests/bug-227710.c: small changes for mcs51
10225 * support/regression/tests/staticinit.c: small changes for mcs51
10226 * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
10227 * as/mcs51/lklex.c: accept everything as symbol name in rel-files, bug fix ID 452601
10228 * as/mcs51/lksym.c: accept everything as symbol name in rel-files, bug fix ID 452601