From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111c93,100c510dac09e617 X-Google-Attributes: gid111c93,public From: "H.W. Stockman" Subject: Re: MFlops Comparison using g77 (bad news) - bench.tgz (0/1) Date: 1997/09/26 Message-ID: <342BCE8F.6559@swcp.com>#1/1 X-Deja-AN: 275757313 References: <6060pv$kn6@news.cis.okstate.edu> <6078ji$5j0@news2.zippo.com> Organization: Lentil Sorbet, Inc. Reply-To: hwstock@swcp.com Newsgroups: comp.os.linux.alpha Greg Lindahl wrote: > > jwest@jwest.ecen.okstate.edu (Jim West) writes: > > > I'm wondering if an optimizing compiler sould pick this up even without the > > explicit definition of nx_r. Can anyone explain why it wouldn't? > > aliasing? > Likely. Some compilers will do a global aliasing check, which is fairly time-consuming -- it helps to have all the source in one file. Most (I've used) make conservative aliasing assumptions, on a function-by- function basis. Some compilers allow "no alias" pragmas to be placed around critical functions, but this practice is generally regarded as "cheating" for benchmarks. Others have a switch for global assumption of no aliasing -- a rather dangerous option. FORTRAN aficionados like to tout lack of aliasing as a great advantage. But I ask naively: what keeps a FORTRAN function declared foo(xarray, yarray) from being called foo(xarray, xarray)?