ache@hq.demos.su (Andrew A. Chernov) (02/24/91)
Hi, folks! I've found Microsoft C compiler bug in computation offsets in structures on my XENIX/386 v2.3.3: if any field exceed 64K, offsets of next fields are WRONG. And so, Microsoft programmers can't write their products without DIRTY bugs. Use your Microsoft C CAREFULLY! May be, it can damage all (and you brains also) in one day! I've check this problem with 'gcc', and get CORRECT result. NOTE: if you have 286 computer, don't worry about this: you can't make object bigger than 64K. This is my test to detect error in your compiler: ------------------------------ CUT HERE ------------------------------- #define SIZE_OVER_64K 100000 struct { char a[SIZE_OVER_64K]; char junk[100]; int b; } c; main() { int i; c.b = 1; for(i = 0; i < SIZE_OVER_64K; i++) if(c.a[i] != 0) { printf("THIS 32-bit C COMPILER IS BUGGY !\n"); exit(1); } printf("NO ERRORS FOUND.\n"); exit(0); } ------------------------------ CUT HERE ------------------------------- -- In-Real-Life: Andrew A. Chernov | Domain: ache@hq.demos.su, Zodiac-Sign: Virgo | ache%hq.demos.su@relay.eu.net Organization: DEMOS Coop., | Phone: +7 095 2312129 Moscow, Russia | Fax: +7 095 2335016
sef@sco.COM (Sean Eric Fagan) (02/24/91)
In article <1991Feb23.175948.842@hq.demos.su> ache@hq.demos.su (Andrew A. Chernov) writes: >Hi, folks! >I've found Microsoft C compiler bug in computation offsets in >structures on my XENIX/386 v2.3.3: That is the OS version. You are using the 2.3.0 DS, I suspect. I suspect this because I fixed this bug for teh 2.3.1 (and unix) devsys. If you upgrade, you get a better compiler, including this bug fix. (The 2.3.0 msc compiler is 4.5ish; the 2.3.1 and 3.2 and later compilers are 5.1, the same version as the '286 compiler.) Before you start flaming a product, *any product*, try to see if there is a cheap/free upgrade to a version that does not have the bug. The 2.3.1 ds upgrade qualifies as that. Note that, for the 2.3.0 ds, there is an SLS (lng055, I believe) which consists of little else besides the compiler, since the 4.5ish compiler received so many complaints. And, yes, this was written as an SCO employee. That's why the From: and Reply-to: lines say what they say. -- Sean Eric Fagan | "I made the universe, but please don't blame me for it; sef@kithrup.COM | I had a bellyache at the time." -----------------+ -- The Turtle (Stephen King, _It_) Any opinions expressed are my own, and generally unpopular with others.
ronald@robobar.co.uk (Ronald S H Khoo) (02/25/91)
sef@sco.COM (Sean Eric Fagan) writes: > Note that, > for the 2.3.0 ds, there is an SLS (lng055, I believe) which > consists of little else besides the compiler, since the 4.5ish > compiler received so many complaints. I think Sean's thinking of lng085, of which: /* As quoted from scolon!/usr/spool/uucppublic/SLS/info * New on 9/28/90: * * lng085: No longer available, replaced by lng244. * end of quote from scolon!/usr/spool/uucppublic/SLS/info */ Note that lng244 is relative to 2.3.1 DS, so apparently there is no longer a free upgrade for our friend in the Soviet Union. Still, he's got GCC so what does it matter? :-) I *can* independently confirm that lng085's compiler does not have the bug, whereas 4.85's compiler does. I'm also just about to wipe most of these compiler passes off my disc (ENOSPC), so 'scuse me... -- Ronald Khoo <ronald@robobar.co.uk> +44 81 991 1142 (O) +44 71 229 7741 (H)
rosso@sco.COM (Ross Oliver) (03/01/91)
In article <1991Feb25.072926.12537@robobar.co.uk> ronald@robobar.co.uk (Ronald S H Khoo) writes: |sef@sco.COM (Sean Eric Fagan) writes: |> Note that, |> for the 2.3.0 ds, there is an SLS (lng055, I believe) which |> consists of little else besides the compiler, since the 4.5ish |> compiler received so many complaints. | |I think Sean's thinking of lng085, of which: | |/* As quoted from scolon!/usr/spool/uucppublic/SLS/info | * New on 9/28/90: | * | * lng085: No longer available, replaced by lng244. | * end of quote from scolon!/usr/spool/uucppublic/SLS/info */ | |Note that lng244 is relative to 2.3.1 DS, so apparently there is no |longer a free upgrade for our friend in the Soviet Union. A no-charge update from 2.3.0 to 2.3.1 for the Development System is available. It doesn't have an "official" name (i.e. Update ZZ), but the part numbers are 015-200-123 for 3.5-inch disks, and 015-700-123 for 5.25-inch disks. Send your shipping address and current DS serial number to sco!support if you need it. Ross Oliver Technical Support The Santa Cruz Operation, Inc.