Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
ocaml doesn't need to optimize on amd64??
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2008-01-10 (13:56)
From: Kuba Ober <ober.14@o...>
Subject: Re: [Caml-list] ocaml doesn't need to optimize on amd64??
On Wednesday 09 January 2008, you wrote:
> On Wed, Jan 09, 2008 at 09:22:00AM -0500, Kuba Ober wrote:
> > Jon & al,
> >
> > why do you think that OCaml doesn't need to do certain
> > optimizations on amd64? Or does it apply only to 64 bit mode?
> > I run my benchmarks on amd64 (in 32 bit mode) and OCaml is worse
> > off than gcc.
> Register pressure.  The extra eight registers in AMD64 make a huge
> difference to a lot of code generators.  Of course, to access them
> you need to run in 64 bit mode.

Don't current x32 processors "emulate" extra registers anyway? I don't know 
what's the preferred way of telling the on-chip code dissector that you 
intend the data to say in virtual registers, but it must be something simple, 
like common, fixed memory locations or stack locations accessed in a certain 
way. I'm sure if you google on Intel's site you'll find it. In any event, the 
x32 chips have a notion of "many" virtual registers, it's just the old x32 
opcodes that don't have it. Isn't it so?

Cheers, Kuba