From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA16021; Wed, 11 Jul 2001 17:54:33 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA16013 for caml-list@pauillac.inria.fr; Wed, 11 Jul 2001 17:54:32 +0200 (MET DST) Received: (from xleroy@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id QAA25194; Tue, 10 Jul 2001 16:44:00 +0200 (MET DST) Date: Tue, 10 Jul 2001 16:44:00 +0200 From: Xavier Leroy To: Fergus Henderson Cc: caml-list@pauillac.inria.fr Subject: Re: [Caml-list] why does hashtbl not use lists? Message-ID: <20010710164400.A24756@pauillac.inria.fr> References: <4.3.2.7.2.20010710013127.02c06600@shell16.ba.best.com> <15178.50493.314895.925129@pc803> <20010710194255.A15865@hg.cs.mu.oz.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: <20010710194255.A15865@hg.cs.mu.oz.au>; from fjh@cs.mu.OZ.AU on Tue, Jul 10, 2001 at 07:42:55PM +1000 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk > I thought about mentioning the time saving from the reduced number of > allocations, but then I wondered whether it would really save any time. > If you have a compacting garbage collector, as I'm pretty sure Ocaml does, > and a good compiler, then the compiler would be able to combine the two > allocations into a single one. Does Ocamlopt do that? Yes, it does. Still, you save two stores at allocation time with the flat representation -- in addition to the more significant time savings at access time (one fewer indirection). - Xavier Leroy ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr