🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #588

Re: Volatile (was Re: observability)

#588
From: Bill Poser
Date: Thu, 14 Sep 1989 03:48
15 lines
1283 bytes
In article <7330001@hpfcso.HP.COM> mike@hpfcso.HP.COM (Mike McNelly) writes:
>
>Ah, but any compiler that has optimization capabilities that would allow
>it to nullify a useless program invariably does not do such optimization
>unless you ask for it with flags such as -O. My guess is that you don't
>optimize such a program during development, only after development is
>nearly complete.

True, but I often just stick the optimization flag in the Makefile
and don't bother to turn it off during testing. Anyhow, the question I
answered was why one might want to write a "useless" code fragment.
I agree that a compiler that optimizes such a fragment into nothingness
is not a problem if one can disable the optimization.

							Bill
Technical Details
Message-ID: <10370@csli.Stanford.EDU>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!agate!shelby!csli!poser
References: <28993@news.Think.COM> <7330001@hpfcso.HP.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!agate!shelby!csli!poser
From: poser@csli.Stanford.EDU (Bill Poser)
Newsgroups: comp.std.c
Subject: Re: Volatile (was Re: observability)
Message-ID: <10370@csli.Stanford.EDU>
Date: 14 Sep 89 03:48:41 GMT
References: <28993@news.Think.COM> <7330001@hpfcso.HP.COM>
Sender: poser@csli.Stanford.EDU (Bill Poser)
Reply-To: poser@csli.stanford.edu (Bill Poser)
Organization: Center for the Study of Language and Information, Stanford U.
Lines: 15