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
[Caml-list] yet another benchmark: vs tail recursive map
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2003-06-04 (20:23)
From: Stefano Zacchiroli <zack@b...>
Subject: Re: [Caml-list] Re: yet another benchmark: vs tail recursive map
On Wed, Jun 04, 2003 at 05:13:27PM +0200, Christophe TROESTLER wrote:
> Given this, it rather seems that is fine -- for if one really
> wants speed, one will compile to native code and the bytecode version

My point is not having speed, but rather having tail recursion. In many
cases lists are the correct data structure even for "a lot of elements".

I've always thought that tail recursive version of map would have been
terribly slower than not tail recrusive one due to the additional
reversal. But since this is not the case (or at least the shown figures
don't fit my idea of "terribly"), why keep on using the not tail
recursive one?


Stefano Zacchiroli  --  Master in Computer Science @ Uni. Bologna, Italy
zack@{,,}  -
"  I know you believe you understood what you think I said, but I am not
sure you realize that what you heard is not what I meant!  " -- G.Romney

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: