LOG (3214B)
1 From lcc 4.0 to 4.1: 2 3 Changes: 4 5 See doc/4.html for changes in the code-generation interface. 6 7 Warns about constants that are too large, eg, short x = 70000; 8 9 Warns about expressions that have no effect. 10 11 Unsigned shorts are now used for wide-character constants, and 12 wchar_t is a typedef for unsigned short. 13 14 More assertions in gen.c to confirm that the register allocator is 15 configured correctly; ie, that the various masks, wildcards, 16 clobbers, and targets are internally consistent. Full checking 17 appears impractical, but there's still more than than there was 18 before. 19 20 On the SPARC, lcc now emits .type and .size directives 21 unconditionally. 22 23 On the x86, constants are now emitted into the text segment. 24 25 If the environment variable "LCCDIR" is defined, it gives the directory 26 that contains the preprocessor, the compiler proper, and the 27 lcc-specific libraries. 28 29 Under Windows, lcc searches the directories named in the environment 30 variable "include" for header files. 31 32 Errors fixed: 33 34 Erroneously complained about unknown sizes for some const fields, eg, 35 typedef struct foo ref; struct foo { const ref *q; int a; }; 36 f(ref *p, int i) { return p->q[i].a; } 37 38 -A -A erroneously complained about static main's that didn't conform 39 to the ANSI-mandated "int main(void)" or "int main(int, char **)". 40 41 Silently generated incorrect code for a structure copy with a 42 post-incremented target, eg, 43 struct { int x; } data = {1}, copy[2], *q = copy; 44 main() { *q++ = data; } 45 46 Generated incorrect values in some expressions with constant pointers. 47 48 Silently truncated string literals longer than 4095 characters. 49 50 Failed to emit debugging information for uninitialized globals. 51 52 Failed to diagnose missing sizes in some multi-dimensioned array 53 declarators, eg, extern int x[][10]; int x[5][]; 54 55 Silently emitted incorrect sizes and initalizations for some 56 incomplete multi-dimensioned arrays involving pointers and whose size 57 is determined by the number of initializers. 58 59 Set only the x.name field for some back-end symbols (eg, wildcards), 60 and the uninitialized name field crashed some debugging output. 61 62 uses() failed to check the register *set* as well as the register 63 mask. There's no known bug demo, but a wildcard set might be 64 contrived that would need the test. 65 66 Crashed with -b on some conditional expressions involving calls, eg, 67 int p; void g(void) { p ? f() : 1; } 68 69 On the MIPS, sometimes generated an incorrect frame size and thus a 70 crash when floating-point registers were saved. 71 72 On the SPARC, erroneously reused a register variable as a temporary 73 when the variable is compiler-generated. 74 75 On the SPARC with -b, emitted incorrect code for returning structs. 76 77 On the x86, conversion from float to int rounded instead of truncated 78 with the default floating-point mode. 79 80 On the x86, eliminate rtargets for kids after the first (see p. 419). 81 82 On the x86, substitute reg for freg, in order to use the common reg 83 rules. Needed only for debugging output, since we're not using any 84 float regs as regs at this time. 85 86 On the x86, "double f(); main(){f();}" wasn't popping the FP register stack. 87 88 On the x86, ECX was saved by the callee, when it should have been 89 saved by the caller. 90 91 $Id: LOG 145 2001-10-17 21:53:10Z timo $