From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,b1a14dd1b577e76c X-Google-Attributes: gid1164f8,public X-Google-Thread: 102b75,b1a14dd1b577e76c X-Google-Attributes: gid102b75,public From: patchkov@acs1.acs.ucalgary.ca (Serguei Patchkovskii) Subject: Re: 21364 presentation Date: 1998/10/18 Message-ID: <70dol9$1770@ds2.acs.ucalgary.ca>#1/1 X-Deja-AN: 402603874 References: <70btkg$8s5$1@mark.ucdavis.edu> <908732006.6364.0.nnrp-10.9e981e55@news.demon.co.uk> Followup-To: comp.sys.dec,comp.arch Organization: The University of Calgary Newsgroups: comp.sys.dec,comp.arch P Dickerson (peter@localhost) wrote: : Slide 4 compares the 7 cycles of Merced code with 6 cycles of Alpha. However : the Alpha code does not appear to have the correct exception semantics. If : any other the arrays are invalid the Alpha throws an exception while Merced : only throws if the array should of be accessed. This was the point of the : Merced example. Of course the example is not a good one since the arrays are : almost certainly local and the compiler can determine that exceptions won't : happen. Well, the fragment of code given on slide 4 apparently comes from the 8-queens problem (or at least the original Intel's example had). Using 8-queens as a benchmark had always sounded a bit silly to me: a properly coded program solving it does NOT need any like extraordinary number of memory accesses. In fact, the inner loop in the bit-array implementation is simply a register shift-and-test (or find-first-bit if your compiler is smart enough to figure that out), and can run as fast as the isolated CPU core will let it. With a pretty crude C implementation on a 500MHz 21164, it takes: Nqueens Nsolutions Seconds 8 92 <0.01 9 352 <0.01 10 724 <0.01 11 2680 <0.03 12 14200 0.16 13 73712 0.88 14 365596 5.26 15 2279184 33.51 16 14772512 230.11 17 95815104 1641.74 ... and so on. (It is quite possible to go much faster with a bit of a hand-tuned assembly code). I do not think you can beat these timings using the naive implementation of slide 4 on however fast that 21364 (or first IA-64 chip for that matter) is going to be. So I guess the only *real* point it makes is that an incompetent programmer can write a molasses-slow program on any hardware regardless of how fast it is. Cheers, /Serge.P