From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: weis Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA21470 for caml-redistribution; Thu, 7 Oct 1999 17:51:03 +0200 (MET DST) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id QAA21185 for ; Thu, 7 Oct 1999 16:25:37 +0200 (MET DST) Received: from miss.wu-wien.ac.at (miss.wu-wien.ac.at [137.208.107.17]) by nez-perce.inria.fr (8.8.7/8.8.7) with ESMTP id QAA10482 for ; Thu, 7 Oct 1999 16:25:35 +0200 (MET DST) Received: (from mottl@localhost) by miss.wu-wien.ac.at (8.9.0/8.9.0) id QAA21666; Thu, 7 Oct 1999 16:25:34 +0200 (MET DST) From: Markus Mottl Message-Id: <199910071425.QAA21666@miss.wu-wien.ac.at> Subject: Re: speed versus C To: williamc@dai.ed.ac.uk (William Chesters) Date: Thu, 7 Oct 1999 16:25:34 +0100 (MET DST) Cc: caml-list@inria.fr (OCAML) In-Reply-To: <199910061521.QAA02123@toy.william.bogus> from "William Chesters" at Oct 6, 99 04:21:05 pm X-Mailer: ELM [version 2.4 PL21] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: weis > Incidentally, implementing a Vector in ocaml is slightly fiddly, > because you have to keep valid pointers of the right type in even the > unused part all the time. This means o.a. delaying the creation of > the underlying array until you have at least one element to put in it. I have just finished implementing a fully featured efficient automatically resizing array which gets rid of this problem (by using Obj.magic internally, but the user of this module won't see this outside). Another version treats integer and float arrays differently to exploit the fact that values in it are unboxed. Even resizable strings can be used with it (space and time efficiently). You can also use customized resizing strategies which you can change at runtime. I am nearly ready testing the code now and will write some documentation on it. I hope that it can be released sometime next week. Best regards, Markus Mottl -- Markus Mottl, mottl@miss.wu-wien.ac.at, http://miss.wu-wien.ac.at/~mottl