Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!caen!spool.mu.edu!uwm.edu!linac!att!ucbvax!WATSON.IBM.COM!jbs From: jbs@WATSON.IBM.COM Newsgroups: comp.arch Subject: Re: IEEE arithmetic (Goldberg paper) Message-ID: <9106210542.AA21933@ucbvax.Berkeley.EDU> Date: 21 Jun 91 04:53:48 GMT Sender: daemon@ucbvax.BERKELEY.EDU Lines: 32 I said: > I checked the behavior with the IBM VS Fortran and Xlf compi- >lers. In both cases the behavior was not changed by optimization. The >behavior differs between the two compilers but that is a different is- >sue. So this example will not convince me that I'm wrong. (Actually >I later softened my original statement to say it is undesirable for >optimization to affect a program's behavior.) (My original statement was a compiler which compiles a legal program so that it behaves differently when compiled with optimization is "broken".) Jon Krueger selectively quoted this as: >I checked the behavior with the IBM VS >Fortran and Xlf compilers. In both cases the behavior was not changed >by optimization ... So this example will not convince me that I'm wrong. and commented: :I see. Therefore no standard FORTRAN compiler would be permitted :to do any differently, right? These compilers define what is and :is not a legal optimization, is that your assertion? I have the following comments: 1. This is not my position as I believe the final sentence in my post (which you tendentiously failed to quote) makes clear. Do you disagree that it is undesirable for optimization to affect a program's behavior? 2. I believe a compiler can obey the Fortran standard and still be properly called broken. For example it can take 100 hours to compile a trivial program. 3. The person who posted the code example didn't say what the exam- ple was supposed to show. If it was supposed to show any compiler would produce code that behaved differently when compiling with optimization then it is incorrect. James B. Shearer