Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!wuarchive!gem.mps.ohio-state.edu!ginosko!uunet!portal!cup.portal.com!Don_A_Corbitt
From: Don_A_Corbitt@cup.portal.com
Newsgroups: comp.std.c
Subject: Re: volatile required?
Message-ID: <22715@cup.portal.com>
Date: 2 Oct 89 03:48:48 GMT
References: <712@Aragorn.dde.dk> <16785@watdragon.waterloo.edu>
Organization: The Portal System (TM)
Lines: 20

In article  Anthony Scian afscian@violet.uwaterloo.ca wrote
[rest of article deleted]
>>Is it acceptable that this program prints 3 instead of 4? 
>NO. This is a convenient type of oversight that allows so called
>"optimizing compilers" like Turbo C and Microsoft C to squeeze
>out extra performance from benchmarks. Too bad if production code
>doesn't run with the optimizer turned on. True optimizing
>compilers (WATCOM C,GNU CC) don't resort to "tricks" like this.
>--
>Anthony
>//// Anthony Scian afscian@violet.uwaterloo.ca afscian@violet.waterloo.edu ///
/

I have heard that MSC 5.0 had optimizer problems, and most are fixed in 5.1.
Of more importance, Turbo C doesn't have an 'aggressive' optimizer, and is
not guilty of the sin mentioned here.  It generates fairly good code anyway.

Don_A_Corbitt@cup.portal.com     Not a spokesperson for CrystalGraphics, Inc.
"Mail flames, post apologies"    "Support the three-line signature"
Contrary to popular belief