Volatile is Necessary

Michael Meissner meissner at xyzzy.UUCP
Sun Apr 10 02:57:35 AEST 1988


In article <140 at polygen.UUCP> pablo at polygen.uucp (Pablo Halpern) writes:
| Not true.  Volatile was invented to solve some of the problems associated
| with multiprocessing or multitasking.  ...

Ughhh, let me throw some facts on this issue.  Volatile was NOT
originally added for shared memory multiprocessing systems.  Around the
ANSI X3J11 meeting in Concord or the meeting before that (around 3-4
years ago), const had been put in from the C++ implementation.  At that
time, it was felt that about half of the C programmers in the world were
writing C for the bare iron, ie OS developers, and device controllers
(which some in the committee calls toasters in a pejoritive sense), and
the other half were writing on UNIX.  It was for the first set of users
that volatile was invented, since we had many people who for example
wanted to do something silly like run highly optimizing compilers on
their operating system or product without breaking it (once they
identified the critical places).  If you look at the current C
programmers, I would suspect the bare iron people are considerably in
the minority, and that MSDOS C programmers have surpased the UNIX C
programmers.
-- 
Michael Meissner, Data General.		Uucp: ...!mcnc!rti!xyzzy!meissner
					Arpa/Csnet:  meissner at dg-rtp.DG.COM



More information about the Comp.lang.c mailing list