Path: utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!rpi!uupsi!sunic!nuug!ulrik!ulrik!oles From: oles@kelvin.uio.no (Ole Swang) Newsgroups: comp.benchmarks Subject: Re: more bc babble Message-ID: Date: 13 Dec 90 20:33:01 GMT References: <1990Dec11.163826.5439@eagle.lerc.nasa.gov> Sender: news@ulrik.uio.no (USENET News System) Organization: University of Oslo, Norway Lines: 45 In-Reply-To: xxdon@monet.lerc.nasa.gov's message of 11 Dec 90 16:38:26 GMT Another easy-to-memorize benchmark is the computation of the sum of the first 10 million terms in the harmonic series. This is a FORTRAN version, it should not be too hard to translate even without f2c :-) PROGRAM RR DOUBLE PRECISION R R=0.0 DO 10 I=1,10000000 R=R+1/DBLE(I) 10 CONTINUE WRITE(*,*)R,I END This one is obviously testing floating-point perfomance only. The emphasis on divisions might give biased results. It vectorizes fully on the vectorizing compilers I've tested it on (Cray and Convex). It has the advantage over the bc benchmark that it's the same code every time. Some results (in seconds): Cray X/MP 216 0.29 * Convex C 120 8.7 DECstation 5000/200 10.5 DECsystem 5400 13.1 VAX 6330/VMS5.3 FPA 41.9 VAX 8650/VMS5.3 FPA 55.3 VAX 8600/VMS5.2 FPA 77.1 Sun 3/60 (m68881) 105.6 * The code was modified to single presicion for the Cray, as this yields the wanted 64-bits accuracy. Comments and suggestions are encouraged. ------------------------------------------------------------------------- Ole Swang, assistant professor, Dept. of Chemistry, U. of Oslo, Norway ------------------------------------------------------------------------- -- ----------------------------------------------------------------------- Ole Swang oles@kelvin.uio.no -----------------------------------------------------------------------