Re: [Caml-list] testers wanted for experimental SSE2 back-end

2010-03-10 Thread Will M. Farr
On Mar 10, 2010, at 1:25 PM, Mike Lin wrote: > On Tue, Mar 9, 2010 at 11:33 AM, Xavier Leroy wrote: > Note that x86-64 bits systems as well as Mac OS X already use SSE2 as > their default floating-point model. > > I have a bunch of biological sequence analysis stuff that could be > interesting

[Caml-list] A (Silly?) Question About Universal Type Quantification

2009-09-10 Thread Will M Farr
Hello, I recently encountered a situation where I had (effectively) the following polymorphic type: type 'a record = { id : int; data : 'a } and the following compare function let compare {id = id1} {id = id2} = Pervasives.compare id1 id2 and wanted to put such records into a set. However

Re: [Caml-list] Optimizing Float Ref's

2009-09-03 Thread Will M Farr
Xavier, Thanks for the comments. I thought that float ref's were unboxed by default! In fact, I find that breaking out the code into a stand- alone example which loops through matrix multiplies only indeed does not have any calls to "caml_modify"; everything is unboxed and stored on the

Re: [Caml-list] Optimizing Float Ref's

2009-08-31 Thread Will M Farr
ld be better to implement ref on top of a single-cell array, since then everyone would get the float unboxing whenever applicable. I imagine there is some runtime overhead to this, though. y On Aug 28, 2009, at 4:32 PM, Will M Farr wrote: Hello all, I'm running OCaml 3.11.1, and

[Caml-list] Optimizing Float Ref's

2009-08-28 Thread Will M Farr
Hello all, I'm running OCaml 3.11.1, and I noticed something strange in some native code for matrix multiply today. The code was let mmmul store m1 m2 = let (ni,nk) = dims m1 and (nk2,nj) = dims m2 and (sni,snj) = dims store in assert(nk=nk2); assert(ni=sni); assert(nj=sn

Re: [Caml-list] speeding up matrix multiplication (newbie question)

2009-02-20 Thread Will M. Farr
Mike and Erick, In some of my work, I've got code which is constantly creating and multiplying 4x4 matrices (Lorentz transforms). I usually write in a functional style, so I do not generally overwrite old matrices with the multiplication results. I have discovered that, at these sizes, it's abou

Re: [Caml-list] speeding up matrix multiplication (newbie question)

2009-02-20 Thread Will M. Farr
Erick, Sorry about the long email, but here is an explanation of what "boxing" means, how it slows you down in this case, and how you can (eventually) figure out whether it will slow you down in general. I'm not an expert, so I've probably made mistakes in the following, but I think the broad out

Re: [Caml-list] true parallelism / threads

2009-02-20 Thread Will M. Farr
Atmam, I've had some luck using OCaml with MPI (using the OCamlMPI library at http://caml.inria.fr/cgi-bin/hump.en.cgi?contrib=401 ). That may not satisfy your needs as far as multi-core goes, but perhaps it will. I can't speak to the speed of the interface (my operations were compute-bound on t