Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!zaphod.mps.ohio-state.edu!mips!cs.uoregon.edu!ogicse!intelhf!ichips!iwarp.intel.com!inews!bishop!bhoughto From: bhoughto@bishop.intel.com (Blair P. Houghton) Newsgroups: comp.lang.c Subject: Re: low level optimization Message-ID: <3906@inews.intel.com> Date: 19 Apr 91 04:21:54 GMT References: <21846@lanl.gov> <1991Apr18.233807.19552@zoo.toronto.edu> <21868@lanl.gov> Sender: news@inews.intel.com Organization: Intel Corp, Chandler, AZ Lines: 46 In article <21868@lanl.gov> jlg@cochiti.lanl.gov (Jim Giles) writes: >I don't understand why you continue to hang on like grim death >to the fiction that dependent compilation satisfies the requirements >of the standard. I haven't seen anyone state such a thing. What I have seen is plenty of statements that equate to the standard's requirement that a conforming program be translatable by a conforming implementation into a form that can be used to produce the output associated with a given input. It's just tough luck if this prevents you from expecting a certain optimization to be applied when you compile in strictly conforming mode. This has absolutely no effect on the form of the code in the source files. Exactly the opposite. It provides for the desired state where a program can be translated on any number of machines without alteration of the source files. If, however, it's provided you with extensions that allow you to produce odd effects, and you use them, then you are exceeding the bounds of the standard's influence, and whatever is required by the extension you must obey or it just won't work, apparently. This still has no effect on the source code. You haven't stated that special syntax must be provided in the source files in order to use this optimization you so desire, so there's no reason that my strictly conforming compiler that doesn't optimize in this way and your specialized compiler that does optimize in this way shouldn't be able to produce the same output. You're so hyped up about the fact that separate compilation prevents use of this optimization, but you haven't been so vocal about the case where you deliberately alias one of your arrays, which also blows your optimization. If you want to go out of your way, you have to go out of your way. --Blair "If the implementation also has knobby tires, a half-fairing, and a bottle of diethyl ether, then it's also an offroad crotch-rocket, but it better do the -ansi thing for `main(){printf("Hello, world.\n");}'"