Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!cornell!batcomputer!itsgw!steinmetz!uunet!auspex!guy From: guy@auspex.UUCP (Guy Harris) Newsgroups: comp.lang.c Subject: Re: Re: Register unions Message-ID: <333@auspex.UUCP> Date: 27 Oct 88 23:52:21 GMT References: <983@l.cc.purdue.edu> <10130003@hpisod1.HP.COM> Reply-To: guy@auspex.UUCP (Guy Harris) Organization: Auspex Systems, Santa Clara Lines: 15 >Even if the hardware could not support a register union of incompatible >data types, the information would be valuable to an optimizer. >"Register," in addition to expressing a storage preference, informs the >compiler that the variable is non-addressable, and that the compiler >needn't worry about the contents changing. Well, optimizers of that level of sophistication often completely ignore "register" declarations and decide for themselves what should go into registers.... (Wasn't there some other keyword people were talking about at one point for saying that there wouldn't be any aliases for some location? :-) :-) :-) :-) :-) :-) :-) :-) :-)) The compiler can generally figure out for itself whether you're taking the address of some local variable or not; it tends not to need the assistance of a "register" declaration.