Version française
Home     About     Download     Resources     Contact us    
Browse thread
32- and 64-bit performance
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Robert Roessler <roessler@r...>
Subject: Re: [Caml-list] 32- and 64-bit performance
Alex Baretta wrote:

> Jon Harrop wrote:
> 
>> I just bought a new Athlon 64 laptop and installed 32- and 64-bit Debian.
>> Here are some timings, showing the performance change when moving from 
>> 32-
>> to 64-bit using ocamlopt (3.08.2) and g++ (3.4.4):
> 
> ...
> 
>>
>> So ocamlopt does seem to generate significantly better code in these 
>> examples, particularly when they are floating point intensive. Also, 
>> only one test is slower in 64-bit, due to its heavy use of trees.
>>
> 
> Why do you suppose is there *any* benchmark faster in 32 bit mode than 
> in 64 bit mode on the Athlon64? Since the AMD64 architecture is 
> generally better than IA32--were it only for the additional registers--I 
> would expect all benchmarks to run as fast or faster when compiled to 
> the AMD64 instruction set.

I believe Jon was alluding to the issues that would be encountered on 
any structure that is pointer-heavy - every pointer is now 8 bytes 
long - you just get *killed* on the [extra] memory accessing, and your 
L1/L2 caches holding "less".  This effect will be more pronounced for 
tasks that are mostly pointer-shuffling...

Robert Roessler
roessler@rftp.com
http://www.rftp.com