Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mandrill!gatech!ncar!oddjob!uwvax!vanvleck!uwmcsd1!ig!agate!pasteur!ic.Berkeley.EDU!faustus
From: faustus@ic.Berkeley.EDU (Wayne A. Christopher)
Newsgroups: comp.lang.c
Subject: Re: volatile: a summary
Message-ID: <4002@pasteur.Berkeley.Edu>
Date: 20 Jun 88 23:15:27 GMT
References: <761@garth.UUCP> <11837@mimsy.UUCP> <3811@pasteur.Berkeley.Edu> <580@wsccs.UUCP> <751@garth.UUCP> <12020@mimsy.UUCP>
Sender: news@pasteur.Berkeley.Edu
Lines: 15

Here is a (stupid) program that proves you cannot always infer volatility:

main() {
	int *device_address, i;

	printf("Please input \"0x4f0\", the address of the t-o-d register\n");

	scanf("%x", (int *) &i);
	device_address = (int *) i;

	while (*device_address < 43200)	/* noon */
		;
}

	Wayne