> For some reason the "real" time column is slower. e.g. > Array access: total user+cpu time: 17.22 ---> 16.95 > real time: 17.63 ---> 17.97 > > There must be something funny going on - the program does the tiniest amount > of I/O so it's hard to see what it's blocking on. I think it may be because > of the following warning which is generated twice for each test: > > /usr/local/lib/ruby/site_ruby/1.8/benchmark.rb:435: warning: obsolete method Time::times; use Process::times That was my broken ruby16->18 shim installation, which I've now fixed. But I also realised that I was running under X, with KDE and Mozilla eating up chunks of memory, and hence likely to mess things up especially with regards to garbage collection. So, exiting out of all that, and running from a text console, I get the following results: [1.6.8] user system total real Ackermann function: 2.523438 0.000000 2.523438 ( 2.519697) Array access: 17.882812 0.015625 17.898438 ( 17.928351) Fibonacci numbers: 16.078125 0.007812 16.085938 ( 16.114064) Hash access I: 15.031250 0.007812 15.039062 ( 15.086221) Hash access II: 20.273438 0.046875 20.320312 ( 20.425834) Lists: 57.328125 0.007812 57.335938 ( 57.639749) Nested loop: 18.125000 0.000000 18.125000 ( 18.162831) Sieve of Eratosthenes: 27.914062 0.007812 27.921875 ( 27.968728) Word Frequency: 5.820312 0.023438 5.843750 ( 5.856217) [1.8.0p2] user system total real Ackermann function: 2.609375 0.000000 2.609375 ( 2.611862) Array access: 16.226562 0.000000 16.226562 ( 16.235060) Fibonacci numbers: 16.132812 0.000000 16.132812 ( 16.153930) Hash access I: 17.500000 0.000000 17.500000 ( 17.587397) Hash access II: 19.101562 0.031250 19.132812 ( 19.182812) Lists: 4.281250 0.015625 4.296875 ( 4.535421) Nested loop: 17.906250 0.000000 17.906250 ( 17.917728) Sieve of Eratosthenes: 23.765625 0.023438 23.789062 ( 23.820149) Word Frequency: 6.742188 0.007812 6.750000 ( 6.861685) Now the "total CPU" and "real" (elapsed) times are very similar, which is what I'd expect. I still see 1.8 faster in 5 out of 9 tests, so on this evidence I'm not hugely concerned about moving to 1.8 I compiled both 1.6.8 and 1.8.0p2 from source, on the same machine, with the same version of GCC (2.95.4) and libraries. This is worth thinking about - you don't want to end up comparing the optimisation performance of two different C compilers, rather than the code itself! Regards, Brian.