Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Bigarray map & set/get (long)
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Christophe TROESTLER <Christophe.Troestler@u...>
Subject: Re: [Caml-list] Bigarray map & set/get
Thanks for your suggestions.  Here are the results.

On Sat, 20 Jul 2002, Oleg <oleg_inconnu@myrealbox.com> wrote:
> 
> If you are using fortran layout (column-major) why are you
> incrementing rows in the inner-most loop? (AFAICR this can make a
> big difference with GCC, perhaps O'Caml too).

Ooops!  You are correct this make the times more reasonable (about 2
to 3 times C).

> Also, each loop seems to contain a call to function Array2.dim2.
> Can't this number be cached?

Well, that in fact has the opposite effect of increasing very slightly
the running time.

> Thirdly, does bigarray access check bounds? Can this be turned off?

It does.  And I don't think it can be turned off.

> And finally, you might try to experiment with 0-based indexing [1],
> it may turn out to be faster.

Very same running times.

Cheers,
ChriS
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners