This is the bug fix list, please check it before posting a bug report in order to reduce duplication. The list will be sorted by greatest severity and then in order of date reported. LEVEL is the severity of the error from the following list 4 - compiler error - failure to parse C language 3 - incorrect code is generated 2 - generated code could be improved/optimized 1 - cosmetic improvements NEXT ID = 65 ID LEVEL DESCRIPTION -------- LIVE BUGS -------- 61 4 if the first of two arguments to a function call contains an expression with an undefined symbol the following argument (a simple variable) is the one declared as undefined. 54 4 the compiler does not correctly pass instances of structures to functions, it seems that was never coded in. Passing a structure rather than a pointer to it is a dumb idea anyway. 51 4 prototype checking for too few arguments is non-existant 38 4 the compiler forgets to generate a label for a static function that is consistent with the label it uses when the address of the function is stored in a function pointer. 37 4 the compiler was never coded to initialize structures local to a function. An example statement would be; struct st = {3, 4, DOG}; 64 3 printf does not handle floats 62 3 scanf does not work at all for reasons I don't understand and can't determine without a better debugging system. 60 3 the put_asc_l family of functions in C_lib are not implemented thus attempts to print longs will not happen. 56 2 a "register used" tracking peep-hole optimization could markedly improve code generation in cases such as * if (*chr_ptr == 's') { ldx _chr_ptr ldab 0,x cmpb #'s' bne L4 * ... * } else if (*chr_ptr == 't') { L4 ldx _chr_ptr ldab 0,x cmpb #'t' bne L5 * ... * } In the second clause both the ldx and ldab could be removed, This is a tricky optimization and will be left undone. 44 2 change the linker to allow replacing functions 20 2 add an option/keyword/pragma to allow placement of variables in zero page memory 21 1 allow C++ style comments 14 1 eliminate the lc_auto label used for local var access (inc 4-L1,Y) -------- NEWLY DEAD BUGS -------- -------- ROTTING BUGS -------- 49 4 ellipsis handling for prototype checking is incorrect 50 4 prototype checking for too many arguments is non-existant 59 3 bugs in conversions of larger types to smaller types 58 3 comparisons generating incorrect code 57 3 casts of constants are being ignored 53 3 missing ldx 0,x in direct version of switch statement 52 3 various fixes to stdio routines 45 3 the following statement breaks the compiler repeatedly file_ptr->_buff[file_ptr->_wr_cnt++] = *((char *)file_ptr->_io_ext->_data)++; 43 3 two errors in the long branch optimizer could (although rarely) cause a short branch range to be exceeded. 39 3 size of return values from functions is not being used. The default size of int is being used. 36 3 initialization of structures, longs and pointers are not correct 35 3 return of address of variable produces a 68000 addr mode 29 3 post fix auto increment of longs where result is used in further expressions is not done 26 3 incorrect handling of char cast to int as function parameter 22 3 bugs in string usage 17 3 multiply and divide library functions need to be coded 16 3 all comparisons (if, while etc.) will not work with longs this is due to missing 4 byte compare 15 3 one form of switch statement will not work with longs this is due to missing 4 byte compare 12 3 various errors in local vars, using local vars, function parameters -Stan 13 3 returning a constant from a function resulted in a 68000 instr -Stan 6 3 a short branch is always used even when a long one is req'd -Stan 7 3 the switch statement generates a sequence that crashes SAsm -Stan 5 3 increment decrement is not correct with longs -Stan 2 3 incorrect code in ?: syntax -Stan 31 2 a hangover from the 68000 version is forcing structures to an even byte size 32 2 the assembler (SAsm) must be modified to handle zero page XREF's (XREF.z L99999999) and segments 24 2 Modify linker to handle IDATA 28 2 auto increment by sizes other than char doesn't advance efficiently for post fix forms 25 2 write c.o startup program 55 2 optimize std x/ldd x and stab x/ldab x 46 2 optimize ldd followed by cpd #0 41 2 optimize the &= and |= operators to bit ops where possible and add a compiler option to generate 6301 bit ops instead or to not generate bit ops if 6301 bit ops prove insufficient. CANCEL!! 6301 can never be used effectively with C (no Y reg) 42 2 optimize the +, -, += and -= operators to do a faster version when the operand is a simple variable. 48 2 use of float variables should now be correct. There is also a new library (math.lib) containing arithmatic and trigonometric functions. 47 2 three HC11 specific builtin functions must be added; enable_intr() = CLI, disable_intr() = SEI and wait_for_intr() = WAI 34 2 add peephole optimization cmpb #0 ==> tstb and if it follows a ldab remove it completely 19 2 add an option to generate PROMable programs ( the -P option generates initialized data into an IDATA segment when the linker sees this, it creates a BSS the size of the segment and make this segment into code. Your program must call _init_data to cause the code image to be copied to the BSS. This will first require a rev of the linker.) 1 2 allow for 8 bit pushes to stack instead of "pshd" in binary ops with 8 bit operands -Stan 10 2 create a static compiler option that forces local vars to static -Stan ( this option is -w ) 9 2 optimize incdec to use inx/dex for 2 byte operands -Stan (this was not done, the existing method is one byte longer but, normally, 4 cycles faster.) 4 2 automatic promotion of numerics to any size (with cbl cwl) does not happen -Stan 8 2 the switch statement needs optimization 3 2 multiply of char * char to char forces to int size -Stan 63 1 the quiet option now defaults to on 23 1 compiler always reports same version at startup 27 1 write printf,scanf routines 40 1 due to the importance of prototypes for return values from functions it is neccesary to add a warning whenever a function is used before its prototype is known. 33 1 default path for includes should be ADev11:include 11 1 remove muldiv32 option